@onerjs/core 8.26.4 → 8.26.5

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.
Files changed (137) hide show
  1. package/Engines/abstractEngine.js +2 -2
  2. package/Engines/abstractEngine.js.map +1 -1
  3. package/FrameGraph/Tasks/Rendering/objectRendererTask.js +6 -0
  4. package/FrameGraph/Tasks/Rendering/objectRendererTask.js.map +1 -1
  5. package/FrameGraph/frameGraphContext.d.ts +2 -1
  6. package/FrameGraph/frameGraphContext.js +4 -1
  7. package/FrameGraph/frameGraphContext.js.map +1 -1
  8. package/Lights/Clustered/clusteredLightContainer.d.ts +1 -1
  9. package/Lights/Clustered/clusteredLightContainer.js +4 -5
  10. package/Lights/Clustered/clusteredLightContainer.js.map +1 -1
  11. package/Lights/pointLight.js +4 -4
  12. package/Lights/pointLight.js.map +1 -1
  13. package/Lights/rectAreaLight.js +4 -4
  14. package/Lights/rectAreaLight.js.map +1 -1
  15. package/Lights/spotLight.js +2 -2
  16. package/Lights/spotLight.js.map +1 -1
  17. package/Materials/Background/backgroundMaterial.d.ts +19 -91
  18. package/Materials/Background/backgroundMaterial.js +17 -245
  19. package/Materials/Background/backgroundMaterial.js.map +1 -1
  20. package/Materials/Node/Blocks/Dual/lightBlock.js +15 -4
  21. package/Materials/Node/Blocks/Dual/lightBlock.js.map +1 -1
  22. package/Materials/Node/Blocks/PBR/pbrMetallicRoughnessBlock.js +28 -5
  23. package/Materials/Node/Blocks/PBR/pbrMetallicRoughnessBlock.js.map +1 -1
  24. package/Materials/Node/nodeMaterial.d.ts +57 -69
  25. package/Materials/Node/nodeMaterial.js +9 -86
  26. package/Materials/Node/nodeMaterial.js.map +1 -1
  27. package/Materials/Node/nodeMaterialBuildState.d.ts +3 -1
  28. package/Materials/Node/nodeMaterialBuildState.js +35 -15
  29. package/Materials/Node/nodeMaterialBuildState.js.map +1 -1
  30. package/Materials/PBR/index.d.ts +5 -0
  31. package/Materials/PBR/index.js +5 -0
  32. package/Materials/PBR/index.js.map +1 -1
  33. package/Materials/PBR/openPbrMaterial.d.ts +998 -0
  34. package/Materials/PBR/openPbrMaterial.js +2069 -0
  35. package/Materials/PBR/openPbrMaterial.js.map +1 -0
  36. package/Materials/PBR/pbrBaseMaterial.d.ts +57 -43
  37. package/Materials/PBR/pbrBaseMaterial.js +21 -304
  38. package/Materials/PBR/pbrBaseMaterial.js.map +1 -1
  39. package/Materials/PBR/pbrMaterial.d.ts +0 -78
  40. package/Materials/PBR/pbrMaterial.js +0 -110
  41. package/Materials/PBR/pbrMaterial.js.map +1 -1
  42. package/Materials/floatingOriginMatrixOverrides.d.ts +3 -0
  43. package/Materials/floatingOriginMatrixOverrides.js +91 -0
  44. package/Materials/floatingOriginMatrixOverrides.js.map +1 -0
  45. package/Materials/imageProcessing.d.ts +65 -0
  46. package/Materials/imageProcessing.js +162 -0
  47. package/Materials/imageProcessing.js.map +1 -0
  48. package/Materials/imageProcessingConfiguration.defines.d.ts +25 -0
  49. package/Materials/imageProcessingConfiguration.defines.js +27 -0
  50. package/Materials/imageProcessingConfiguration.defines.js.map +1 -1
  51. package/Materials/index.d.ts +2 -0
  52. package/Materials/index.js +2 -0
  53. package/Materials/index.js.map +1 -1
  54. package/Materials/material.d.ts +14 -0
  55. package/Materials/material.js +14 -0
  56. package/Materials/material.js.map +1 -1
  57. package/Materials/materialHelper.functions.d.ts +53 -0
  58. package/Materials/materialHelper.functions.js +297 -0
  59. package/Materials/materialHelper.functions.js.map +1 -1
  60. package/Materials/standardMaterial.d.ts +57 -121
  61. package/Materials/standardMaterial.js +21 -250
  62. package/Materials/standardMaterial.js.map +1 -1
  63. package/Materials/uv.defines.d.ts +22 -0
  64. package/Materials/uv.defines.js +24 -0
  65. package/Materials/uv.defines.js.map +1 -0
  66. package/Meshes/GaussianSplatting/gaussianSplattingMesh.js +1 -0
  67. package/Meshes/GaussianSplatting/gaussianSplattingMesh.js.map +1 -1
  68. package/Misc/decorators.d.ts +7 -0
  69. package/Misc/decorators.js +34 -0
  70. package/Misc/decorators.js.map +1 -1
  71. package/Particles/Node/Blocks/Emitters/createParticleBlock.js +10 -1
  72. package/Particles/Node/Blocks/Emitters/createParticleBlock.js.map +1 -1
  73. package/Particles/Node/Blocks/index.d.ts +2 -0
  74. package/Particles/Node/Blocks/index.js +2 -0
  75. package/Particles/Node/Blocks/index.js.map +1 -1
  76. package/Particles/Node/Blocks/particleInputBlock.js +4 -1
  77. package/Particles/Node/Blocks/particleInputBlock.js.map +1 -1
  78. package/Particles/Node/Blocks/particleLocalVariableBlock.d.ts +38 -0
  79. package/Particles/Node/Blocks/particleLocalVariableBlock.js +108 -0
  80. package/Particles/Node/Blocks/particleLocalVariableBlock.js.map +1 -0
  81. package/Particles/Node/Blocks/particleVectorLengthBlock.d.ts +26 -0
  82. package/Particles/Node/Blocks/particleVectorLengthBlock.js +50 -0
  83. package/Particles/Node/Blocks/particleVectorLengthBlock.js.map +1 -0
  84. package/Rendering/IBLShadows/iblShadowsPluginMaterial.d.ts +2 -1
  85. package/Rendering/IBLShadows/iblShadowsPluginMaterial.js +45 -0
  86. package/Rendering/IBLShadows/iblShadowsPluginMaterial.js.map +1 -1
  87. package/Rendering/IBLShadows/iblShadowsRenderPipeline.js +2 -1
  88. package/Rendering/IBLShadows/iblShadowsRenderPipeline.js.map +1 -1
  89. package/Rendering/geometryBufferRenderer.js +6 -4
  90. package/Rendering/geometryBufferRenderer.js.map +1 -1
  91. package/Rendering/iblCdfGenerator.js +28 -20
  92. package/Rendering/iblCdfGenerator.js.map +1 -1
  93. package/Rendering/reflectiveShadowMap.d.ts +3 -3
  94. package/Shaders/ShadersInclude/backgroundUboDeclaration.js +1 -1
  95. package/Shaders/ShadersInclude/backgroundUboDeclaration.js.map +1 -1
  96. package/Shaders/ShadersInclude/clusteredLightingFunctions.js +3 -1
  97. package/Shaders/ShadersInclude/clusteredLightingFunctions.js.map +1 -1
  98. package/Shaders/ShadersInclude/defaultUboDeclaration.js +1 -1
  99. package/Shaders/ShadersInclude/defaultUboDeclaration.js.map +1 -1
  100. package/Shaders/ShadersInclude/hdrFilteringFunctions.js +34 -0
  101. package/Shaders/ShadersInclude/hdrFilteringFunctions.js.map +1 -1
  102. package/Shaders/ShadersInclude/helperFunctions.js +1 -1
  103. package/Shaders/ShadersInclude/helperFunctions.js.map +1 -1
  104. package/Shaders/ShadersInclude/importanceSampling.js +4 -0
  105. package/Shaders/ShadersInclude/importanceSampling.js.map +1 -1
  106. package/Shaders/ShadersInclude/lightsFragmentFunctions.js +1 -0
  107. package/Shaders/ShadersInclude/lightsFragmentFunctions.js.map +1 -1
  108. package/Shaders/ShadersInclude/pbrBRDFFunctions.js +1 -1
  109. package/Shaders/ShadersInclude/pbrBRDFFunctions.js.map +1 -1
  110. package/Shaders/ShadersInclude/pbrClusteredLightingFunctions.js +1 -0
  111. package/Shaders/ShadersInclude/pbrClusteredLightingFunctions.js.map +1 -1
  112. package/Shaders/ShadersInclude/pbrDirectLightingFunctions.js +3 -1
  113. package/Shaders/ShadersInclude/pbrDirectLightingFunctions.js.map +1 -1
  114. package/Shaders/ShadersInclude/pbrHelperFunctions.js +2 -0
  115. package/Shaders/ShadersInclude/pbrHelperFunctions.js.map +1 -1
  116. package/Shaders/ShadersInclude/pbrUboDeclaration.js +1 -1
  117. package/Shaders/ShadersInclude/pbrUboDeclaration.js.map +1 -1
  118. package/ShadersWGSL/ShadersInclude/backgroundUboDeclaration.js +1 -1
  119. package/ShadersWGSL/ShadersInclude/backgroundUboDeclaration.js.map +1 -1
  120. package/ShadersWGSL/ShadersInclude/defaultUboDeclaration.js +1 -1
  121. package/ShadersWGSL/ShadersInclude/defaultUboDeclaration.js.map +1 -1
  122. package/ShadersWGSL/ShadersInclude/hdrFilteringFunctions.js +28 -0
  123. package/ShadersWGSL/ShadersInclude/hdrFilteringFunctions.js.map +1 -1
  124. package/ShadersWGSL/ShadersInclude/importanceSampling.js +4 -0
  125. package/ShadersWGSL/ShadersInclude/importanceSampling.js.map +1 -1
  126. package/ShadersWGSL/ShadersInclude/pbrBRDFFunctions.js +1 -1
  127. package/ShadersWGSL/ShadersInclude/pbrBRDFFunctions.js.map +1 -1
  128. package/ShadersWGSL/ShadersInclude/pbrDirectLightingFunctions.js +3 -1
  129. package/ShadersWGSL/ShadersInclude/pbrDirectLightingFunctions.js.map +1 -1
  130. package/ShadersWGSL/ShadersInclude/pbrHelperFunctions.js +2 -0
  131. package/ShadersWGSL/ShadersInclude/pbrHelperFunctions.js.map +1 -1
  132. package/ShadersWGSL/ShadersInclude/pbrUboDeclaration.js +1 -1
  133. package/ShadersWGSL/ShadersInclude/pbrUboDeclaration.js.map +1 -1
  134. package/package.json +1 -1
  135. package/scene.d.ts +21 -0
  136. package/scene.js +29 -3
  137. package/scene.js.map +1 -1
