babylonjs-gui 7.32.0 → 7.32.2

Sign up to get free protection for your applications and to get access to all the features.
package/babylon.gui.d.ts CHANGED
@@ -3852,6 +3852,18 @@ declare module BABYLON.GUI {
3852
3852
 
3853
3853
 
3854
3854
 
3855
+ /**
3856
+ * Interface used to define options to create an AdvancedDynamicTexture
3857
+ */
3858
+ export interface IAdvancedDynamicTextureOptions extends BABYLON.IDynamicTextureOptions {
3859
+ /**
3860
+ * Indicates whether the ADT will be used autonomously. In this mode:
3861
+ * - _checkUpdate() is not called
3862
+ * - the layer is not rendered (so, the ADT is not visible)
3863
+ * It's up to the user to perform the required calls manually to update the ADT.
3864
+ */
3865
+ useStandalone?: boolean;
3866
+ }
3855
3867
  /**
3856
3868
  * Class used to create texture to support 2D GUI elements
3857
3869
  * @see https://doc.babylonjs.com/features/featuresDeepDive/gui/gui
@@ -3861,6 +3873,8 @@ declare module BABYLON.GUI {
3861
3873
  static SnippetUrl: string;
3862
3874
  /** Indicates if some optimizations can be performed in GUI GPU management (the downside is additional memory/GPU texture memory used) */
3863
3875
  static AllowGPUOptimizations: boolean;
3876
+ /** Indicates whether the ADT is used autonomously */
3877
+ readonly useStandalone: boolean;
3864
3878
  /** Snippet ID if the content was created from the snippet server */
3865
3879
  snippetId: string;
3866
3880
  /** BABYLON.Observable that fires when the GUI is ready */
@@ -3965,6 +3979,10 @@ declare module BABYLON.GUI {
3965
3979
  * Defaults to false.
3966
3980
  */
3967
3981
  disableTabNavigation: boolean;
3982
+ /**
3983
+ * A boolean indicating whether controls can be picked/clicked on or not. Defaults to false.
3984
+ */
3985
+ disablePicking: boolean;
3968
3986
  /**
3969
3987
  * If set to true, the POINTERTAP event type will be used for "click", instead of POINTERUP
3970
3988
  */
@@ -4074,13 +4092,9 @@ declare module BABYLON.GUI {
4074
4092
  /**
4075
4093
  * Creates a new AdvancedDynamicTexture
4076
4094
  * @param name defines the name of the texture
4077
- * @param width defines the width of the texture
4078
- * @param height defines the height of the texture
4079
- * @param scene defines the hosting scene
4080
- * @param generateMipMaps defines a boolean indicating if mipmaps must be generated (false by default)
4081
- * @param samplingMode defines the texture sampling mode (Texture.NEAREST_SAMPLINGMODE by default)
4082
- * @param invertY defines if the texture needs to be inverted on the y axis during loading (true by default)
4095
+ * @param options The options to be used when constructing the ADT
4083
4096
  */
4097
+ constructor(name: string, options?: IAdvancedDynamicTextureOptions);
4084
4098
  constructor(name: string, width?: number, height?: number, scene?: BABYLON.Nullable<BABYLON.Scene>, generateMipMaps?: boolean, samplingMode?: number, invertY?: boolean);
4085
4099
  /**
4086
4100
  * Get the current class name of the texture useful for serialization or dynamic coding.
@@ -4159,7 +4173,8 @@ declare module BABYLON.GUI {
4159
4173
  * @returns the projected position with Z
4160
4174
  */
4161
4175
  getProjectedPositionWithZ(position: BABYLON.Vector3, worldMatrix: BABYLON.Matrix): BABYLON.Vector3;
4162
- private _checkUpdate;
4176
+ /** @internal */
4177
+ _checkUpdate(camera: BABYLON.Nullable<BABYLON.Camera>, skipUpdate?: boolean): void;
4163
4178
  private _clearMeasure;
4164
4179
  private _render;
4165
4180
  /**
@@ -4337,12 +4352,12 @@ declare module BABYLON.GUI {
4337
4352
  * LayerMask is set through advancedTexture.layer.layerMask
4338
4353
  * @param name defines name for the texture
4339
4354
  * @param foreground defines a boolean indicating if the texture must be rendered in foreground (default is true)
4340
- * @param scene defines the hosting scene
4355
+ * @param sceneOrOptions defines the hosting scene or options (IAdvancedDynamicTextureOptions)
4341
4356
  * @param sampling defines the texture sampling mode (Texture.BILINEAR_SAMPLINGMODE by default)
4342
4357
  * @param adaptiveScaling defines whether to automatically scale root to match hardwarescaling (false by default)
4343
4358
  * @returns a new AdvancedDynamicTexture
4344
4359
  */
4345
- static CreateFullscreenUI(name: string, foreground?: boolean, scene?: BABYLON.Nullable<BABYLON.Scene>, sampling?: number, adaptiveScaling?: boolean): AdvancedDynamicTexture;
4360
+ static CreateFullscreenUI(name: string, foreground?: boolean, sceneOrOptions?: BABYLON.Nullable<BABYLON.Scene> | IAdvancedDynamicTextureOptions, sampling?: number, adaptiveScaling?: boolean): AdvancedDynamicTexture;
4346
4361
  /**
4347
4362
  * Scales the texture
4348
4363
  * @param ratio the scale factor to apply to both width and height
@@ -8198,6 +8213,77 @@ declare module BABYLON.GUI {
8198
8213
  }
8199
8214
 
8200
8215
 
8216
+ /**
8217
+ * Block that implements a fullscreen GUI for render graph
8218
+ */
8219
+ export class NodeRenderGraphGUIBlock extends BABYLON.NodeRenderGraphBlock {
8220
+ protected _frameGraphTask: FrameGraphGUITask;
8221
+ protected _gui: AdvancedDynamicTexture;
8222
+ /**
8223
+ * Gets the frame graph task associated with this block
8224
+ */
8225
+ get task(): FrameGraphGUITask;
8226
+ /**
8227
+ * Gets the GUI texture used by this block
8228
+ */
8229
+ get gui(): AdvancedDynamicTexture;
8230
+ /**
8231
+ * Create a new NodeRenderGraphGUIBlock
8232
+ * @param name defines the block name
8233
+ * @param frameGraph defines the hosting frame graph
8234
+ * @param scene defines the hosting scene
8235
+ */
8236
+ constructor(name: string, frameGraph: BABYLON.FrameGraph, scene: BABYLON.Scene);
8237
+ /**
8238
+ * Gets the current class name
8239
+ * @returns the class name
8240
+ */
8241
+ getClassName(): string;
8242
+ /**
8243
+ * Gets the destination input component
8244
+ */
8245
+ get destination(): BABYLON.NodeRenderGraphConnectionPoint;
8246
+ /**
8247
+ * Gets the output component
8248
+ */
8249
+ get output(): BABYLON.NodeRenderGraphConnectionPoint;
8250
+ protected _buildBlock(state: BABYLON.NodeRenderGraphBuildState): void;
8251
+ }
8252
+
8253
+
8254
+ /**
8255
+ * Task that renders a GUI texture.
8256
+ */
8257
+ export class FrameGraphGUITask extends BABYLON.FrameGraphTask {
8258
+ /**
8259
+ * The destination texture to render the GUI to.
8260
+ */
8261
+ destinationTexture: BABYLON.FrameGraphTextureHandle;
8262
+ /**
8263
+ * The output texture of the task.
8264
+ * This is the same texture as the destination texture, but the handles are different!
8265
+ */
8266
+ readonly outputTexture: BABYLON.FrameGraphTextureHandle;
8267
+ get disabled(): boolean;
8268
+ set disabled(value: boolean);
8269
+ /**
8270
+ * Gets the underlying advanced dynamic texture.
8271
+ */
8272
+ get gui(): AdvancedDynamicTexture;
8273
+ protected _adt: AdvancedDynamicTexture;
8274
+ /**
8275
+ * Constructs a new GUI task.
8276
+ * @param name Name of the task
8277
+ * @param frameGraph Frame graph the task belongs to
8278
+ * @param adt The GUI texture. If not provided, a new fullscreen GUI will be created.
8279
+ */
8280
+ constructor(name: string, frameGraph: BABYLON.FrameGraph, adt?: AdvancedDynamicTexture);
8281
+ isReady(): boolean;
8282
+ record(): void;
8283
+ dispose(): void;
8284
+ }
8285
+
8286
+
8201
8287
 
8202
8288
  }
8203
8289