/** This file must only contain pure code and pure imports */ import { type Nullable } from "../../../../types.js"; import { NodeGeometryBlock } from "../../nodeGeometryBlock.js"; import { type NodeGeometryConnectionPoint } from "../../nodeGeometryBlockConnectionPoint.js"; import { type Texture } from "../../../../Materials/Textures/texture.pure.js"; /** * Block used to load texture data */ export declare class GeometryTextureBlock extends NodeGeometryBlock { private _data; private _width; private _height; /** * Gets or sets a boolean indicating that this block should serialize its cached data */ serializedCachedData: boolean; /** * Gets the texture data */ get textureData(): Nullable; /** * Gets the texture width */ get textureWidth(): number; /** * Gets the texture height */ get textureHeight(): number; /** * Creates a new GeometryTextureBlock * @param name defines the block name */ constructor(name: string); /** * Gets the current class name * @returns the class name */ getClassName(): string; /** * Gets the texture component */ get texture(): NodeGeometryConnectionPoint; private _prepareImgToLoadAsync; /** * Remove stored data */ cleanData(): void; /** * Load the texture data from a Float32Array * @param data defines the data to load * @param width defines the width of the texture * @param height defines the height of the texture */ loadTextureFromData(data: Float32Array, width: number, height: number): void; /** * Load the texture data * @param imageFile defines the file to load data from * @returns a promise fulfilled when image data is loaded */ loadTextureFromFileAsync(imageFile: File): Promise; /** * Load the texture data * @param url defines the url to load data from * @returns a promise fulfilled when image data is loaded */ loadTextureFromUrlAsync(url: string): Promise; /** * Load the texture data * @param texture defines the source texture * @returns a promise fulfilled when image data is loaded */ extractFromTextureAsync(texture: Texture): Promise; protected _buildBlock(): void; /** * Serializes this block in a JSON representation * @returns the serialized block object */ serialize(): any; /** @internal */ _deserialize(serializationObject: any): void; } /** * Register side effects for geometryTextureBlock. * Safe to call multiple times; only the first call has an effect. */ export declare function RegisterGeometryTextureBlock(): void;