@@ -0,0 +1,162 @@
1
+ /* eslint-disable @typescript-eslint/naming-convention */
2
+ import { serializeAsImageProcessingConfiguration } from "../Misc/decorators.js";
3
+ /**
4
+ * Mixin to add Image processing defines to your material defines
5
+ * @internal
6
+ */
7
+ export function ImageProcessingMixin(base) {
8
+ return class extends base {
9
+ /**
10
+ * Constructor for the ImageProcessingMixin.
11
+ * @param args - arguments to pass to the base class constructor
12
+ */
13
+ constructor(...args) {
14
+ super(...args);
15
+ // Decorators don't work on this annonymous class
16
+ // so I'm setting this up manually.
17
+ serializeAsImageProcessingConfiguration.call(this, this, "_imageProcessingConfiguration");
18
+ }
19
+ /**
20
+ * Gets the image processing configuration used either in this material.
21
+ */
22
+ get imageProcessingConfiguration() {
23
+ return this._imageProcessingConfiguration;
24
+ }
25
+ /**
26
+ * Sets the Default image processing configuration used either in the this material.
27
+ *
28
+ * If sets to null, the scene one is in use.
29
+ */
30
+ set imageProcessingConfiguration(value) {
31
+ this._attachImageProcessingConfiguration(value);
32
+ // Ensure the effect will be rebuilt.
33
+ if (this._markAllSubMeshesAsImageProcessingDirty) {
34
+ this._markAllSubMeshesAsImageProcessingDirty();
35
+ }
36
+ }
37
+ /**
38
+ * Attaches a new image processing configuration to the Standard Material.
39
+ * @param configuration
40
+ */
41
+ _attachImageProcessingConfiguration(configuration) {
42
+ if (configuration === this._imageProcessingConfiguration) {
43
+ return;
44
+ }
45
+ // Detaches observer
46
+ if (this._imageProcessingConfiguration && this._imageProcessingObserver) {
47
+ this._imageProcessingConfiguration.onUpdateParameters.remove(this._imageProcessingObserver);
48
+ }
49
+ // Pick the scene configuration if needed
50
+ if (!configuration && this.getScene) {
51
+ this._imageProcessingConfiguration = this.getScene().imageProcessingConfiguration;
52
+ }
53
+ else if (configuration) {
54
+ this._imageProcessingConfiguration = configuration;
55
+ }
56
+ // Attaches observer
57
+ if (this._imageProcessingConfiguration) {
58
+ this._imageProcessingObserver = this._imageProcessingConfiguration.onUpdateParameters.add(() => {
59
+ // Ensure the effect will be rebuilt.
60
+ if (this._markAllSubMeshesAsImageProcessingDirty) {
61
+ this._markAllSubMeshesAsImageProcessingDirty();
62
+ }
63
+ });
64
+ }
65
+ }
66
+ /**
67
+ * Gets whether the color curves effect is enabled.
68
+ */
69
+ get cameraColorCurvesEnabled() {
70
+ return this.imageProcessingConfiguration.colorCurvesEnabled;
71
+ }
72
+ /**
73
+ * Sets whether the color curves effect is enabled.
74
+ */
75
+ set cameraColorCurvesEnabled(value) {
76
+ this.imageProcessingConfiguration.colorCurvesEnabled = value;
77
+ }
78
+ /**
79
+ * Gets whether the color grading effect is enabled.
80
+ */
81
+ get cameraColorGradingEnabled() {
82
+ return this.imageProcessingConfiguration.colorGradingEnabled;
83
+ }
84
+ /**
85
+ * Gets whether the color grading effect is enabled.
86
+ */
87
+ set cameraColorGradingEnabled(value) {
88
+ this.imageProcessingConfiguration.colorGradingEnabled = value;
89
+ }
90
+ /**
91
+ * Gets whether tonemapping is enabled or not.
92
+ */
93
+ get cameraToneMappingEnabled() {
94
+ return this._imageProcessingConfiguration.toneMappingEnabled;
95
+ }
96
+ /**
97
+ * Sets whether tonemapping is enabled or not
98
+ */
99
+ set cameraToneMappingEnabled(value) {
100
+ this._imageProcessingConfiguration.toneMappingEnabled = value;
101
+ }
102
+ /**
103
+ * The camera exposure used on this material.
104
+ * This property is here and not in the camera to allow controlling exposure without full screen post process.
105
+ * This corresponds to a photographic exposure.
106
+ */
107
+ get cameraExposure() {
108
+ return this._imageProcessingConfiguration.exposure;
109
+ }
110
+ /**
111
+ * The camera exposure used on this material.
112
+ * This property is here and not in the camera to allow controlling exposure without full screen post process.
113
+ * This corresponds to a photographic exposure.
114
+ */
115
+ set cameraExposure(value) {
116
+ this._imageProcessingConfiguration.exposure = value;
117
+ }
118
+ /**
119
+ * Gets The camera contrast used on this material.
120
+ */
121
+ get cameraContrast() {
122
+ return this._imageProcessingConfiguration.contrast;
123
+ }
124
+ /**
125
+ * Sets The camera contrast used on this material.
126
+ */
127
+ set cameraContrast(value) {
128
+ this._imageProcessingConfiguration.contrast = value;
129
+ }
130
+ /**
131
+ * Gets the Color Grading 2D Lookup Texture.
132
+ */
133
+ get cameraColorGradingTexture() {
134
+ return this._imageProcessingConfiguration.colorGradingTexture;
135
+ }
136
+ /**
137
+ * Sets the Color Grading 2D Lookup Texture.
138
+ */
139
+ set cameraColorGradingTexture(value) {
140
+ this._imageProcessingConfiguration.colorGradingTexture = value;
141
+ }
142
+ /**
143
+ * The color grading curves provide additional color adjustmnent that is applied after any color grading transform (3D LUT).
144
+ * They allow basic adjustment of saturation and small exposure adjustments, along with color filter tinting to provide white balance adjustment or more stylistic effects.
145
+ * These are similar to controls found in many professional imaging or colorist software. The global controls are applied to the entire image. For advanced tuning, extra controls are provided to adjust the shadow, midtone and highlight areas of the image;
146
+ * corresponding to low luminance, medium luminance, and high luminance areas respectively.
147
+ */
148
+ get cameraColorCurves() {
149
+ return this._imageProcessingConfiguration.colorCurves;
150
+ }
151
+ /**
152
+ * The color grading curves provide additional color adjustment that is applied after any color grading transform (3D LUT).
153
+ * They allow basic adjustment of saturation and small exposure adjustments, along with color filter tinting to provide white balance adjustment or more stylistic effects.
154
+ * These are similar to controls found in many professional imaging or colorist software. The global controls are applied to the entire image. For advanced tuning, extra controls are provided to adjust the shadow, midtone and highlight areas of the image;
155
+ * corresponding to low luminance, medium luminance, and high luminance areas respectively.
156
+ */
157
+ set cameraColorCurves(value) {
158
+ this._imageProcessingConfiguration.colorCurves = value;
159
+ }
160
+ };
161
+ }
162
+ //# sourceMappingURL=imageProcessing.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"imageProcessing.js","sourceRoot":"","sources":["../../../../dev/core/src/Materials/imageProcessing.ts"],"names":[],"mappings":"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","sourcesContent":["/* eslint-disable @typescript-eslint/naming-convention */\r\nimport { serializeAsImageProcessingConfiguration } from \"../Misc/decorators\";\r\nimport type { Nullable } from \"../types\";\r\nimport type { ImageProcessingConfiguration } from \"./imageProcessingConfiguration\";\r\nimport type { Observer } from \"../Misc/observable\";\r\nimport type { BaseTexture } from \"../Materials/Textures/baseTexture\";\r\nimport type { ColorCurves } from \"../Materials/colorCurves\";\r\n\r\ntype ImageProcessingMixinConstructor<T = {}> = new (...args: any[]) => T;\r\n\r\n/**\r\n * Mixin to add Image processing defines to your material defines\r\n * @internal\r\n */\r\nexport function ImageProcessingMixin<Tbase extends ImageProcessingMixinConstructor>(base: Tbase) {\r\n return class extends base {\r\n /**\r\n * Constructor for the ImageProcessingMixin.\r\n * @param args - arguments to pass to the base class constructor\r\n */\r\n constructor(...args: any[]) {\r\n super(...args);\r\n // Decorators don't work on this annonymous class\r\n // so I'm setting this up manually.\r\n serializeAsImageProcessingConfiguration.call(this, this, \"_imageProcessingConfiguration\");\r\n }\r\n /**\r\n * Default configuration related to image processing available in the standard Material.\r\n */\r\n public _imageProcessingConfiguration: ImageProcessingConfiguration;\r\n\r\n /**\r\n * Gets the image processing configuration used either in this material.\r\n */\r\n public get imageProcessingConfiguration(): ImageProcessingConfiguration {\r\n return this._imageProcessingConfiguration;\r\n }\r\n\r\n /**\r\n * Sets the Default image processing configuration used either in the this material.\r\n *\r\n * If sets to null, the scene one is in use.\r\n */\r\n public set imageProcessingConfiguration(value: ImageProcessingConfiguration) {\r\n this._attachImageProcessingConfiguration(value);\r\n\r\n // Ensure the effect will be rebuilt.\r\n if ((this as any)._markAllSubMeshesAsImageProcessingDirty) {\r\n (this as any)._markAllSubMeshesAsImageProcessingDirty();\r\n }\r\n }\r\n\r\n /**\r\n * Keep track of the image processing observer to allow dispose and replace.\r\n */\r\n public _imageProcessingObserver: Nullable<Observer<ImageProcessingConfiguration>>;\r\n\r\n /**\r\n * Attaches a new image processing configuration to the Standard Material.\r\n * @param configuration\r\n */\r\n public _attachImageProcessingConfiguration(configuration: Nullable<ImageProcessingConfiguration>): void {\r\n if (configuration === this._imageProcessingConfiguration) {\r\n return;\r\n }\r\n\r\n // Detaches observer\r\n if (this._imageProcessingConfiguration && this._imageProcessingObserver) {\r\n this._imageProcessingConfiguration.onUpdateParameters.remove(this._imageProcessingObserver);\r\n }\r\n\r\n // Pick the scene configuration if needed\r\n if (!configuration && (this as any).getScene) {\r\n this._imageProcessingConfiguration = (this as any).getScene().imageProcessingConfiguration;\r\n } else if (configuration) {\r\n this._imageProcessingConfiguration = configuration;\r\n }\r\n\r\n // Attaches observer\r\n if (this._imageProcessingConfiguration) {\r\n this._imageProcessingObserver = this._imageProcessingConfiguration.onUpdateParameters.add(() => {\r\n // Ensure the effect will be rebuilt.\r\n if ((this as any)._markAllSubMeshesAsImageProcessingDirty) {\r\n (this as any)._markAllSubMeshesAsImageProcessingDirty();\r\n }\r\n });\r\n }\r\n }\r\n\r\n /**\r\n * Gets whether the color curves effect is enabled.\r\n */\r\n public get cameraColorCurvesEnabled(): boolean {\r\n return this.imageProcessingConfiguration.colorCurvesEnabled;\r\n }\r\n /**\r\n * Sets whether the color curves effect is enabled.\r\n */\r\n public set cameraColorCurvesEnabled(value: boolean) {\r\n this.imageProcessingConfiguration.colorCurvesEnabled = value;\r\n }\r\n\r\n /**\r\n * Gets whether the color grading effect is enabled.\r\n */\r\n public get cameraColorGradingEnabled(): boolean {\r\n return this.imageProcessingConfiguration.colorGradingEnabled;\r\n }\r\n /**\r\n * Gets whether the color grading effect is enabled.\r\n */\r\n public set cameraColorGradingEnabled(value: boolean) {\r\n this.imageProcessingConfiguration.colorGradingEnabled = value;\r\n }\r\n\r\n /**\r\n * Gets whether tonemapping is enabled or not.\r\n */\r\n public get cameraToneMappingEnabled(): boolean {\r\n return this._imageProcessingConfiguration.toneMappingEnabled;\r\n }\r\n /**\r\n * Sets whether tonemapping is enabled or not\r\n */\r\n public set cameraToneMappingEnabled(value: boolean) {\r\n this._imageProcessingConfiguration.toneMappingEnabled = value;\r\n }\r\n\r\n /**\r\n * The camera exposure used on this material.\r\n * This property is here and not in the camera to allow controlling exposure without full screen post process.\r\n * This corresponds to a photographic exposure.\r\n */\r\n public get cameraExposure(): number {\r\n return this._imageProcessingConfiguration.exposure;\r\n }\r\n /**\r\n * The camera exposure used on this material.\r\n * This property is here and not in the camera to allow controlling exposure without full screen post process.\r\n * This corresponds to a photographic exposure.\r\n */\r\n public set cameraExposure(value: number) {\r\n this._imageProcessingConfiguration.exposure = value;\r\n }\r\n\r\n /**\r\n * Gets The camera contrast used on this material.\r\n */\r\n public get cameraContrast(): number {\r\n return this._imageProcessingConfiguration.contrast;\r\n }\r\n\r\n /**\r\n * Sets The camera contrast used on this material.\r\n */\r\n public set cameraContrast(value: number) {\r\n this._imageProcessingConfiguration.contrast = value;\r\n }\r\n\r\n /**\r\n * Gets the Color Grading 2D Lookup Texture.\r\n */\r\n public get cameraColorGradingTexture(): Nullable<BaseTexture> {\r\n return this._imageProcessingConfiguration.colorGradingTexture;\r\n }\r\n /**\r\n * Sets the Color Grading 2D Lookup Texture.\r\n */\r\n public set cameraColorGradingTexture(value: Nullable<BaseTexture>) {\r\n this._imageProcessingConfiguration.colorGradingTexture = value;\r\n }\r\n\r\n /**\r\n * The color grading curves provide additional color adjustmnent that is applied after any color grading transform (3D LUT).\r\n * They allow basic adjustment of saturation and small exposure adjustments, along with color filter tinting to provide white balance adjustment or more stylistic effects.\r\n * These are similar to controls found in many professional imaging or colorist software. The global controls are applied to the entire image. For advanced tuning, extra controls are provided to adjust the shadow, midtone and highlight areas of the image;\r\n * corresponding to low luminance, medium luminance, and high luminance areas respectively.\r\n */\r\n public get cameraColorCurves(): Nullable<ColorCurves> {\r\n return this._imageProcessingConfiguration.colorCurves;\r\n }\r\n /**\r\n * The color grading curves provide additional color adjustment that is applied after any color grading transform (3D LUT).\r\n * They allow basic adjustment of saturation and small exposure adjustments, along with color filter tinting to provide white balance adjustment or more stylistic effects.\r\n * These are similar to controls found in many professional imaging or colorist software. The global controls are applied to the entire image. For advanced tuning, extra controls are provided to adjust the shadow, midtone and highlight areas of the image;\r\n * corresponding to low luminance, medium luminance, and high luminance areas respectively.\r\n */\r\n public set cameraColorCurves(value: Nullable<ColorCurves>) {\r\n this._imageProcessingConfiguration.colorCurves = value;\r\n }\r\n };\r\n}\r\n"]}
@@ -21,6 +21,30 @@ export interface IImageProcessingConfigurationDefines {
21
21
  IMAGEPROCESSINGPOSTPROCESS: boolean;
22
22
  SKIPFINALCOLORCLAMP: boolean;
23
23
  }
