Skip to content

Commit 8fccc99

Browse files
fixed positioning of label in points of interest, added style options for font width. Also added option to draw poi text on top of point. Fixed stroke not displaying with bg opacity 0 issue.
1 parent 855fc18 commit 8fccc99

File tree

3 files changed

+34
-11
lines changed

3 files changed

+34
-11
lines changed

packages/dev/babylonjs/lib/api/inputs/base-inputs.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,15 @@ export namespace Base {
7272
borderBox = "border-box",
7373
contentBox = "content-box",
7474
}
75+
export enum verticalAlignmentEnum {
76+
top = "top",
77+
middle = "middle",
78+
bottom = "bottom",
79+
}
80+
export enum topBottomEnum {
81+
top = "top",
82+
bottom = "bottom",
83+
}
7584
// Can't use BabylonJS types here as that crashes worker, which tries to include them
7685
export type Color = string;
7786
export type ColorRGB = { r: number, g: number, b: number };

packages/dev/base/lib/api/inputs/base-inputs.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,17 @@ export namespace Base {
2626
export type TransformMatrix = [number, number, number, number, number, number, number, number, number, number, number, number, number, number, number, number];
2727
export type TransformMatrixes = TransformMatrix[];
2828
export enum horizontalAlignEnum {
29-
/**
30-
* Aligns to the left
31-
*/
3229
left = "left",
33-
/**
34-
* Aligns to the center
35-
*/
3630
center = "center",
37-
/**
38-
* Aligns to the right
39-
*/
4031
right = "right",
4132
}
33+
export enum verticalAlignmentEnum {
34+
top = "top",
35+
middle = "middle",
36+
bottom = "bottom",
37+
}
38+
export enum topBottomEnum {
39+
top = "top",
40+
bottom = "bottom",
41+
}
4242
}

packages/dev/core/lib/api/inputs/base-inputs.ts

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,29 @@ export namespace Base {
1212
exponentialSquared = "exponentialSquared",
1313
linear = "linear",
1414
}
15+
export enum horizontalAlignEnum {
16+
left = "left",
17+
center = "center",
18+
right = "right",
19+
}
20+
export enum verticalAlignmentEnum {
21+
top = "top",
22+
middle = "middle",
23+
bottom = "bottom",
24+
}
25+
export enum topBottomEnum {
26+
top = "top",
27+
bottom = "bottom",
28+
}
1529
// Can't use BabylonJS types here as that crashes worker, which tries to include them
1630
export type Color = string;
1731
export type ColorRGB = { r: number, g: number, b: number };
1832
export type Point2 = [number, number];
1933
export type Vector2 = [number, number];
2034
export type Point3 = [number, number, number];
2135
export type Vector3 = [number, number, number];
22-
export type Axis3 = {origin: Base.Point3, direction: Base.Vector3};
23-
export type Axis2 = {origin: Base.Point2, direction: Base.Vector2};
36+
export type Axis3 = { origin: Base.Point3, direction: Base.Vector3 };
37+
export type Axis2 = { origin: Base.Point2, direction: Base.Vector2 };
2438
export type Segment2 = [Point2, Point2];
2539
export type Segment3 = [Point3, Point3];
2640
// Triangle plane is efficient defininition described by a normal vector and d value (N dot X = d)

0 commit comments

Comments
 (0)