Interface IMultiRenderTargetOptions
createMipMaps?: boolean;
creationFlags?: number[];
defaultType?: number;
depthTextureFormat?: number;
doNotChangeAspectRatio?: boolean;
dontCreateTextures?: boolean;
drawOnlyOnFirstAttachmentByDefault?: boolean;
faceIndex?: number[];
formats?: number[];
generateDepthBuffer?: boolean;
generateDepthTexture?: boolean;
generateMipMaps?: boolean;
generateStencilBuffer?: boolean;
label?: string;
labels?: string[];
layerCounts?: number[];
layerIndex?: number[];
samples?: number;
samplingModes?: number[];
targetTypes?: number[];
textureCount?: number;
types?: number[];
useSRGBBuffers?: boolean[];
}
Index
Properties
Properties
Optionalcreate Mip Maps
Specifies if mipmaps must be created. If undefined, the value from generateMipMaps is taken instead
Optionalcreation Flags
Define the creation flags of the textures (Constants.TEXTURE_CREATIONFLAG_STORAGE for storage textures, for eg)
Optionaldefault Type
Define the default type of the buffers we are creating (default: Constants.TEXTURETYPE_UNSIGNED_BYTE). types[] is prioritized over defaultType if provided.
Optionaldepth Texture Format
Define depth texture format to use
Optionaldo Not Change Aspect Ratio
Define if aspect ratio should be adapted to the texture or stay the scene one (default: true)
Optionaldont Create Textures
Define if the textures should not be created by the MultiRenderTarget (default: false) If true, you will need to set the textures yourself by calling setTexture on the MultiRenderTarget.
Optionaldraw Only On First Attachment By Default
Defines if we should draw into all attachments or the first one only by default (default: false)
Optionalface Index
Define the face index of each texture in the textures array (if applicable, given the corresponding targetType) at creation time (for Constants.TEXTURE_CUBE_MAP and .TEXTURE_CUBE_MAP_ARRAY). Can be changed at any time by calling setLayerAndFaceIndices or setLayerAndFaceIndex
Optionalformats
Define the internal format of the buffer in the RTT (RED, RG, RGB, RGBA (default), ALPHA...) of all the draw buffers (render textures) we want to create
Optionalgenerate Depth Buffer
Define if a depth buffer is required (default: true)
Optionalgenerate Depth Texture
Define if a depth texture is required instead of a depth buffer (default: false)
Optionalgenerate Mip Maps
Define if the texture needs to create mip maps after render (default: false).
Optionalgenerate Stencil Buffer
Define if a stencil buffer is required (default: false)
Optionallabel
Label of the RenderTargetWrapper (used for debugging only)
Optionallabels
Define the names of the textures (used for debugging purpose)
Optionallayer Counts
Define the number of layer of each texture in the textures array (if applicable, given the corresponding targetType) (for Constants.TEXTURE_3D, .TEXTURE_2D_ARRAY, and .TEXTURE_CUBE_MAP_ARRAY)
Optionallayer Index
Define the layer index of each texture in the textures array (if applicable, given the corresponding targetType) at creation time (for Constants.TEXTURE_3D, .TEXTURE_2D_ARRAY, and .TEXTURE_CUBE_MAP_ARRAY). Can be changed at any time by calling setLayerAndFaceIndices or setLayerAndFaceIndex
Optionalsamples
Defines sample count (1 by default)
Optionalsampling Modes
Define the sampling modes of all the draw buffers (render textures) we want to create
Optionaltarget Types
Define the type of texture at each attahment index (of Constants.TEXTURE_2D, .TEXTURE_2D_ARRAY, .TEXTURE_CUBE_MAP, .TEXTURE_CUBE_MAP_ARRAY, .TEXTURE_3D). You can also use the -1 value to indicate that no texture should be created but that you will assign a texture to that attachment index later. Can be useful when you want to attach several layers of the same 2DArrayTexture / 3DTexture or several faces of the same CubeMapTexture: Use the setInternalTexture method for that purpose, after the MultiRenderTarget has been created.
Optionaltexture Count
Define the number of desired draw buffers (render textures). You can set it to 0 if you don't need any color attachment. (default: 1)
Optionaltypes
Define the types of all the draw buffers (render textures) we want to create
Optionaluse SRGB Buffers
Define if sRGB format should be used for each of the draw buffers (render textures) we want to create
Creation options of the multi render target texture.