24
+ type ImageProcessingDefinesMixinConstructor<T = {}> = new (...args: any[]) => T;
25
+ /**
26
+ * Mixin to add Image processing defines to your material defines
27
+ * @internal
28
+ */
29
+ export declare function ImageProcessingDefinesMixin<Tbase extends ImageProcessingDefinesMixinConstructor>(base: Tbase): {
30
+ new (...args: any[]): {
31
+ IMAGEPROCESSING: boolean;
32
+ VIGNETTE: boolean;
33
+ VIGNETTEBLENDMODEMULTIPLY: boolean;
34
+ VIGNETTEBLENDMODEOPAQUE: boolean;
35
+ TONEMAPPING: number;
36
+ CONTRAST: boolean;
37
+ COLORCURVES: boolean;
38
+ COLORGRADING: boolean;
39
+ COLORGRADING3D: boolean;
40
+ SAMPLER3DGREENDEPTH: boolean;
41
+ SAMPLER3DBGRMAP: boolean;
42
+ DITHER: boolean;
43
+ IMAGEPROCESSINGPOSTPROCESS: boolean;
44
+ SKIPFINALCOLORCLAMP: boolean;
45
+ EXPOSURE: boolean;
46
+ };
47
+ } & Tbase;
24
48
  /**
25
49
  * @internal
26
50
  */
