@babylonjs/gui 9.13.0 → 9.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/2D/FrameGraph/pure.d.ts +2 -0
- package/2D/FrameGraph/pure.js +3 -0
- package/2D/FrameGraph/pure.js.map +1 -0
- package/2D/FrameGraph/renderGraphGUIBlock.d.ts +3 -41
- package/2D/FrameGraph/renderGraphGUIBlock.js +5 -64
- package/2D/FrameGraph/renderGraphGUIBlock.js.map +1 -1
- package/2D/FrameGraph/renderGraphGUIBlock.pure.d.ts +48 -0
- package/2D/FrameGraph/renderGraphGUIBlock.pure.js +78 -0
- package/2D/FrameGraph/renderGraphGUIBlock.pure.js.map +1 -0
- package/2D/controls/button.d.ts +3 -107
- package/2D/controls/button.js +5 -243
- package/2D/controls/button.js.map +1 -1
- package/2D/controls/button.pure.d.ts +114 -0
- package/2D/controls/button.pure.js +257 -0
- package/2D/controls/button.pure.js.map +1 -0
- package/2D/controls/checkbox.d.ts +3 -51
- package/2D/controls/checkbox.js +5 -161
- package/2D/controls/checkbox.js.map +1 -1
- package/2D/controls/checkbox.pure.d.ts +58 -0
- package/2D/controls/checkbox.pure.js +175 -0
- package/2D/controls/checkbox.pure.js.map +1 -0
- package/2D/controls/colorpicker.d.ts +5 -101
- package/2D/controls/colorpicker.js +7 -1394
- package/2D/controls/colorpicker.js.map +1 -1
- package/2D/controls/colorpicker.pure.d.ts +106 -0
- package/2D/controls/colorpicker.pure.js +1406 -0
- package/2D/controls/colorpicker.pure.js.map +1 -0
- package/2D/controls/container.d.ts +3 -177
- package/2D/controls/container.js +5 -615
- package/2D/controls/container.js.map +1 -1
- package/2D/controls/container.pure.d.ts +184 -0
- package/2D/controls/container.pure.js +629 -0
- package/2D/controls/container.pure.js.map +1 -0
- package/2D/controls/control.d.ts +3 -944
- package/2D/controls/control.js +5 -2457
- package/2D/controls/control.js.map +1 -1
- package/2D/controls/control.pure.d.ts +951 -0
- package/2D/controls/control.pure.js +2471 -0
- package/2D/controls/control.pure.js.map +1 -0
- package/2D/controls/displayGrid.d.ts +5 -53
- package/2D/controls/displayGrid.js +7 -201
- package/2D/controls/displayGrid.js.map +1 -1
- package/2D/controls/displayGrid.pure.d.ts +58 -0
- package/2D/controls/displayGrid.pure.js +213 -0
- package/2D/controls/displayGrid.pure.js.map +1 -0
- package/2D/controls/ellipse.d.ts +5 -25
- package/2D/controls/ellipse.js +7 -92
- package/2D/controls/ellipse.js.map +1 -1
- package/2D/controls/ellipse.pure.d.ts +30 -0
- package/2D/controls/ellipse.pure.js +104 -0
- package/2D/controls/ellipse.pure.js.map +1 -0
- package/2D/controls/focusableButton.d.ts +3 -15
- package/2D/controls/focusableButton.js +5 -22
- package/2D/controls/focusableButton.js.map +1 -1
- package/2D/controls/focusableButton.pure.d.ts +22 -0
- package/2D/controls/focusableButton.pure.js +36 -0
- package/2D/controls/focusableButton.pure.js.map +1 -0
- package/2D/controls/gradient/LinearGradient.d.ts +3 -43
- package/2D/controls/gradient/LinearGradient.js +5 -70
- package/2D/controls/gradient/LinearGradient.js.map +1 -1
- package/2D/controls/gradient/LinearGradient.pure.d.ts +50 -0
- package/2D/controls/gradient/LinearGradient.pure.js +84 -0
- package/2D/controls/gradient/LinearGradient.pure.js.map +1 -0
- package/2D/controls/gradient/RadialGradient.d.ts +3 -51
- package/2D/controls/gradient/RadialGradient.js +5 -86
- package/2D/controls/gradient/RadialGradient.js.map +1 -1
- package/2D/controls/gradient/RadialGradient.pure.d.ts +58 -0
- package/2D/controls/gradient/RadialGradient.pure.js +100 -0
- package/2D/controls/gradient/RadialGradient.pure.js.map +1 -0
- package/2D/controls/gradient/pure.d.ts +3 -0
- package/2D/controls/gradient/pure.js +4 -0
- package/2D/controls/gradient/pure.js.map +1 -0
- package/2D/controls/grid.d.ts +3 -149
- package/2D/controls/grid.js +5 -525
- package/2D/controls/grid.js.map +1 -1
- package/2D/controls/grid.pure.d.ts +156 -0
- package/2D/controls/grid.pure.js +539 -0
- package/2D/controls/grid.pure.js.map +1 -0
- package/2D/controls/image.d.ts +3 -226
- package/2D/controls/image.js +5 -913
- package/2D/controls/image.js.map +1 -1
- package/2D/controls/image.pure.d.ts +233 -0
- package/2D/controls/image.pure.js +927 -0
- package/2D/controls/image.pure.js.map +1 -0
- package/2D/controls/inputPassword.d.ts +3 -7
- package/2D/controls/inputPassword.js +5 -19
- package/2D/controls/inputPassword.js.map +1 -1
- package/2D/controls/inputPassword.pure.d.ts +14 -0
- package/2D/controls/inputPassword.pure.js +33 -0
- package/2D/controls/inputPassword.pure.js.map +1 -0
- package/2D/controls/inputText.d.ts +3 -202
- package/2D/controls/inputText.js +5 -1050
- package/2D/controls/inputText.js.map +1 -1
- package/2D/controls/inputText.pure.d.ts +209 -0
- package/2D/controls/inputText.pure.js +1064 -0
- package/2D/controls/inputText.pure.js.map +1 -0
- package/2D/controls/inputTextArea.d.ts +3 -140
- package/2D/controls/inputTextArea.js +5 -1023
- package/2D/controls/inputTextArea.js.map +1 -1
- package/2D/controls/inputTextArea.pure.d.ts +147 -0
- package/2D/controls/inputTextArea.pure.js +1037 -0
- package/2D/controls/inputTextArea.pure.js.map +1 -0
- package/2D/controls/line.d.ts +5 -74
- package/2D/controls/line.js +7 -234
- package/2D/controls/line.js.map +1 -1
- package/2D/controls/line.pure.d.ts +79 -0
- package/2D/controls/line.pure.js +246 -0
- package/2D/controls/line.pure.js.map +1 -0
- package/2D/controls/multiLine.d.ts +3 -73
- package/2D/controls/multiLine.js +5 -234
- package/2D/controls/multiLine.js.map +1 -1
- package/2D/controls/multiLine.pure.d.ts +80 -0
- package/2D/controls/multiLine.pure.js +248 -0
- package/2D/controls/multiLine.pure.js.map +1 -0
- package/2D/controls/pure.d.ts +38 -0
- package/2D/controls/pure.js +39 -0
- package/2D/controls/pure.js.map +1 -0
- package/2D/controls/radioButton.d.ts +3 -47
- package/2D/controls/radioButton.js +5 -182
- package/2D/controls/radioButton.js.map +1 -1
- package/2D/controls/radioButton.pure.d.ts +54 -0
- package/2D/controls/radioButton.pure.js +196 -0
- package/2D/controls/radioButton.pure.js.map +1 -0
- package/2D/controls/rectangle.d.ts +5 -43
- package/2D/controls/rectangle.js +7 -205
- package/2D/controls/rectangle.js.map +1 -1
- package/2D/controls/rectangle.pure.d.ts +48 -0
- package/2D/controls/rectangle.pure.js +217 -0
- package/2D/controls/rectangle.pure.js.map +1 -0
- package/2D/controls/scrollViewers/pure.d.ts +2 -0
- package/2D/controls/scrollViewers/pure.js +3 -0
- package/2D/controls/scrollViewers/pure.js.map +1 -0
- package/2D/controls/scrollViewers/scrollViewer.d.ts +3 -176
- package/2D/controls/scrollViewers/scrollViewer.js +5 -584
- package/2D/controls/scrollViewers/scrollViewer.js.map +1 -1
- package/2D/controls/scrollViewers/scrollViewer.pure.d.ts +183 -0
- package/2D/controls/scrollViewers/scrollViewer.pure.js +598 -0
- package/2D/controls/scrollViewers/scrollViewer.pure.js.map +1 -0
- package/2D/controls/sliders/imageBasedSlider.d.ts +3 -45
- package/2D/controls/sliders/imageBasedSlider.js +5 -165
- package/2D/controls/sliders/imageBasedSlider.js.map +1 -1
- package/2D/controls/sliders/imageBasedSlider.pure.d.ts +52 -0
- package/2D/controls/sliders/imageBasedSlider.pure.js +179 -0
- package/2D/controls/sliders/imageBasedSlider.pure.js.map +1 -0
- package/2D/controls/sliders/pure.d.ts +4 -0
- package/2D/controls/sliders/pure.js +5 -0
- package/2D/controls/sliders/pure.js.map +1 -0
- package/2D/controls/sliders/scrollBar.d.ts +3 -48
- package/2D/controls/sliders/scrollBar.js +5 -170
- package/2D/controls/sliders/scrollBar.js.map +1 -1
- package/2D/controls/sliders/scrollBar.pure.d.ts +55 -0
- package/2D/controls/sliders/scrollBar.pure.js +184 -0
- package/2D/controls/sliders/scrollBar.pure.js.map +1 -0
- package/2D/controls/sliders/slider.d.ts +3 -44
- package/2D/controls/sliders/slider.js +5 -278
- package/2D/controls/sliders/slider.js.map +1 -1
- package/2D/controls/sliders/slider.pure.d.ts +51 -0
- package/2D/controls/sliders/slider.pure.js +292 -0
- package/2D/controls/sliders/slider.pure.js.map +1 -0
- package/2D/controls/stackPanel.d.ts +3 -62
- package/2D/controls/stackPanel.js +5 -243
- package/2D/controls/stackPanel.js.map +1 -1
- package/2D/controls/stackPanel.pure.d.ts +69 -0
- package/2D/controls/stackPanel.pure.js +257 -0
- package/2D/controls/stackPanel.pure.js.map +1 -0
- package/2D/controls/statics.d.ts +3 -4
- package/2D/controls/statics.js +5 -47
- package/2D/controls/statics.js.map +1 -1
- package/2D/controls/statics.pure.d.ts +11 -0
- package/2D/controls/statics.pure.js +61 -0
- package/2D/controls/statics.pure.js.map +1 -0
- package/2D/controls/textBlock.d.ts +3 -217
- package/2D/controls/textBlock.js +5 -676
- package/2D/controls/textBlock.js.map +1 -1
- package/2D/controls/textBlock.pure.d.ts +224 -0
- package/2D/controls/textBlock.pure.js +690 -0
- package/2D/controls/textBlock.pure.js.map +1 -0
- package/2D/controls/toggleButton.d.ts +3 -91
- package/2D/controls/toggleButton.js +5 -226
- package/2D/controls/toggleButton.js.map +1 -1
- package/2D/controls/toggleButton.pure.d.ts +98 -0
- package/2D/controls/toggleButton.pure.js +240 -0
- package/2D/controls/toggleButton.pure.js.map +1 -0
- package/2D/controls/virtualKeyboard.d.ts +3 -100
- package/2D/controls/virtualKeyboard.js +5 -272
- package/2D/controls/virtualKeyboard.js.map +1 -1
- package/2D/controls/virtualKeyboard.pure.d.ts +107 -0
- package/2D/controls/virtualKeyboard.pure.js +286 -0
- package/2D/controls/virtualKeyboard.pure.js.map +1 -0
- package/2D/pure.d.ts +13 -0
- package/2D/pure.js +15 -0
- package/2D/pure.js.map +1 -0
- package/3D/controls/pure.d.ts +23 -0
- package/3D/controls/pure.js +24 -0
- package/3D/controls/pure.js.map +1 -0
- package/3D/gizmos/pure.d.ts +3 -0
- package/3D/gizmos/pure.js +4 -0
- package/3D/gizmos/pure.js.map +1 -0
- package/3D/materials/fluent/fluentMaterial.d.ts +5 -100
- package/3D/materials/fluent/fluentMaterial.js +7 -305
- package/3D/materials/fluent/fluentMaterial.js.map +1 -1
- package/3D/materials/fluent/fluentMaterial.pure.d.ts +105 -0
- package/3D/materials/fluent/fluentMaterial.pure.js +317 -0
- package/3D/materials/fluent/fluentMaterial.pure.js.map +1 -0
- package/3D/materials/fluent/pure.d.ts +2 -0
- package/3D/materials/fluent/pure.js +3 -0
- package/3D/materials/fluent/pure.js.map +1 -0
- package/3D/materials/fluentBackplate/fluentBackplateMaterial.d.ts +5 -164
- package/3D/materials/fluentBackplate/fluentBackplateMaterial.js +7 -488
- package/3D/materials/fluentBackplate/fluentBackplateMaterial.js.map +1 -1
- package/3D/materials/fluentBackplate/fluentBackplateMaterial.pure.d.ts +169 -0
- package/3D/materials/fluentBackplate/fluentBackplateMaterial.pure.js +500 -0
- package/3D/materials/fluentBackplate/fluentBackplateMaterial.pure.js.map +1 -0
- package/3D/materials/fluentBackplate/pure.d.ts +2 -0
- package/3D/materials/fluentBackplate/pure.js +3 -0
- package/3D/materials/fluentBackplate/pure.js.map +1 -0
- package/3D/materials/fluentButton/fluentButtonMaterial.d.ts +5 -200
- package/3D/materials/fluentButton/fluentButtonMaterial.js +7 -563
- package/3D/materials/fluentButton/fluentButtonMaterial.js.map +1 -1
- package/3D/materials/fluentButton/fluentButtonMaterial.pure.d.ts +205 -0
- package/3D/materials/fluentButton/fluentButtonMaterial.pure.js +575 -0
- package/3D/materials/fluentButton/fluentButtonMaterial.pure.js.map +1 -0
- package/3D/materials/fluentButton/pure.d.ts +2 -0
- package/3D/materials/fluentButton/pure.js +3 -0
- package/3D/materials/fluentButton/pure.js.map +1 -0
- package/3D/materials/handle/handleMaterial.d.ts +5 -66
- package/3D/materials/handle/handleMaterial.js +5 -118
- package/3D/materials/handle/handleMaterial.js.map +1 -1
- package/3D/materials/handle/handleMaterial.pure.d.ts +66 -0
- package/3D/materials/handle/handleMaterial.pure.js +119 -0
- package/3D/materials/handle/handleMaterial.pure.js.map +1 -0
- package/3D/materials/handle/pure.d.ts +2 -0
- package/3D/materials/handle/pure.js +3 -0
- package/3D/materials/handle/pure.js.map +1 -0
- package/3D/materials/mrdl/mrdlBackglowMaterial.d.ts +5 -85
- package/3D/materials/mrdl/mrdlBackglowMaterial.js +7 -299
- package/3D/materials/mrdl/mrdlBackglowMaterial.js.map +1 -1
- package/3D/materials/mrdl/mrdlBackglowMaterial.pure.d.ts +90 -0
- package/3D/materials/mrdl/mrdlBackglowMaterial.pure.js +311 -0
- package/3D/materials/mrdl/mrdlBackglowMaterial.pure.js.map +1 -0
- package/3D/materials/mrdl/mrdlBackplateMaterial.d.ts +5 -145
- package/3D/materials/mrdl/mrdlBackplateMaterial.js +7 -433
- package/3D/materials/mrdl/mrdlBackplateMaterial.js.map +1 -1
- package/3D/materials/mrdl/mrdlBackplateMaterial.pure.d.ts +157 -0
- package/3D/materials/mrdl/mrdlBackplateMaterial.pure.js +452 -0
- package/3D/materials/mrdl/mrdlBackplateMaterial.pure.js.map +1 -0
- package/3D/materials/mrdl/mrdlFrontplateMaterial.d.ts +5 -183
- package/3D/materials/mrdl/mrdlFrontplateMaterial.js +7 -532
- package/3D/materials/mrdl/mrdlFrontplateMaterial.js.map +1 -1
- package/3D/materials/mrdl/mrdlFrontplateMaterial.pure.d.ts +188 -0
- package/3D/materials/mrdl/mrdlFrontplateMaterial.pure.js +544 -0
- package/3D/materials/mrdl/mrdlFrontplateMaterial.pure.js.map +1 -0
- package/3D/materials/mrdl/mrdlInnerquadMaterial.d.ts +5 -54
- package/3D/materials/mrdl/mrdlInnerquadMaterial.js +7 -227
- package/3D/materials/mrdl/mrdlInnerquadMaterial.js.map +1 -1
- package/3D/materials/mrdl/mrdlInnerquadMaterial.pure.d.ts +59 -0
- package/3D/materials/mrdl/mrdlInnerquadMaterial.pure.js +239 -0
- package/3D/materials/mrdl/mrdlInnerquadMaterial.pure.js.map +1 -0
- package/3D/materials/mrdl/mrdlSliderBarMaterial.d.ts +5 -334
- package/3D/materials/mrdl/mrdlSliderBarMaterial.js +7 -855
- package/3D/materials/mrdl/mrdlSliderBarMaterial.js.map +1 -1
- package/3D/materials/mrdl/mrdlSliderBarMaterial.pure.d.ts +346 -0
- package/3D/materials/mrdl/mrdlSliderBarMaterial.pure.js +874 -0
- package/3D/materials/mrdl/mrdlSliderBarMaterial.pure.js.map +1 -0
- package/3D/materials/mrdl/mrdlSliderThumbMaterial.d.ts +5 -334
- package/3D/materials/mrdl/mrdlSliderThumbMaterial.js +7 -855
- package/3D/materials/mrdl/mrdlSliderThumbMaterial.js.map +1 -1
- package/3D/materials/mrdl/mrdlSliderThumbMaterial.pure.d.ts +346 -0
- package/3D/materials/mrdl/mrdlSliderThumbMaterial.pure.js +874 -0
- package/3D/materials/mrdl/mrdlSliderThumbMaterial.pure.js.map +1 -0
- package/3D/materials/mrdl/pure.d.ts +7 -0
- package/3D/materials/mrdl/pure.js +8 -0
- package/3D/materials/mrdl/pure.js.map +1 -0
- package/3D/materials/pure.d.ts +6 -0
- package/3D/materials/pure.js +8 -0
- package/3D/materials/pure.js.map +1 -0
- package/3D/pure.d.ts +6 -0
- package/3D/pure.js +8 -0
- package/3D/pure.js.map +1 -0
- package/package.json +50 -3
- package/pure.d.ts +3 -0
- package/pure.js +5 -0
- package/pure.js.map +1 -0
|
@@ -1,858 +1,10 @@
|
|
|
1
|
-
import { __decorate } from "@babylonjs/core/tslib.es6.js";
|
|
2
|
-
import { serialize } from "@babylonjs/core/Misc/decorators.js";
|
|
3
|
-
import { SerializationHelper } from "@babylonjs/core/Misc/decorators.serialization.js";
|
|
4
|
-
import { Vector2, Vector3, Vector4 } from "@babylonjs/core/Maths/math.vector.js";
|
|
5
|
-
import { Texture } from "@babylonjs/core/Materials/Textures/texture.js";
|
|
6
|
-
import { MaterialDefines } from "@babylonjs/core/Materials/materialDefines.js";
|
|
7
|
-
import { PushMaterial } from "@babylonjs/core/Materials/pushMaterial.js";
|
|
8
|
-
import { VertexBuffer } from "@babylonjs/core/Buffers/buffer.js";
|
|
9
|
-
import { RegisterClass } from "@babylonjs/core/Misc/typeStore.js";
|
|
10
|
-
import { Color4 } from "@babylonjs/core/Maths/math.color.js";
|
|
11
|
-
import { EffectFallbacks } from "@babylonjs/core/Materials/effectFallbacks.js";
|
|
12
|
-
import { Constants } from "@babylonjs/core/Engines/constants.js";
|
|
13
|
-
import "./shaders/mrdlSliderBar.fragment.js";
|
|
14
|
-
import "./shaders/mrdlSliderBar.vertex.js";
|
|
15
|
-
import { HandleFallbacksForShadows, PrepareAttributesForInstances, PrepareDefinesForAttributes, PrepareUniformsAndSamplersList } from "@babylonjs/core/Materials/materialHelper.functions.js";
|
|
16
|
-
import { Tools } from "@babylonjs/core/Misc/tools.js";
|
|
17
|
-
/** @internal */
|
|
18
|
-
class MRDLSliderBarMaterialDefines extends MaterialDefines {
|
|
19
|
-
constructor() {
|
|
20
|
-
super();
|
|
21
|
-
/*
|
|
22
|
-
"SKY_ENABLED", "BLOB_ENABLE_2", "IRIDESCENCE_ENABLED"
|
|
23
|
-
*/
|
|
24
|
-
this.SKY_ENABLED = true;
|
|
25
|
-
this.BLOB_ENABLE_2 = true;
|
|
26
|
-
this.IRIDESCENCE_ENABLED = true;
|
|
27
|
-
this._needNormals = true;
|
|
28
|
-
this._needUVs = true;
|
|
29
|
-
this.rebuild();
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* Class used to render Slider Bar material with MRDL
|
|
34
|
-
*/
|
|
35
|
-
export class MRDLSliderBarMaterial extends PushMaterial {
|
|
36
|
-
constructor(name, scene) {
|
|
37
|
-
super(name, scene);
|
|
38
|
-
/**
|
|
39
|
-
* Gets or sets the corner Radius on the slider bar.
|
|
40
|
-
*/
|
|
41
|
-
this.radius = 0.6;
|
|
42
|
-
/**
|
|
43
|
-
* Gets or sets the Bevel Front on the slider bar.
|
|
44
|
-
*/
|
|
45
|
-
this.bevelFront = 0.6;
|
|
46
|
-
/**
|
|
47
|
-
* Gets or sets the Bevel Front Stretch on the slider bar.
|
|
48
|
-
*/
|
|
49
|
-
this.bevelFrontStretch = 0.077;
|
|
50
|
-
/**
|
|
51
|
-
* Gets or sets the Bevel Back on the slider bar.
|
|
52
|
-
*/
|
|
53
|
-
this.bevelBack = 0;
|
|
54
|
-
/**
|
|
55
|
-
* Gets or sets the Bevel Back Stretch on the slider bar.
|
|
56
|
-
*/
|
|
57
|
-
this.bevelBackStretch = 0;
|
|
58
|
-
/**
|
|
59
|
-
* Gets or sets the top left Radii Multiplier.
|
|
60
|
-
*/
|
|
61
|
-
this.radiusTopLeft = 1.0;
|
|
62
|
-
/**
|
|
63
|
-
* Gets or sets the top left Radii Multiplier.
|
|
64
|
-
*/
|
|
65
|
-
this.radiusTopRight = 1.0;
|
|
66
|
-
/**
|
|
67
|
-
* Gets or sets the top left Radii Multiplier.
|
|
68
|
-
*/
|
|
69
|
-
this.radiusBottomLeft = 1.0;
|
|
70
|
-
/**
|
|
71
|
-
* Gets or sets the top left Radii Multiplier.
|
|
72
|
-
*/
|
|
73
|
-
this.radiusBottomRight = 1.0;
|
|
74
|
-
/**
|
|
75
|
-
* Gets or sets whether Bulge is enabled.
|
|
76
|
-
* Default is false.
|
|
77
|
-
*/
|
|
78
|
-
this.bulgeEnabled = false;
|
|
79
|
-
/**
|
|
80
|
-
* Gets or sets the Bulge Height.
|
|
81
|
-
*/
|
|
82
|
-
this.bulgeHeight = -0.323;
|
|
83
|
-
/**
|
|
84
|
-
* Gets or sets the Bulge Radius.
|
|
85
|
-
*/
|
|
86
|
-
this.bulgeRadius = 0.73;
|
|
87
|
-
/**
|
|
88
|
-
* Gets or sets the Sun Intensity.
|
|
89
|
-
*/
|
|
90
|
-
this.sunIntensity = 1.102;
|
|
91
|
-
/**
|
|
92
|
-
* Gets or sets the Sun Theta.
|
|
93
|
-
*/
|
|
94
|
-
this.sunTheta = 0.76;
|
|
95
|
-
/**
|
|
96
|
-
* Gets or sets the Sun Phi.
|
|
97
|
-
*/
|
|
98
|
-
this.sunPhi = 0.526;
|
|
99
|
-
/**
|
|
100
|
-
* Gets or sets the Indirect Diffuse.
|
|
101
|
-
*/
|
|
102
|
-
this.indirectDiffuse = 0.658;
|
|
103
|
-
/**
|
|
104
|
-
* Gets or sets the base albedo.
|
|
105
|
-
*/
|
|
106
|
-
this.albedo = new Color4(0.0117647, 0.505882, 0.996078, 1);
|
|
107
|
-
/**
|
|
108
|
-
* Gets or sets the Specular value.
|
|
109
|
-
*/
|
|
110
|
-
this.specular = 0;
|
|
111
|
-
/**
|
|
112
|
-
* Gets or sets the Shininess value.
|
|
113
|
-
*/
|
|
114
|
-
this.shininess = 10;
|
|
115
|
-
/**
|
|
116
|
-
* Gets or sets the Sharpness value.
|
|
117
|
-
*/
|
|
118
|
-
this.sharpness = 0;
|
|
119
|
-
/**
|
|
120
|
-
* Gets or sets the Subsurface value.
|
|
121
|
-
*/
|
|
122
|
-
this.subsurface = 0;
|
|
123
|
-
/**
|
|
124
|
-
* Gets or sets the left gradient color.
|
|
125
|
-
*/
|
|
126
|
-
this.leftGradientColor = new Color4(0.0117647, 0.505882, 0.996078, 1);
|
|
127
|
-
/**
|
|
128
|
-
* Gets or sets the right gradient color.
|
|
129
|
-
*/
|
|
130
|
-
this.rightGradientColor = new Color4(0.0117647, 0.505882, 0.996078, 1);
|
|
131
|
-
/**
|
|
132
|
-
* Gets or sets the reflection value.
|
|
133
|
-
*/
|
|
134
|
-
this.reflection = 0.749;
|
|
135
|
-
/**
|
|
136
|
-
* Gets or sets the front reflect value.
|
|
137
|
-
*/
|
|
138
|
-
this.frontReflect = 0;
|
|
139
|
-
/**
|
|
140
|
-
* Gets or sets the edge reflect value.
|
|
141
|
-
*/
|
|
142
|
-
this.edgeReflect = 0.09;
|
|
143
|
-
/**
|
|
144
|
-
* Gets or sets the power value.
|
|
145
|
-
*/
|
|
146
|
-
this.power = 8.13;
|
|
147
|
-
/**
|
|
148
|
-
* Gets or sets the sky color.
|
|
149
|
-
*/
|
|
150
|
-
this.skyColor = new Color4(0.0117647, 0.964706, 0.996078, 1);
|
|
151
|
-
/**
|
|
152
|
-
* Gets or sets the horizon color.
|
|
153
|
-
*/
|
|
154
|
-
this.horizonColor = new Color4(0.0117647, 0.333333, 0.996078, 1);
|
|
155
|
-
/**
|
|
156
|
-
* Gets or sets the ground color.
|
|
157
|
-
*/
|
|
158
|
-
this.groundColor = new Color4(0, 0.254902, 0.996078, 1);
|
|
159
|
-
/**
|
|
160
|
-
* Gets or sets the horizon power value.
|
|
161
|
-
*/
|
|
162
|
-
this.horizonPower = 1;
|
|
163
|
-
/**
|
|
164
|
-
* Gets or sets the finger occlusion width value.
|
|
165
|
-
*/
|
|
166
|
-
this.width = 0.02;
|
|
167
|
-
/**
|
|
168
|
-
* Gets or sets the finger occlusion fuzz value.
|
|
169
|
-
*/
|
|
170
|
-
this.fuzz = 0.5;
|
|
171
|
-
/**
|
|
172
|
-
* Gets or sets the minimum finger occlusion fuzz value.
|
|
173
|
-
*/
|
|
174
|
-
this.minFuzz = 0.001;
|
|
175
|
-
/**
|
|
176
|
-
* Gets or sets the finger occlusion clip fade value.
|
|
177
|
-
*/
|
|
178
|
-
this.clipFade = 0.01;
|
|
179
|
-
/**
|
|
180
|
-
* Gets or sets the hue shift value.
|
|
181
|
-
*/
|
|
182
|
-
this.hueShift = 0;
|
|
183
|
-
/**
|
|
184
|
-
* Gets or sets the saturation shift value.
|
|
185
|
-
*/
|
|
186
|
-
this.saturationShift = 0;
|
|
187
|
-
/**
|
|
188
|
-
* Gets or sets the value shift.
|
|
189
|
-
*/
|
|
190
|
-
this.valueShift = 0;
|
|
191
|
-
/**
|
|
192
|
-
* Gets or sets the position of the hover glow effect.
|
|
193
|
-
*/
|
|
194
|
-
this.blobPosition = new Vector3(0, 0, 0.1);
|
|
195
|
-
/**
|
|
196
|
-
* Gets or sets the intensity of the hover glow effect.
|
|
197
|
-
*/
|
|
198
|
-
this.blobIntensity = 0.5;
|
|
199
|
-
/**
|
|
200
|
-
* Gets or sets the near size of the hover glow effect.
|
|
201
|
-
*/
|
|
202
|
-
this.blobNearSize = 0.01;
|
|
203
|
-
/**
|
|
204
|
-
* Gets or sets the far size of the hover glow effect.
|
|
205
|
-
*/
|
|
206
|
-
this.blobFarSize = 0.03;
|
|
207
|
-
/**
|
|
208
|
-
* Gets or sets the distance considered "near" to the mesh, which controls the size of the hover glow effect (see blobNearSize).
|
|
209
|
-
*/
|
|
210
|
-
this.blobNearDistance = 0;
|
|
211
|
-
/**
|
|
212
|
-
* Gets or sets the distance considered "far" from the mesh, which controls the size of the hover glow effect (see blobFarSize).
|
|
213
|
-
*/
|
|
214
|
-
this.blobFarDistance = 0.08;
|
|
215
|
-
/**
|
|
216
|
-
* Gets or sets the length of the hover glow effect fade.
|
|
217
|
-
*/
|
|
218
|
-
this.blobFadeLength = 0.576;
|
|
219
|
-
/**
|
|
220
|
-
* Gets or sets the progress of the hover glow effect selection animation corresponding to the left pointer (0.0 - 1.0).
|
|
221
|
-
*/
|
|
222
|
-
this.blobPulse = 0;
|
|
223
|
-
/**
|
|
224
|
-
* Gets or sets the opacity of the hover glow effect corresponding to the left pointer (0.0 - 1.0). Default is 0.
|
|
225
|
-
*/
|
|
226
|
-
this.blobFade = 1;
|
|
227
|
-
/**
|
|
228
|
-
* Gets or sets the position of the hover glow effect.
|
|
229
|
-
*/
|
|
230
|
-
this.blobPosition2 = new Vector3(0.2, 0, 0.1);
|
|
231
|
-
/**
|
|
232
|
-
* Gets or sets the size of the hover glow effect when the right pointer is considered "near" to the mesh (see blobNearDistance).
|
|
233
|
-
*/
|
|
234
|
-
this.blobNearSize2 = 0.01;
|
|
235
|
-
/**
|
|
236
|
-
* Gets or sets the progress of the hover glow effect selection animation corresponding to the right pointer (0.0 - 1.0).
|
|
237
|
-
*/
|
|
238
|
-
this.blobPulse2 = 0;
|
|
239
|
-
/**
|
|
240
|
-
* Gets or sets the opacity of the hover glow effect corresponding to the right pointer (0.0 - 1.0). Default is 1.
|
|
241
|
-
*/
|
|
242
|
-
this.blobFade2 = 1;
|
|
243
|
-
/**
|
|
244
|
-
* Gets or sets the texture of the hover glow effect.
|
|
245
|
-
*/
|
|
246
|
-
this.blobTexture = new Texture("", this.getScene());
|
|
247
|
-
/**
|
|
248
|
-
* Gets or sets the finger position for left index.
|
|
249
|
-
*/
|
|
250
|
-
this.leftIndexPosition = new Vector3(0, 0, 1);
|
|
251
|
-
/**
|
|
252
|
-
* Gets or sets the finger position for right index.
|
|
253
|
-
*/
|
|
254
|
-
this.rightIndexPosition = new Vector3(-1, -1, -1);
|
|
255
|
-
/**
|
|
256
|
-
* Gets or sets the finger position for left index middle position.
|
|
257
|
-
*/
|
|
258
|
-
this.leftIndexMiddlePosition = new Vector3(0, 0, 0);
|
|
259
|
-
/**
|
|
260
|
-
* Gets or sets the finger position for right index middle position.
|
|
261
|
-
*/
|
|
262
|
-
this.rightIndexMiddlePosition = new Vector3(0, 0, 0);
|
|
263
|
-
/**
|
|
264
|
-
* Gets or sets the Decal Scle for XY.
|
|
265
|
-
*/
|
|
266
|
-
this.decalScaleXY = new Vector2(1.5, 1.5);
|
|
267
|
-
/**
|
|
268
|
-
* Gets or sets decalFrontOnly
|
|
269
|
-
* Default is true
|
|
270
|
-
*/
|
|
271
|
-
this.decalFrontOnly = true;
|
|
272
|
-
/**
|
|
273
|
-
* Gets or sets the Rim Light intensity.
|
|
274
|
-
*/
|
|
275
|
-
this.rimIntensity = 0.287;
|
|
276
|
-
/**
|
|
277
|
-
* Gets or sets the Rim Light hue shift value.
|
|
278
|
-
*/
|
|
279
|
-
this.rimHueShift = 0;
|
|
280
|
-
/**
|
|
281
|
-
* Gets or sets the Rim Light saturation shift value.
|
|
282
|
-
*/
|
|
283
|
-
this.rimSaturationShift = 0;
|
|
284
|
-
/**
|
|
285
|
-
* Gets or sets the Rim Light value shift.
|
|
286
|
-
*/
|
|
287
|
-
this.rimValueShift = -1;
|
|
288
|
-
/**
|
|
289
|
-
* Gets or sets the intensity of the iridescence effect.
|
|
290
|
-
*/
|
|
291
|
-
this.iridescenceIntensity = 0;
|
|
292
|
-
/**
|
|
293
|
-
* @internal
|
|
294
|
-
*/
|
|
295
|
-
this.useGlobalLeftIndex = 1.0;
|
|
296
|
-
/**
|
|
297
|
-
* @internal
|
|
298
|
-
*/
|
|
299
|
-
this.useGlobalRightIndex = 1.0;
|
|
300
|
-
/**
|
|
301
|
-
* @internal
|
|
302
|
-
*/
|
|
303
|
-
this.globalLeftIndexTipProximity = 0.0;
|
|
304
|
-
/**
|
|
305
|
-
* @internal
|
|
306
|
-
*/
|
|
307
|
-
this.globalRightIndexTipProximity = 0.0;
|
|
308
|
-
/**
|
|
309
|
-
* @internal
|
|
310
|
-
*/
|
|
311
|
-
this.globalLeftIndexTipPosition = new Vector4(0.5, 0.0, -0.55, 1.0);
|
|
312
|
-
/**
|
|
313
|
-
* @internal
|
|
314
|
-
*/
|
|
315
|
-
this.globaRightIndexTipPosition = new Vector4(0.0, 0.0, 0.0, 1.0);
|
|
316
|
-
/**
|
|
317
|
-
* @internal
|
|
318
|
-
*/
|
|
319
|
-
this.globalLeftThumbTipPosition = new Vector4(0.5, 0.0, -0.55, 1.0);
|
|
320
|
-
/**
|
|
321
|
-
* @internal
|
|
322
|
-
*/
|
|
323
|
-
this.globalRightThumbTipPosition = new Vector4(0.0, 0.0, 0.0, 1.0);
|
|
324
|
-
/**
|
|
325
|
-
* @internal
|
|
326
|
-
*/
|
|
327
|
-
this.globalLeftIndexMiddlePosition = new Vector4(0.5, 0.0, -0.55, 1.0);
|
|
328
|
-
/**
|
|
329
|
-
* @internal
|
|
330
|
-
*/
|
|
331
|
-
this.globalRightIndexMiddlePosition = new Vector4(0.0, 0.0, 0.0, 1.0);
|
|
332
|
-
this.alphaMode = Constants.ALPHA_DISABLE;
|
|
333
|
-
this.backFaceCulling = false;
|
|
334
|
-
const textureUrl = Tools.GetAssetUrl(MRDLSliderBarMaterial.BLUE_GRADIENT_TEXTURE_URL);
|
|
335
|
-
this._blueGradientTexture = new Texture(textureUrl, this.getScene(), true, false, Texture.NEAREST_SAMPLINGMODE);
|
|
336
|
-
this._decalTexture = new Texture("", this.getScene());
|
|
337
|
-
this._reflectionMapTexture = new Texture("", this.getScene());
|
|
338
|
-
this._indirectEnvTexture = new Texture("", this.getScene());
|
|
339
|
-
}
|
|
340
|
-
needAlphaBlending() {
|
|
341
|
-
return false;
|
|
342
|
-
}
|
|
343
|
-
needAlphaTesting() {
|
|
344
|
-
return false;
|
|
345
|
-
}
|
|
346
|
-
getAlphaTestTexture() {
|
|
347
|
-
return null;
|
|
348
|
-
}
|
|
349
|
-
// Methods
|
|
350
|
-
isReadyForSubMesh(mesh, subMesh) {
|
|
351
|
-
const drawWrapper = subMesh._drawWrapper;
|
|
352
|
-
if (this.isFrozen) {
|
|
353
|
-
if (drawWrapper.effect && drawWrapper._wasPreviouslyReady) {
|
|
354
|
-
return true;
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
if (!subMesh.materialDefines) {
|
|
358
|
-
subMesh.materialDefines = new MRDLSliderBarMaterialDefines();
|
|
359
|
-
}
|
|
360
|
-
const defines = subMesh.materialDefines;
|
|
361
|
-
const scene = this.getScene();
|
|
362
|
-
if (!this._blueGradientTexture.isReady()) {
|
|
363
|
-
return false;
|
|
364
|
-
}
|
|
365
|
-
if (this._isReadyForSubMesh(subMesh)) {
|
|
366
|
-
return true;
|
|
367
|
-
}
|
|
368
|
-
const engine = scene.getEngine();
|
|
369
|
-
// Attribs
|
|
370
|
-
PrepareDefinesForAttributes(mesh, defines, false, false);
|
|
371
|
-
// Get correct effect
|
|
372
|
-
if (defines.isDirty) {
|
|
373
|
-
defines.markAsProcessed();
|
|
374
|
-
scene.resetCachedMaterial();
|
|
375
|
-
// Fallbacks
|
|
376
|
-
const fallbacks = new EffectFallbacks();
|
|
377
|
-
if (defines.FOG) {
|
|
378
|
-
fallbacks.addFallback(1, "FOG");
|
|
379
|
-
}
|
|
380
|
-
HandleFallbacksForShadows(defines, fallbacks);
|
|
381
|
-
defines.IMAGEPROCESSINGPOSTPROCESS = scene.imageProcessingConfiguration.applyByPostProcess;
|
|
382
|
-
//Attributes
|
|
383
|
-
const attribs = [VertexBuffer.PositionKind];
|
|
384
|
-
if (defines.NORMAL) {
|
|
385
|
-
attribs.push(VertexBuffer.NormalKind);
|
|
386
|
-
}
|
|
387
|
-
if (defines.UV1) {
|
|
388
|
-
attribs.push(VertexBuffer.UVKind);
|
|
389
|
-
}
|
|
390
|
-
if (defines.UV2) {
|
|
391
|
-
attribs.push(VertexBuffer.UV2Kind);
|
|
392
|
-
}
|
|
393
|
-
if (defines.VERTEXCOLOR) {
|
|
394
|
-
attribs.push(VertexBuffer.ColorKind);
|
|
395
|
-
}
|
|
396
|
-
if (defines.TANGENT) {
|
|
397
|
-
attribs.push(VertexBuffer.TangentKind);
|
|
398
|
-
}
|
|
399
|
-
PrepareAttributesForInstances(attribs, defines);
|
|
400
|
-
// Legacy browser patch
|
|
401
|
-
const shaderName = "mrdlSliderBar";
|
|
402
|
-
const join = defines.toString();
|
|
403
|
-
const uniforms = [
|
|
404
|
-
"world",
|
|
405
|
-
"viewProjection",
|
|
406
|
-
"cameraPosition",
|
|
407
|
-
"_Radius_",
|
|
408
|
-
"_Bevel_Front_",
|
|
409
|
-
"_Bevel_Front_Stretch_",
|
|
410
|
-
"_Bevel_Back_",
|
|
411
|
-
"_Bevel_Back_Stretch_",
|
|
412
|
-
"_Radius_Top_Left_",
|
|
413
|
-
"_Radius_Top_Right_",
|
|
414
|
-
"_Radius_Bottom_Left_",
|
|
415
|
-
"_Radius_Bottom_Right_",
|
|
416
|
-
"_Bulge_Enabled_",
|
|
417
|
-
"_Bulge_Height_",
|
|
418
|
-
"_Bulge_Radius_",
|
|
419
|
-
"_Sun_Intensity_",
|
|
420
|
-
"_Sun_Theta_",
|
|
421
|
-
"_Sun_Phi_",
|
|
422
|
-
"_Indirect_Diffuse_",
|
|
423
|
-
"_Albedo_",
|
|
424
|
-
"_Specular_",
|
|
425
|
-
"_Shininess_",
|
|
426
|
-
"_Sharpness_",
|
|
427
|
-
"_Subsurface_",
|
|
428
|
-
"_Left_Color_",
|
|
429
|
-
"_Right_Color_",
|
|
430
|
-
"_Reflection_",
|
|
431
|
-
"_Front_Reflect_",
|
|
432
|
-
"_Edge_Reflect_",
|
|
433
|
-
"_Power_",
|
|
434
|
-
"_Sky_Color_",
|
|
435
|
-
"_Horizon_Color_",
|
|
436
|
-
"_Ground_Color_",
|
|
437
|
-
"_Horizon_Power_",
|
|
438
|
-
"_Reflection_Map_",
|
|
439
|
-
"_Indirect_Environment_",
|
|
440
|
-
"_Width_",
|
|
441
|
-
"_Fuzz_",
|
|
442
|
-
"_Min_Fuzz_",
|
|
443
|
-
"_Clip_Fade_",
|
|
444
|
-
"_Hue_Shift_",
|
|
445
|
-
"_Saturation_Shift_",
|
|
446
|
-
"_Value_Shift_",
|
|
447
|
-
"_Blob_Position_",
|
|
448
|
-
"_Blob_Intensity_",
|
|
449
|
-
"_Blob_Near_Size_",
|
|
450
|
-
"_Blob_Far_Size_",
|
|
451
|
-
"_Blob_Near_Distance_",
|
|
452
|
-
"_Blob_Far_Distance_",
|
|
453
|
-
"_Blob_Fade_Length_",
|
|
454
|
-
"_Blob_Pulse_",
|
|
455
|
-
"_Blob_Fade_",
|
|
456
|
-
"_Blob_Texture_",
|
|
457
|
-
"_Blob_Position_2_",
|
|
458
|
-
"_Blob_Near_Size_2_",
|
|
459
|
-
"_Blob_Pulse_2_",
|
|
460
|
-
"_Blob_Fade_2_",
|
|
461
|
-
"_Left_Index_Pos_",
|
|
462
|
-
"_Right_Index_Pos_",
|
|
463
|
-
"_Left_Index_Middle_Pos_",
|
|
464
|
-
"_Right_Index_Middle_Pos_",
|
|
465
|
-
"_Decal_",
|
|
466
|
-
"_Decal_Scale_XY_",
|
|
467
|
-
"_Decal_Front_Only_",
|
|
468
|
-
"_Rim_Intensity_",
|
|
469
|
-
"_Rim_Texture_",
|
|
470
|
-
"_Rim_Hue_Shift_",
|
|
471
|
-
"_Rim_Saturation_Shift_",
|
|
472
|
-
"_Rim_Value_Shift_",
|
|
473
|
-
"_Iridescence_Intensity_",
|
|
474
|
-
"_Iridescence_Texture_",
|
|
475
|
-
"Use_Global_Left_Index",
|
|
476
|
-
"Use_Global_Right_Index",
|
|
477
|
-
"Global_Left_Index_Tip_Position",
|
|
478
|
-
"Global_Right_Index_Tip_Position",
|
|
479
|
-
"Global_Left_Thumb_Tip_Position",
|
|
480
|
-
"Global_Right_Thumb_Tip_Position",
|
|
481
|
-
"Global_Left_Index_Middle_Position;",
|
|
482
|
-
"Global_Right_Index_Middle_Position",
|
|
483
|
-
"Global_Left_Index_Tip_Proximity",
|
|
484
|
-
"Global_Right_Index_Tip_Proximity",
|
|
485
|
-
];
|
|
486
|
-
const samplers = ["_Rim_Texture_", "_Iridescence_Texture_"];
|
|
487
|
-
const uniformBuffers = [];
|
|
488
|
-
PrepareUniformsAndSamplersList({
|
|
489
|
-
uniformsNames: uniforms,
|
|
490
|
-
uniformBuffersNames: uniformBuffers,
|
|
491
|
-
samplers: samplers,
|
|
492
|
-
defines: defines,
|
|
493
|
-
maxSimultaneousLights: 4,
|
|
494
|
-
});
|
|
495
|
-
subMesh.setEffect(scene.getEngine().createEffect(shaderName, {
|
|
496
|
-
attributes: attribs,
|
|
497
|
-
uniformsNames: uniforms,
|
|
498
|
-
uniformBuffersNames: uniformBuffers,
|
|
499
|
-
samplers: samplers,
|
|
500
|
-
defines: join,
|
|
501
|
-
fallbacks: fallbacks,
|
|
502
|
-
onCompiled: this.onCompiled,
|
|
503
|
-
onError: this.onError,
|
|
504
|
-
indexParameters: { maxSimultaneousLights: 4 },
|
|
505
|
-
}, engine), defines, this._materialContext);
|
|
506
|
-
}
|
|
507
|
-
if (!subMesh.effect || !subMesh.effect.isReady()) {
|
|
508
|
-
return false;
|
|
509
|
-
}
|
|
510
|
-
defines._renderId = scene.getRenderId();
|
|
511
|
-
drawWrapper._wasPreviouslyReady = true;
|
|
512
|
-
return true;
|
|
513
|
-
}
|
|
514
|
-
bindForSubMesh(world, mesh, subMesh) {
|
|
515
|
-
const defines = subMesh.materialDefines;
|
|
516
|
-
if (!defines) {
|
|
517
|
-
return;
|
|
518
|
-
}
|
|
519
|
-
const effect = subMesh.effect;
|
|
520
|
-
if (!effect) {
|
|
521
|
-
return;
|
|
522
|
-
}
|
|
523
|
-
this._activeEffect = effect;
|
|
524
|
-
// Matrices
|
|
525
|
-
this.bindOnlyWorldMatrix(world);
|
|
526
|
-
this._activeEffect.setMatrix("viewProjection", this.getScene().getTransformMatrix());
|
|
527
|
-
this._activeEffect.setVector3("cameraPosition", this.getScene().activeCamera.position);
|
|
528
|
-
// "Round Rect"
|
|
529
|
-
this._activeEffect.setFloat("_Radius_", this.radius);
|
|
530
|
-
this._activeEffect.setFloat("_Bevel_Front_", this.bevelFront);
|
|
531
|
-
this._activeEffect.setFloat("_Bevel_Front_Stretch_", this.bevelFrontStretch);
|
|
532
|
-
this._activeEffect.setFloat("_Bevel_Back_", this.bevelBack);
|
|
533
|
-
this._activeEffect.setFloat("_Bevel_Back_Stretch_", this.bevelBackStretch);
|
|
534
|
-
// "Radii Multipliers"
|
|
535
|
-
this._activeEffect.setFloat("_Radius_Top_Left_", this.radiusTopLeft);
|
|
536
|
-
this._activeEffect.setFloat("_Radius_Top_Right_", this.radiusTopRight);
|
|
537
|
-
this._activeEffect.setFloat("_Radius_Bottom_Left_", this.radiusBottomLeft);
|
|
538
|
-
this._activeEffect.setFloat("_Radius_Bottom_Right_", this.radiusBottomRight);
|
|
539
|
-
// "Bulge"
|
|
540
|
-
this._activeEffect.setFloat("_Bulge_Enabled_", this.bulgeEnabled ? 1.0 : 0.0);
|
|
541
|
-
this._activeEffect.setFloat("_Bulge_Height_", this.bulgeHeight);
|
|
542
|
-
this._activeEffect.setFloat("_Bulge_Radius_", this.bulgeRadius);
|
|
543
|
-
// "Sun"
|
|
544
|
-
this._activeEffect.setFloat("_Sun_Intensity_", this.sunIntensity);
|
|
545
|
-
this._activeEffect.setFloat("_Sun_Theta_", this.sunTheta);
|
|
546
|
-
this._activeEffect.setFloat("_Sun_Phi_", this.sunPhi);
|
|
547
|
-
this._activeEffect.setFloat("_Indirect_Diffuse_", this.indirectDiffuse);
|
|
548
|
-
// "Diffuse And Specular"
|
|
549
|
-
this._activeEffect.setDirectColor4("_Albedo_", this.albedo);
|
|
550
|
-
this._activeEffect.setFloat("_Specular_", this.specular);
|
|
551
|
-
this._activeEffect.setFloat("_Shininess_", this.shininess);
|
|
552
|
-
this._activeEffect.setFloat("_Sharpness_", this.sharpness);
|
|
553
|
-
this._activeEffect.setFloat("_Subsurface_", this.subsurface);
|
|
554
|
-
// "Gradient"
|
|
555
|
-
this._activeEffect.setDirectColor4("_Left_Color_", this.leftGradientColor);
|
|
556
|
-
this._activeEffect.setDirectColor4("_Right_Color_", this.rightGradientColor);
|
|
557
|
-
// "Reflection"
|
|
558
|
-
this._activeEffect.setFloat("_Reflection_", this.reflection);
|
|
559
|
-
this._activeEffect.setFloat("_Front_Reflect_", this.frontReflect);
|
|
560
|
-
this._activeEffect.setFloat("_Edge_Reflect_", this.edgeReflect);
|
|
561
|
-
this._activeEffect.setFloat("_Power_", this.power);
|
|
562
|
-
// "Sky Environment"
|
|
563
|
-
//define SKY_ENABLED true;
|
|
564
|
-
this._activeEffect.setDirectColor4("_Sky_Color_", this.skyColor);
|
|
565
|
-
this._activeEffect.setDirectColor4("_Horizon_Color_", this.horizonColor);
|
|
566
|
-
this._activeEffect.setDirectColor4("_Ground_Color_", this.groundColor);
|
|
567
|
-
this._activeEffect.setFloat("_Horizon_Power_", this.horizonPower);
|
|
568
|
-
// "Mapped Environment"
|
|
569
|
-
//define ENV_ENABLE false;
|
|
570
|
-
this._activeEffect.setTexture("_Reflection_Map_", this._reflectionMapTexture);
|
|
571
|
-
this._activeEffect.setTexture("_Indirect_Environment_", this._indirectEnvTexture);
|
|
572
|
-
// "FingerOcclusion"
|
|
573
|
-
//define OCCLUSION_ENABLED false;
|
|
574
|
-
this._activeEffect.setFloat("_Width_", this.width);
|
|
575
|
-
this._activeEffect.setFloat("_Fuzz_", this.fuzz);
|
|
576
|
-
this._activeEffect.setFloat("_Min_Fuzz_", this.minFuzz);
|
|
577
|
-
this._activeEffect.setFloat("_Clip_Fade_", this.clipFade);
|
|
578
|
-
// "View Based Color Shift"
|
|
579
|
-
this._activeEffect.setFloat("_Hue_Shift_", this.hueShift);
|
|
580
|
-
this._activeEffect.setFloat("_Saturation_Shift_", this.saturationShift);
|
|
581
|
-
this._activeEffect.setFloat("_Value_Shift_", this.valueShift);
|
|
582
|
-
// "Blob"
|
|
583
|
-
//define BLOB_ENABLE false;
|
|
584
|
-
this._activeEffect.setVector3("_Blob_Position_", this.blobPosition);
|
|
585
|
-
this._activeEffect.setFloat("_Blob_Intensity_", this.blobIntensity);
|
|
586
|
-
this._activeEffect.setFloat("_Blob_Near_Size_", this.blobNearSize);
|
|
587
|
-
this._activeEffect.setFloat("_Blob_Far_Size_", this.blobFarSize);
|
|
588
|
-
this._activeEffect.setFloat("_Blob_Near_Distance_", this.blobNearDistance);
|
|
589
|
-
this._activeEffect.setFloat("_Blob_Far_Distance_", this.blobFarDistance);
|
|
590
|
-
this._activeEffect.setFloat("_Blob_Fade_Length_", this.blobFadeLength);
|
|
591
|
-
this._activeEffect.setFloat("_Blob_Pulse_", this.blobPulse);
|
|
592
|
-
this._activeEffect.setFloat("_Blob_Fade_", this.blobFade);
|
|
593
|
-
// "Blob Texture"
|
|
594
|
-
this._activeEffect.setTexture("_Blob_Texture_", this.blobTexture);
|
|
595
|
-
// "Blob 2"
|
|
596
|
-
//define BLOB_ENABLE_2 true;
|
|
597
|
-
this._activeEffect.setVector3("_Blob_Position_2_", this.blobPosition2);
|
|
598
|
-
this._activeEffect.setFloat("_Blob_Near_Size_2_", this.blobNearSize2);
|
|
599
|
-
this._activeEffect.setFloat("_Blob_Pulse_2_", this.blobPulse2);
|
|
600
|
-
this._activeEffect.setFloat("_Blob_Fade_2_", this.blobFade2);
|
|
601
|
-
// "Finger Positions"
|
|
602
|
-
this._activeEffect.setVector3("_Left_Index_Pos_", this.leftIndexPosition);
|
|
603
|
-
this._activeEffect.setVector3("_Right_Index_Pos_", this.rightIndexPosition);
|
|
604
|
-
this._activeEffect.setVector3("_Left_Index_Middle_Pos_", this.leftIndexMiddlePosition);
|
|
605
|
-
this._activeEffect.setVector3("_Right_Index_Middle_Pos_", this.rightIndexMiddlePosition);
|
|
606
|
-
// "Decal Texture"
|
|
607
|
-
//define DECAL_ENABLE false;
|
|
608
|
-
this._activeEffect.setTexture("_Decal_", this._decalTexture);
|
|
609
|
-
this._activeEffect.setVector2("_Decal_Scale_XY_", this.decalScaleXY);
|
|
610
|
-
this._activeEffect.setFloat("_Decal_Front_Only_", this.decalFrontOnly ? 1.0 : 0.0);
|
|
611
|
-
// "Rim Light"
|
|
612
|
-
this._activeEffect.setFloat("_Rim_Intensity_", this.rimIntensity);
|
|
613
|
-
this._activeEffect.setTexture("_Rim_Texture_", this._blueGradientTexture);
|
|
614
|
-
this._activeEffect.setFloat("_Rim_Hue_Shift_", this.rimHueShift);
|
|
615
|
-
this._activeEffect.setFloat("_Rim_Saturation_Shift_", this.rimSaturationShift);
|
|
616
|
-
this._activeEffect.setFloat("_Rim_Value_Shift_", this.rimValueShift);
|
|
617
|
-
// "Iridescence"
|
|
618
|
-
//define IRIDESCENCE_ENABLED true;
|
|
619
|
-
this._activeEffect.setFloat("_Iridescence_Intensity_", this.iridescenceIntensity);
|
|
620
|
-
this._activeEffect.setTexture("_Iridescence_Texture_", this._blueGradientTexture);
|
|
621
|
-
// Global inputs
|
|
622
|
-
this._activeEffect.setFloat("Use_Global_Left_Index", this.useGlobalLeftIndex);
|
|
623
|
-
this._activeEffect.setFloat("Use_Global_Right_Index", this.useGlobalRightIndex);
|
|
624
|
-
this._activeEffect.setVector4("Global_Left_Index_Tip_Position", this.globalLeftIndexTipPosition);
|
|
625
|
-
this._activeEffect.setVector4("Global_Right_Index_Tip_Position", this.globaRightIndexTipPosition);
|
|
626
|
-
this._activeEffect.setVector4("Global_Left_Thumb_Tip_Position", this.globalLeftThumbTipPosition);
|
|
627
|
-
this._activeEffect.setVector4("Global_Right_Thumb_Tip_Position", this.globalRightThumbTipPosition);
|
|
628
|
-
this._activeEffect.setVector4("Global_Left_Index_Middle_Position", this.globalLeftIndexMiddlePosition);
|
|
629
|
-
this._activeEffect.setVector4("Global_Right_Index_Middle_Position", this.globalRightIndexMiddlePosition);
|
|
630
|
-
this._activeEffect.setFloat("Global_Left_Index_Tip_Proximity", this.globalLeftIndexTipProximity);
|
|
631
|
-
this._activeEffect.setFloat("Global_Right_Index_Tip_Proximity", this.globalRightIndexTipProximity);
|
|
632
|
-
this._afterBind(mesh, this._activeEffect, subMesh);
|
|
633
|
-
}
|
|
634
|
-
/**
|
|
635
|
-
* Get the list of animatables in the material.
|
|
636
|
-
* @returns the list of animatables object used in the material
|
|
637
|
-
*/
|
|
638
|
-
getAnimatables() {
|
|
639
|
-
return [];
|
|
640
|
-
}
|
|
641
|
-
dispose(forceDisposeEffect) {
|
|
642
|
-
super.dispose(forceDisposeEffect);
|
|
643
|
-
this._reflectionMapTexture.dispose();
|
|
644
|
-
this._indirectEnvTexture.dispose();
|
|
645
|
-
this._blueGradientTexture.dispose();
|
|
646
|
-
this._decalTexture.dispose();
|
|
647
|
-
}
|
|
648
|
-
clone(name) {
|
|
649
|
-
return SerializationHelper.Clone(() => new MRDLSliderBarMaterial(name, this.getScene()), this);
|
|
650
|
-
}
|
|
651
|
-
serialize() {
|
|
652
|
-
const serializationObject = super.serialize();
|
|
653
|
-
serializationObject.customType = "BABYLON.MRDLSliderBarMaterial";
|
|
654
|
-
return serializationObject;
|
|
655
|
-
}
|
|
656
|
-
getClassName() {
|
|
657
|
-
return "MRDLSliderBarMaterial";
|
|
658
|
-
}
|
|
659
|
-
// Statics
|
|
660
|
-
static Parse(source, scene, rootUrl) {
|
|
661
|
-
return SerializationHelper.Parse(() => new MRDLSliderBarMaterial(source.name, scene), source, scene, rootUrl);
|
|
662
|
-
}
|
|
663
|
-
}
|
|
664
1
|
/**
|
|
665
|
-
*
|
|
2
|
+
* Re-exports the pure implementation and applies the runtime registration side effect.
|
|
3
|
+
* Import "./mrdlSliderBarMaterial.pure" for tree-shakeable, side-effect-free usage.
|
|
666
4
|
*/
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
serialize()
|
|
673
|
-
], MRDLSliderBarMaterial.prototype, "bevelFront", void 0);
|
|
674
|
-
__decorate([
|
|
675
|
-
serialize()
|
|
676
|
-
], MRDLSliderBarMaterial.prototype, "bevelFrontStretch", void 0);
|
|
677
|
-
__decorate([
|
|
678
|
-
serialize()
|
|
679
|
-
], MRDLSliderBarMaterial.prototype, "bevelBack", void 0);
|
|
680
|
-
__decorate([
|
|
681
|
-
serialize()
|
|
682
|
-
], MRDLSliderBarMaterial.prototype, "bevelBackStretch", void 0);
|
|
683
|
-
__decorate([
|
|
684
|
-
serialize()
|
|
685
|
-
], MRDLSliderBarMaterial.prototype, "radiusTopLeft", void 0);
|
|
686
|
-
__decorate([
|
|
687
|
-
serialize()
|
|
688
|
-
], MRDLSliderBarMaterial.prototype, "radiusTopRight", void 0);
|
|
689
|
-
__decorate([
|
|
690
|
-
serialize()
|
|
691
|
-
], MRDLSliderBarMaterial.prototype, "radiusBottomLeft", void 0);
|
|
692
|
-
__decorate([
|
|
693
|
-
serialize()
|
|
694
|
-
], MRDLSliderBarMaterial.prototype, "radiusBottomRight", void 0);
|
|
695
|
-
__decorate([
|
|
696
|
-
serialize()
|
|
697
|
-
], MRDLSliderBarMaterial.prototype, "bulgeEnabled", void 0);
|
|
698
|
-
__decorate([
|
|
699
|
-
serialize()
|
|
700
|
-
], MRDLSliderBarMaterial.prototype, "bulgeHeight", void 0);
|
|
701
|
-
__decorate([
|
|
702
|
-
serialize()
|
|
703
|
-
], MRDLSliderBarMaterial.prototype, "bulgeRadius", void 0);
|
|
704
|
-
__decorate([
|
|
705
|
-
serialize()
|
|
706
|
-
], MRDLSliderBarMaterial.prototype, "sunIntensity", void 0);
|
|
707
|
-
__decorate([
|
|
708
|
-
serialize()
|
|
709
|
-
], MRDLSliderBarMaterial.prototype, "sunTheta", void 0);
|
|
710
|
-
__decorate([
|
|
711
|
-
serialize()
|
|
712
|
-
], MRDLSliderBarMaterial.prototype, "sunPhi", void 0);
|
|
713
|
-
__decorate([
|
|
714
|
-
serialize()
|
|
715
|
-
], MRDLSliderBarMaterial.prototype, "indirectDiffuse", void 0);
|
|
716
|
-
__decorate([
|
|
717
|
-
serialize()
|
|
718
|
-
], MRDLSliderBarMaterial.prototype, "albedo", void 0);
|
|
719
|
-
__decorate([
|
|
720
|
-
serialize()
|
|
721
|
-
], MRDLSliderBarMaterial.prototype, "specular", void 0);
|
|
722
|
-
__decorate([
|
|
723
|
-
serialize()
|
|
724
|
-
], MRDLSliderBarMaterial.prototype, "shininess", void 0);
|
|
725
|
-
__decorate([
|
|
726
|
-
serialize()
|
|
727
|
-
], MRDLSliderBarMaterial.prototype, "sharpness", void 0);
|
|
728
|
-
__decorate([
|
|
729
|
-
serialize()
|
|
730
|
-
], MRDLSliderBarMaterial.prototype, "subsurface", void 0);
|
|
731
|
-
__decorate([
|
|
732
|
-
serialize()
|
|
733
|
-
], MRDLSliderBarMaterial.prototype, "leftGradientColor", void 0);
|
|
734
|
-
__decorate([
|
|
735
|
-
serialize()
|
|
736
|
-
], MRDLSliderBarMaterial.prototype, "rightGradientColor", void 0);
|
|
737
|
-
__decorate([
|
|
738
|
-
serialize()
|
|
739
|
-
], MRDLSliderBarMaterial.prototype, "reflection", void 0);
|
|
740
|
-
__decorate([
|
|
741
|
-
serialize()
|
|
742
|
-
], MRDLSliderBarMaterial.prototype, "frontReflect", void 0);
|
|
743
|
-
__decorate([
|
|
744
|
-
serialize()
|
|
745
|
-
], MRDLSliderBarMaterial.prototype, "edgeReflect", void 0);
|
|
746
|
-
__decorate([
|
|
747
|
-
serialize()
|
|
748
|
-
], MRDLSliderBarMaterial.prototype, "power", void 0);
|
|
749
|
-
__decorate([
|
|
750
|
-
serialize()
|
|
751
|
-
], MRDLSliderBarMaterial.prototype, "skyColor", void 0);
|
|
752
|
-
__decorate([
|
|
753
|
-
serialize()
|
|
754
|
-
], MRDLSliderBarMaterial.prototype, "horizonColor", void 0);
|
|
755
|
-
__decorate([
|
|
756
|
-
serialize()
|
|
757
|
-
], MRDLSliderBarMaterial.prototype, "groundColor", void 0);
|
|
758
|
-
__decorate([
|
|
759
|
-
serialize()
|
|
760
|
-
], MRDLSliderBarMaterial.prototype, "horizonPower", void 0);
|
|
761
|
-
__decorate([
|
|
762
|
-
serialize()
|
|
763
|
-
], MRDLSliderBarMaterial.prototype, "width", void 0);
|
|
764
|
-
__decorate([
|
|
765
|
-
serialize()
|
|
766
|
-
], MRDLSliderBarMaterial.prototype, "fuzz", void 0);
|
|
767
|
-
__decorate([
|
|
768
|
-
serialize()
|
|
769
|
-
], MRDLSliderBarMaterial.prototype, "minFuzz", void 0);
|
|
770
|
-
__decorate([
|
|
771
|
-
serialize()
|
|
772
|
-
], MRDLSliderBarMaterial.prototype, "clipFade", void 0);
|
|
773
|
-
__decorate([
|
|
774
|
-
serialize()
|
|
775
|
-
], MRDLSliderBarMaterial.prototype, "hueShift", void 0);
|
|
776
|
-
__decorate([
|
|
777
|
-
serialize()
|
|
778
|
-
], MRDLSliderBarMaterial.prototype, "saturationShift", void 0);
|
|
779
|
-
__decorate([
|
|
780
|
-
serialize()
|
|
781
|
-
], MRDLSliderBarMaterial.prototype, "valueShift", void 0);
|
|
782
|
-
__decorate([
|
|
783
|
-
serialize()
|
|
784
|
-
], MRDLSliderBarMaterial.prototype, "blobPosition", void 0);
|
|
785
|
-
__decorate([
|
|
786
|
-
serialize()
|
|
787
|
-
], MRDLSliderBarMaterial.prototype, "blobIntensity", void 0);
|
|
788
|
-
__decorate([
|
|
789
|
-
serialize()
|
|
790
|
-
], MRDLSliderBarMaterial.prototype, "blobNearSize", void 0);
|
|
791
|
-
__decorate([
|
|
792
|
-
serialize()
|
|
793
|
-
], MRDLSliderBarMaterial.prototype, "blobFarSize", void 0);
|
|
794
|
-
__decorate([
|
|
795
|
-
serialize()
|
|
796
|
-
], MRDLSliderBarMaterial.prototype, "blobNearDistance", void 0);
|
|
797
|
-
__decorate([
|
|
798
|
-
serialize()
|
|
799
|
-
], MRDLSliderBarMaterial.prototype, "blobFarDistance", void 0);
|
|
800
|
-
__decorate([
|
|
801
|
-
serialize()
|
|
802
|
-
], MRDLSliderBarMaterial.prototype, "blobFadeLength", void 0);
|
|
803
|
-
__decorate([
|
|
804
|
-
serialize()
|
|
805
|
-
], MRDLSliderBarMaterial.prototype, "blobPulse", void 0);
|
|
806
|
-
__decorate([
|
|
807
|
-
serialize()
|
|
808
|
-
], MRDLSliderBarMaterial.prototype, "blobFade", void 0);
|
|
809
|
-
__decorate([
|
|
810
|
-
serialize()
|
|
811
|
-
], MRDLSliderBarMaterial.prototype, "blobPosition2", void 0);
|
|
812
|
-
__decorate([
|
|
813
|
-
serialize()
|
|
814
|
-
], MRDLSliderBarMaterial.prototype, "blobNearSize2", void 0);
|
|
815
|
-
__decorate([
|
|
816
|
-
serialize()
|
|
817
|
-
], MRDLSliderBarMaterial.prototype, "blobPulse2", void 0);
|
|
818
|
-
__decorate([
|
|
819
|
-
serialize()
|
|
820
|
-
], MRDLSliderBarMaterial.prototype, "blobFade2", void 0);
|
|
821
|
-
__decorate([
|
|
822
|
-
serialize()
|
|
823
|
-
], MRDLSliderBarMaterial.prototype, "blobTexture", void 0);
|
|
824
|
-
__decorate([
|
|
825
|
-
serialize()
|
|
826
|
-
], MRDLSliderBarMaterial.prototype, "leftIndexPosition", void 0);
|
|
827
|
-
__decorate([
|
|
828
|
-
serialize()
|
|
829
|
-
], MRDLSliderBarMaterial.prototype, "rightIndexPosition", void 0);
|
|
830
|
-
__decorate([
|
|
831
|
-
serialize()
|
|
832
|
-
], MRDLSliderBarMaterial.prototype, "leftIndexMiddlePosition", void 0);
|
|
833
|
-
__decorate([
|
|
834
|
-
serialize()
|
|
835
|
-
], MRDLSliderBarMaterial.prototype, "rightIndexMiddlePosition", void 0);
|
|
836
|
-
__decorate([
|
|
837
|
-
serialize()
|
|
838
|
-
], MRDLSliderBarMaterial.prototype, "decalScaleXY", void 0);
|
|
839
|
-
__decorate([
|
|
840
|
-
serialize()
|
|
841
|
-
], MRDLSliderBarMaterial.prototype, "decalFrontOnly", void 0);
|
|
842
|
-
__decorate([
|
|
843
|
-
serialize()
|
|
844
|
-
], MRDLSliderBarMaterial.prototype, "rimIntensity", void 0);
|
|
845
|
-
__decorate([
|
|
846
|
-
serialize()
|
|
847
|
-
], MRDLSliderBarMaterial.prototype, "rimHueShift", void 0);
|
|
848
|
-
__decorate([
|
|
849
|
-
serialize()
|
|
850
|
-
], MRDLSliderBarMaterial.prototype, "rimSaturationShift", void 0);
|
|
851
|
-
__decorate([
|
|
852
|
-
serialize()
|
|
853
|
-
], MRDLSliderBarMaterial.prototype, "rimValueShift", void 0);
|
|
854
|
-
__decorate([
|
|
855
|
-
serialize()
|
|
856
|
-
], MRDLSliderBarMaterial.prototype, "iridescenceIntensity", void 0);
|
|
857
|
-
RegisterClass("BABYLON.GUI.MRDLSliderBarMaterial", MRDLSliderBarMaterial);
|
|
5
|
+
export * from "./mrdlSliderBarMaterial.pure.js";
|
|
6
|
+
import "./shaders/mrdlSliderBar.fragment.js";
|
|
7
|
+
import "./shaders/mrdlSliderBar.vertex.js";
|
|
8
|
+
import { RegisterMRDLSliderBarMaterial } from "./mrdlSliderBarMaterial.pure.js";
|
|
9
|
+
RegisterMRDLSliderBarMaterial();
|
|
858
10
|
//# sourceMappingURL=mrdlSliderBarMaterial.js.map
|