/
Image360.ts
73 lines (62 loc) · 1.63 KB
/
Image360.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
/*!
* Copyright 2022 Cognite AS
*/
import { Image360Revision } from './Image360Revision';
import { Image360Visualization } from './Image360Visualization';
import { Color, type Matrix4 } from 'three';
/**
* Image360 icon style
*/
export type Image360IconStyle = {
/**
* A color tint to apply to the 360 icon
*/
color?: Color;
};
/**
* A single 360 image "station", which may consist of several revisions
* captured in approximately the same location
*/
export interface Image360 {
/**
* Get a copy of the model-to-world transformation matrix
* of the given 360 image.
* @returns model-to-world transform of the 360 Image
*/
readonly transform: Matrix4;
/**
* The object containing the unit cube with the 360 images.
* @returns Image360Visualization
*/
readonly image360Visualization: Image360Visualization;
/**
* Get Id of 360 image entity.
* @returns Station Id
*/
readonly id: string;
/**
* Get label of 360 image entity.
* @returns Station label
* */
readonly label: string | undefined;
/**
* List all historical images for this entity.
* @returns A list of available revisions.
*/
getRevisions(): Image360Revision[];
/**
* Get the revision that is currently loaded for this entry.
* @returns The active revision.
*/
getActiveRevision(): Image360Revision;
/**
* Get a copy of the color assigned to the icon of this entity
*
* @returns The currently assign color, or 'default' if none is assigned
*/
getIconColor(): Color | 'default';
/**
* Assign a color to the icon of this entity
*/
setIconColor(color: Color | 'default'): void;
}