@@ -42,3 +66,4 @@ export declare class ImageProcessingConfigurationDefines extends MaterialDefines
42
66
  SKIPFINALCOLORCLAMP: boolean;
43
67
  constructor();
44
68
  }
69
+ export {};
@@ -1,4 +1,31 @@
1
1
  import { MaterialDefines } from "./materialDefines.js";
2
+ /**
3
+ * Mixin to add Image processing defines to your material defines
4
+ * @internal
5
+ */
6
+ export function ImageProcessingDefinesMixin(base) {
7
+ return class extends base {
8
+ constructor() {
9
+ super(...arguments);
10
+ // Implement all members of IImageProcessingConfigurationDefines here
11
+ this.IMAGEPROCESSING = false;
12
+ this.VIGNETTE = false;
13
+ this.VIGNETTEBLENDMODEMULTIPLY = false;
14
+ this.VIGNETTEBLENDMODEOPAQUE = false;
15
+ this.TONEMAPPING = 0;
16
+ this.CONTRAST = false;
17
+ this.COLORCURVES = false;
18
+ this.COLORGRADING = false;
19
+ this.COLORGRADING3D = false;
20
+ this.SAMPLER3DGREENDEPTH = false;
21
+ this.SAMPLER3DBGRMAP = false;
22
+ this.DITHER = false;
23
+ this.IMAGEPROCESSINGPOSTPROCESS = false;
24
+ this.SKIPFINALCOLORCLAMP = false;
25
+ this.EXPOSURE = false;
26
+ }
27
+ };
28
+ }
2
29
  /**
3
30
  * @internal
4
31
  */
