data.ts 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. /**
  2. * Copyright (c) 2019 mol* contributors, licensed under MIT, See LICENSE file for more info.
  3. *
  4. * @author Alexander Rose <alexander.rose@weirdbyte.de>
  5. */
  6. import { Vec3, Quat } from '../../mol-math/linear-algebra';
  7. export interface CellPack {
  8. cell: Cell
  9. packings: CellPacking[]
  10. }
  11. export interface CellPacking {
  12. name: string,
  13. location: 'surface' | 'interior' | 'cytoplasme',
  14. ingredients: Packing['ingredients']
  15. }
  16. //
  17. export interface Cell {
  18. recipe: Recipe
  19. cytoplasme?: Packing
  20. compartments?: { [key: string]: Compartment }
  21. }
  22. export interface Recipe {
  23. setupfile: string
  24. paths: [string, string][] // [name: string, path: string][]
  25. version: string
  26. name: string
  27. }
  28. export interface Compartment {
  29. surface?: Packing
  30. interior?: Packing
  31. }
  32. export interface Packing {
  33. ingredients: { [key: string]: Ingredient }
  34. }
  35. export interface Positions {
  36. coords?: Vec3[];
  37. }
  38. export interface Radii {
  39. radii?: number[];
  40. }
  41. export interface Ingredient {
  42. source: IngredientSource;
  43. results: [Vec3, Quat][];
  44. name: string;
  45. /** Vec3[]];CoarseGraind Beads coordinates LOD */
  46. positions?: [Positions];
  47. /** number[]];CoarseGraind Beads radii LOD */
  48. radii?: [Radii];
  49. /** Number of `curveX` properties in the object where `X` is a 0-indexed number */
  50. nbCurve?: number;
  51. uLength?: number;
  52. /** Curve properties are Vec3[] but that is not expressable in TypeScript */
  53. [curveX: string]: unknown;
  54. /** the orientation in the membrane */
  55. principalAxis?: Vec3;
  56. /** offset along membrane */
  57. offset?: Vec3;
  58. ingtype?: string;
  59. color?: Vec3;
  60. confidence?: number;
  61. }
  62. export interface IngredientSource {
  63. pdb: string;
  64. bu?: string; /** biological unit e.g AU,BU1,etc.. */
  65. selection?: string; /** NGL selection or :A or :B etc.. */
  66. model?: string; /** model number e.g 0,1,2... */
  67. transform: {
  68. center: boolean;
  69. translate?: Vec3;
  70. };
  71. biomt?: boolean;
  72. }