@@ -1 +1 @@
1
- {"version":3,"file":"imageProcessingConfiguration.defines.js","sourceRoot":"","sources":["../../../../dev/core/src/Materials/imageProcessingConfiguration.defines.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAwBpD;;GAEG;AACH,MAAM,OAAO,mCAAoC,SAAQ,eAAe;IAiBpE;QACI,KAAK,EAAE,CAAC;QAjBL,oBAAe,GAAG,KAAK,CAAC;QACxB,aAAQ,GAAG,KAAK,CAAC;QACjB,8BAAyB,GAAG,KAAK,CAAC;QAClC,4BAAuB,GAAG,KAAK,CAAC;QAChC,gBAAW,GAAG,CAAC,CAAC;QAChB,aAAQ,GAAG,KAAK,CAAC;QACjB,gBAAW,GAAG,KAAK,CAAC;QACpB,iBAAY,GAAG,KAAK,CAAC;QACrB,mBAAc,GAAG,KAAK,CAAC;QACvB,wBAAmB,GAAG,KAAK,CAAC;QAC5B,oBAAe,GAAG,KAAK,CAAC;QACxB,WAAM,GAAG,KAAK,CAAC;QACf,+BAA0B,GAAG,KAAK,CAAC;QACnC,aAAQ,GAAG,KAAK,CAAC;QACjB,wBAAmB,GAAG,KAAK,CAAC;QAI/B,IAAI,CAAC,OAAO,EAAE,CAAC;IACnB,CAAC;CACJ","sourcesContent":["import { MaterialDefines } from \"./materialDefines\";\r\n/**\r\n * Interface to follow in your material defines to integrate easily the\r\n * Image processing functions.\r\n * @internal\r\n */\r\nexport interface IImageProcessingConfigurationDefines {\r\n IMAGEPROCESSING: boolean;\r\n VIGNETTE: boolean;\r\n VIGNETTEBLENDMODEMULTIPLY: boolean;\r\n VIGNETTEBLENDMODEOPAQUE: boolean;\r\n TONEMAPPING: number;\r\n CONTRAST: boolean;\r\n EXPOSURE: boolean;\r\n COLORCURVES: boolean;\r\n COLORGRADING: boolean;\r\n COLORGRADING3D: boolean;\r\n SAMPLER3DGREENDEPTH: boolean;\r\n SAMPLER3DBGRMAP: boolean;\r\n DITHER: boolean;\r\n IMAGEPROCESSINGPOSTPROCESS: boolean;\r\n SKIPFINALCOLORCLAMP: boolean;\r\n}\r\n\r\n/**\r\n * @internal\r\n */\r\nexport class ImageProcessingConfigurationDefines extends MaterialDefines implements IImageProcessingConfigurationDefines {\r\n public IMAGEPROCESSING = false;\r\n public VIGNETTE = false;\r\n public VIGNETTEBLENDMODEMULTIPLY = false;\r\n public VIGNETTEBLENDMODEOPAQUE = false;\r\n public TONEMAPPING = 0;\r\n public CONTRAST = false;\r\n public COLORCURVES = false;\r\n public COLORGRADING = false;\r\n public COLORGRADING3D = false;\r\n public SAMPLER3DGREENDEPTH = false;\r\n public SAMPLER3DBGRMAP = false;\r\n public DITHER = false;\r\n public IMAGEPROCESSINGPOSTPROCESS = false;\r\n public EXPOSURE = false;\r\n public SKIPFINALCOLORCLAMP = false;\r\n\r\n constructor() {\r\n super();\r\n this.rebuild();\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"imageProcessingConfiguration.defines.js","sourceRoot":"","sources":["../../../../dev/core/src/Materials/imageProcessingConfiguration.defines.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AA0BpD;;;GAGG;AACH,MAAM,UAAU,2BAA2B,CAAuD,IAAW;IACzG,OAAO,KAAM,SAAQ,IAAI;QAAlB;;YACH,qEAAqE;YAC9D,oBAAe,GAAG,KAAK,CAAC;YACxB,aAAQ,GAAG,KAAK,CAAC;YACjB,8BAAyB,GAAG,KAAK,CAAC;YAClC,4BAAuB,GAAG,KAAK,CAAC;YAChC,gBAAW,GAAG,CAAC,CAAC;YAChB,aAAQ,GAAG,KAAK,CAAC;YACjB,gBAAW,GAAG,KAAK,CAAC;YACpB,iBAAY,GAAG,KAAK,CAAC;YACrB,mBAAc,GAAG,KAAK,CAAC;YACvB,wBAAmB,GAAG,KAAK,CAAC;YAC5B,oBAAe,GAAG,KAAK,CAAC;YACxB,WAAM,GAAG,KAAK,CAAC;YACf,+BAA0B,GAAG,KAAK,CAAC;YACnC,wBAAmB,GAAG,KAAK,CAAC;YAC5B,aAAQ,GAAG,KAAK,CAAC;QAC5B,CAAC;KAAA,CAAC;AACN,CAAC;AAED;;GAEG;AACH,MAAM,OAAO,mCAAoC,SAAQ,eAAe;IAiBpE;QACI,KAAK,EAAE,CAAC;QAjBL,oBAAe,GAAG,KAAK,CAAC;QACxB,aAAQ,GAAG,KAAK,CAAC;QACjB,8BAAyB,GAAG,KAAK,CAAC;QAClC,4BAAuB,GAAG,KAAK,CAAC;QAChC,gBAAW,GAAG,CAAC,CAAC;QAChB,aAAQ,GAAG,KAAK,CAAC;QACjB,gBAAW,GAAG,KAAK,CAAC;QACpB,iBAAY,GAAG,KAAK,CAAC;QACrB,mBAAc,GAAG,KAAK,CAAC;QACvB,wBAAmB,GAAG,KAAK,CAAC;QAC5B,oBAAe,GAAG,KAAK,CAAC;QACxB,WAAM,GAAG,KAAK,CAAC;QACf,+BAA0B,GAAG,KAAK,CAAC;QACnC,aAAQ,GAAG,KAAK,CAAC;QACjB,wBAAmB,GAAG,KAAK,CAAC;QAI/B,IAAI,CAAC,OAAO,EAAE,CAAC;IACnB,CAAC;CACJ","sourcesContent":["import { MaterialDefines } from \"./materialDefines\";\r\n/**\r\n * Interface to follow in your material defines to integrate easily the\r\n * Image processing functions.\r\n * @internal\r\n */\r\nexport interface IImageProcessingConfigurationDefines {\r\n IMAGEPROCESSING: boolean;\r\n VIGNETTE: boolean;\r\n VIGNETTEBLENDMODEMULTIPLY: boolean;\r\n VIGNETTEBLENDMODEOPAQUE: boolean;\r\n TONEMAPPING: number;\r\n CONTRAST: boolean;\r\n EXPOSURE: boolean;\r\n COLORCURVES: boolean;\r\n COLORGRADING: boolean;\r\n COLORGRADING3D: boolean;\r\n SAMPLER3DGREENDEPTH: boolean;\r\n SAMPLER3DBGRMAP: boolean;\r\n DITHER: boolean;\r\n IMAGEPROCESSINGPOSTPROCESS: boolean;\r\n SKIPFINALCOLORCLAMP: boolean;\r\n}\r\n\r\ntype ImageProcessingDefinesMixinConstructor<T = {}> = new (...args: any[]) => T;\r\n\r\n/**\r\n * Mixin to add Image processing defines to your material defines\r\n * @internal\r\n */\r\nexport function ImageProcessingDefinesMixin<Tbase extends ImageProcessingDefinesMixinConstructor>(base: Tbase) {\r\n return class extends base implements IImageProcessingConfigurationDefines {\r\n // Implement all members of IImageProcessingConfigurationDefines here\r\n public IMAGEPROCESSING = false;\r\n public VIGNETTE = false;\r\n public VIGNETTEBLENDMODEMULTIPLY = false;\r\n public VIGNETTEBLENDMODEOPAQUE = false;\r\n public TONEMAPPING = 0;\r\n public CONTRAST = false;\r\n public COLORCURVES = false;\r\n public COLORGRADING = false;\r\n public COLORGRADING3D = false;\r\n public SAMPLER3DGREENDEPTH = false;\r\n public SAMPLER3DBGRMAP = false;\r\n public DITHER = false;\r\n public IMAGEPROCESSINGPOSTPROCESS = false;\r\n public SKIPFINALCOLORCLAMP = false;\r\n public EXPOSURE = false;\r\n };\r\n}\r\n\r\n/**\r\n * @internal\r\n */\r\nexport class ImageProcessingConfigurationDefines extends MaterialDefines implements IImageProcessingConfigurationDefines {\r\n public IMAGEPROCESSING = false;\r\n public VIGNETTE = false;\r\n public VIGNETTEBLENDMODEMULTIPLY = false;\r\n public VIGNETTEBLENDMODEOPAQUE = false;\r\n public TONEMAPPING = 0;\r\n public CONTRAST = false;\r\n public COLORCURVES = false;\r\n public COLORGRADING = false;\r\n public COLORGRADING3D = false;\r\n public SAMPLER3DGREENDEPTH = false;\r\n public SAMPLER3DBGRMAP = false;\r\n public DITHER = false;\r\n public IMAGEPROCESSINGPOSTPROCESS = false;\r\n public EXPOSURE = false;\r\n public SKIPFINALCOLORCLAMP = false;\r\n\r\n constructor() {\r\n super();\r\n this.rebuild();\r\n }\r\n}\r\n"]}
@@ -4,6 +4,7 @@ export * from "./iEffectFallbacks.js";
4
4
  export * from "./effectFallbacks.js";
5
5
  export * from "./effect.js";
6
6
  export * from "./fresnelParameters.js";
7
+ export * from "./imageProcessing.js";
7
8
  export * from "./imageProcessingConfiguration.js";
8
9
  export * from "./material.js";
9
10
  export * from "./materialDefines.js";
@@ -39,6 +40,7 @@ export * from "./GaussianSplatting/gaussianSplattingMaterial.js";
39
40
  export * from "./materialHelper.functions.js";
40
41
  export * from "./materialHelper.geometryrendering.js";
41
42
  export * from "./materialStencilState.js";
43
+ export * from "./uv.defines.js";
42
44
  import "./material.decalMap.js";
43
45
  export * from "../Shaders/default.fragment.js";
44
46
  export * from "../Shaders/default.vertex.js";
@@ -5,6 +5,7 @@ export * from "./iEffectFallbacks.js";
5
5
  export * from "./effectFallbacks.js";
6
6
  export * from "./effect.js";
7
7
  export * from "./fresnelParameters.js";
8
+ export * from "./imageProcessing.js";
8
9
  export * from "./imageProcessingConfiguration.js";
9
10
  export * from "./material.js";
10
11
  export * from "./materialDefines.js";
@@ -40,6 +41,7 @@ export * from "./GaussianSplatting/gaussianSplattingMaterial.js";
40
41
  export * from "./materialHelper.functions.js";
41
42
  export * from "./materialHelper.geometryrendering.js";
42
43
  export * from "./materialStencilState.js";
44
+ export * from "./uv.defines.js";
43
45
  import "./material.decalMap.js";
44
46
  // async-loaded shaders
45
47
  // StandardMaterial
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../dev/core/src/Materials/index.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAC7D,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC;AACpC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mCAAmC,CAAC;AAClD,cAAc,kCAAkC,CAAC;AACjD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yCAAyC,CAAC;AACxD,cAAc,yCAAyC,CAAC;AACxD,cAAc,6CAA6C,CAAC;AAC5D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+CAA+C,CAAC;AAC9D,cAAc,4BAA4B,CAAC;AAC3C,cAAc,oCAAoC,CAAC;AACnD,cAAc,wBAAwB,CAAC;AACvC,OAAO,qBAAqB,CAAC;AAE7B,uBAAuB;AAEvB,mBAAmB;AACnB,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAE9C,2BAA2B;AAC3B,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,qCAAqC,CAAC;AACpD,cAAc,mCAAmC,CAAC","sourcesContent":["/* eslint-disable @typescript-eslint/no-restricted-imports */\r\nexport * from \"./Background/index\";\r\nexport * from \"./colorCurves\";\r\nexport * from \"./iEffectFallbacks\";\r\nexport * from \"./effectFallbacks\";\r\nexport * from \"./effect\";\r\nexport * from \"./fresnelParameters\";\r\nexport * from \"./imageProcessingConfiguration\";\r\nexport * from \"./material\";\r\nexport * from \"./materialDefines\";\r\nexport * from \"./clipPlaneMaterialHelper\";\r\nexport * from \"./materialHelper\";\r\nexport * from \"./multiMaterial\";\r\nexport * from \"./Occlusion/index\";\r\nexport * from \"./PBR/index\";\r\nexport * from \"./pushMaterial\";\r\nexport * from \"./shaderLanguage\";\r\nexport * from \"./shaderMaterial\";\r\nexport * from \"./standardMaterial\";\r\nexport * from \"./Textures/index\";\r\nexport * from \"./uniformBuffer\";\r\nexport * from \"./materialFlags\";\r\nexport * from \"./Node/index\";\r\nexport * from \"./effectRenderer\";\r\nexport * from \"./shadowDepthWrapper\";\r\nexport * from \"./drawWrapper.functions\";\r\nexport * from \"./drawWrapper\";\r\nexport * from \"./materialPluginBase\";\r\nexport * from \"./materialPluginManager\";\r\nexport * from \"./materialPluginEvent\";\r\nexport * from \"./material.detailMapConfiguration\";\r\nexport * from \"./material.decalMapConfiguration\";\r\nexport * from \"./materialPluginFactoryExport\";\r\nexport * from \"./GreasedLine/greasedLinePluginMaterial\";\r\nexport * from \"./GreasedLine/greasedLineSimpleMaterial\";\r\nexport * from \"./GreasedLine/greasedLineMaterialInterfaces\";\r\nexport * from \"./GreasedLine/greasedLineMaterialDefaults\";\r\nexport * from \"./meshDebugPluginMaterial\";\r\nexport * from \"./GaussianSplatting/gaussianSplattingMaterial\";\r\nexport * from \"./materialHelper.functions\";\r\nexport * from \"./materialHelper.geometryrendering\";\r\nexport * from \"./materialStencilState\";\r\nimport \"./material.decalMap\";\r\n\r\n// async-loaded shaders\r\n\r\n// StandardMaterial\r\nexport * from \"../Shaders/default.fragment\";\r\nexport * from \"../Shaders/default.vertex\";\r\nexport * from \"../ShadersWGSL/default.fragment\";\r\nexport * from \"../ShadersWGSL/default.vertex\";\r\n\r\n// GreasedLineSimplMaterial\r\nexport * from \"../Shaders/greasedLine.fragment\";\r\nexport * from \"../Shaders/greasedLine.vertex\";\r\nexport * from \"../ShadersWGSL/greasedLine.fragment\";\r\nexport * from \"../ShadersWGSL/greasedLine.vertex\";\r\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../dev/core/src/Materials/index.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAC7D,cAAc,oBAAoB,CAAC;AACnC,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,YAAY,CAAC;AAC3B,cAAc,mBAAmB,CAAC;AAClC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mCAAmC,CAAC;AAClD,cAAc,kCAAkC,CAAC;AACjD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,yCAAyC,CAAC;AACxD,cAAc,yCAAyC,CAAC;AACxD,cAAc,6CAA6C,CAAC;AAC5D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+CAA+C,CAAC;AAC9D,cAAc,4BAA4B,CAAC;AAC3C,cAAc,oCAAoC,CAAC;AACnD,cAAc,wBAAwB,CAAC;AACvC,cAAc,cAAc,CAAC;AAC7B,OAAO,qBAAqB,CAAC;AAE7B,uBAAuB;AAEvB,mBAAmB;AACnB,cAAc,6BAA6B,CAAC;AAC5C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAE9C,2BAA2B;AAC3B,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,qCAAqC,CAAC;AACpD,cAAc,mCAAmC,CAAC","sourcesContent":["/* eslint-disable @typescript-eslint/no-restricted-imports */\r\nexport * from \"./Background/index\";\r\nexport * from \"./colorCurves\";\r\nexport * from \"./iEffectFallbacks\";\r\nexport * from \"./effectFallbacks\";\r\nexport * from \"./effect\";\r\nexport * from \"./fresnelParameters\";\r\nexport * from \"./imageProcessing\";\r\nexport * from \"./imageProcessingConfiguration\";\r\nexport * from \"./material\";\r\nexport * from \"./materialDefines\";\r\nexport * from \"./clipPlaneMaterialHelper\";\r\nexport * from \"./materialHelper\";\r\nexport * from \"./multiMaterial\";\r\nexport * from \"./Occlusion/index\";\r\nexport * from \"./PBR/index\";\r\nexport * from \"./pushMaterial\";\r\nexport * from \"./shaderLanguage\";\r\nexport * from \"./shaderMaterial\";\r\nexport * from \"./standardMaterial\";\r\nexport * from \"./Textures/index\";\r\nexport * from \"./uniformBuffer\";\r\nexport * from \"./materialFlags\";\r\nexport * from \"./Node/index\";\r\nexport * from \"./effectRenderer\";\r\nexport * from \"./shadowDepthWrapper\";\r\nexport * from \"./drawWrapper.functions\";\r\nexport * from \"./drawWrapper\";\r\nexport * from \"./materialPluginBase\";\r\nexport * from \"./materialPluginManager\";\r\nexport * from \"./materialPluginEvent\";\r\nexport * from \"./material.detailMapConfiguration\";\r\nexport * from \"./material.decalMapConfiguration\";\r\nexport * from \"./materialPluginFactoryExport\";\r\nexport * from \"./GreasedLine/greasedLinePluginMaterial\";\r\nexport * from \"./GreasedLine/greasedLineSimpleMaterial\";\r\nexport * from \"./GreasedLine/greasedLineMaterialInterfaces\";\r\nexport * from \"./GreasedLine/greasedLineMaterialDefaults\";\r\nexport * from \"./meshDebugPluginMaterial\";\r\nexport * from \"./GaussianSplatting/gaussianSplattingMaterial\";\r\nexport * from \"./materialHelper.functions\";\r\nexport * from \"./materialHelper.geometryrendering\";\r\nexport * from \"./materialStencilState\";\r\nexport * from \"./uv.defines\";\r\nimport \"./material.decalMap\";\r\n\r\n// async-loaded shaders\r\n\r\n// StandardMaterial\r\nexport * from \"../Shaders/default.fragment\";\r\nexport * from \"../Shaders/default.vertex\";\r\nexport * from \"../ShadersWGSL/default.fragment\";\r\nexport * from \"../ShadersWGSL/default.vertex\";\r\n\r\n// GreasedLineSimplMaterial\r\nexport * from \"../Shaders/greasedLine.fragment\";\r\nexport * from \"../Shaders/greasedLine.vertex\";\r\nexport * from \"../ShadersWGSL/greasedLine.fragment\";\r\nexport * from \"../ShadersWGSL/greasedLine.vertex\";\r\n"]}
@@ -154,6 +154,20 @@ export declare class Material implements IAnimatable, IClipPlanesHolder {
154
154
  * Details of the algorithm can be found here: https://blog.selfshadow.com/publications/blending-in-detail/
155
155
  */
156
156
  static readonly MATERIAL_NORMALBLENDMETHOD_RNM = 1;
157
+ /**
158
+ * PBRMaterialLightFalloff Physical: light is falling off following the inverse squared distance law.
159
+ */
160
+ static readonly LIGHTFALLOFF_PHYSICAL = 0;
161
+ /**
162
+ * PBRMaterialLightFalloff gltf: light is falling off as described in the gltf moving to PBR document
163
+ * to enhance interoperability with other engines.
164
+ */
165
+ static readonly LIGHTFALLOFF_GLTF = 1;
166
+ /**
167
+ * PBRMaterialLightFalloff Standard: light is falling off like in the standard material
168
+ * to enhance interoperability with other materials.
169
+ */
170
+ static readonly LIGHTFALLOFF_STANDARD = 2;
157
171
  /**
158
172
  * Event observable which raises global events common to all materials (like MaterialPluginEvent.Created)
159
173
  */
@@ -1595,6 +1595,20 @@ Material.MATERIAL_NORMALBLENDMETHOD_WHITEOUT = 0;
1595
1595
  * Details of the algorithm can be found here: https://blog.selfshadow.com/publications/blending-in-detail/
1596
1596
  */
1597
1597
  Material.MATERIAL_NORMALBLENDMETHOD_RNM = 1;
1598
+ /**
1599
+ * PBRMaterialLightFalloff Physical: light is falling off following the inverse squared distance law.
1600
+ */
1601
+ Material.LIGHTFALLOFF_PHYSICAL = 0;
1602
+ /**
1603
+ * PBRMaterialLightFalloff gltf: light is falling off as described in the gltf moving to PBR document
1604
+ * to enhance interoperability with other engines.
1605
+ */
1606
+ Material.LIGHTFALLOFF_GLTF = 1;
1607
+ /**
1608
+ * PBRMaterialLightFalloff Standard: light is falling off like in the standard material
1609
+ * to enhance interoperability with other materials.
1610
+ */
1611
+ Material.LIGHTFALLOFF_STANDARD = 2;
1598
1612
  /**
1599
1613
  * Event observable which raises global events common to all materials (like MaterialPluginEvent.Created)
1600
1614
  */