<Texture> Data Interface

Provides script language access to C++ objects of this type.

Class HierarchyType » Node » Texture

Function Members

Function members are as follows:

Return Type Function Name Documentation
int32ActualHeightThis member is used to access the height of the source image used by the texture.
int32ActualWidthThis member is used to access the width of the source image used by the texture.
int32ClearClears the <Texture> object's underlying <Image> object, or objects in the case of MIP maps, and deallocates all associated memory. Does not deallocate the <Texture> object.
int32GenerateMipMapCountGenerates the number of MIP maps for the <Texture> object's, given the underlying <Image> object's width and height and the specified minimum dimension. For example, if the <Texture> owns an <Image> object that is 1024x1024 pixels, and the minimum dimension is given as 4, this function returns 8, which is the count of <int32> values in the following sequence: 512, 256, 128, 64, 32, 16, 8, 4. Similarly, if the <Texture> owns an <Image> object that is 512x512 pixels, and the minimum dimension is given as 128, this function returns 2, which is the count of <int32> values in the following sequence: 256, 128.
int32GenerateMipMapsPopulates the <Texture> object's ImageList object with down-sampled versions of the first <Image> object in the ImageList object.
<Image>GetFirstImageReturns a pointer to the first <Image> object in the <Texture> object's ImageList object, or nullptr if the ImageList object is empty.
<Image>GetImageRetrieves an <Image> object from a <Texture>, at a specific mip-map level, with 0 being the highest detail level.
doubleGetMemoryFootprintReturns the memory footprint of the texture in bits.
int32GetPixelFormatItemsPopulates a <StrList> and <Int32Array> with texture format item names and indices.
int32GetTopologyReturns an <int32> that refers to a value in the ImageTopology enumeration. This value indicates the topology of the underlying <Image> object. For example: ImageTopology_2D, ImageTopology_2DArray, or ImageTopology_Cubemap. Please see TYPE_SERVICE_ENUMERATION_UTIL.SSL in the application scripts folder for more information.
int32GetViewFromObjectCopies certain texture parameters to the <SurfaceInfo> object submitted to this function. Please see <SurfaceInfo> data interface for more information.
int32IsImageBindingReturns true if the <Texture> is configured to bind as an image sampler such as image2D.
int32IsLayeredTextureReturns true if the <Texture> is a layered texture such as 2D array or cubemap array.
int32IsSamplerBindingReturns true if the <Texture> is configured to bind as a sampler such as sampler2D.
int32LoadTextureLoads the texture from disk if it has not been loaded. Only applies to Textures that store their data externally.
int32OwnsTransfers ownership of an <Image> object to this <Texture>. Note that you must be careful to use this to only add base texture images ( <Image> object 0 in the <Texture> object's ImageList object ) or a complete set of correctly-sized MIP maps.
int32ReadTextureImageReads a <Texture> back from the GPU.
int32RefersAdds a non-owning reference to an <Image> object to the <Texture> object's ImageList object. Note that this function should not be used on <Texture> objects that are stored in the document. This function is used when a <Texture> is being used as a temporary object in a script.
int32ReplaceImageReplaces this <Texture> object's current internal <Image> object with the <Image> object submitted by this function. The <Texture> object's existing <ImageList> is cleared and all existing <Image> objects are destroyed.
int32SaveTextureImageSaves a <Texture> that has been bound on the GPU.
int32SetImageDestroys any existing <Image> objects managed by the <Texture>, and transfers to the <Texture> object ownership of the <Image> object submitted by this function. Does not generate MIP maps.
int32SetObjectParametersFromViewSets the <Texture> object parameters from the parameters in the <MemberView> object submitted to this function.
int32SyncDimensionsSets the <Texture> object's source width, source height, render width, and render height parameters to the width and height values submitted to this function.

Object Members

Object members are as follows:

Type Name Accessor Name Documentation
<ImageList>ImageListReturns a pointer to the <Texture> object's ImageList object, which stores a list of <Image> objects associated with the <Texture> ( usually MIP maps ).
<ImageProcessorList>ImageProcessorListReturns a pointer to the <Texture> object's underlying <<ImageProcessorList>> object.
<MinMaxValueStore>MinMaxValueStoreReturns a pointer to <Texture> object's 's underlying <MinMaxValueStore> object.
int32ArrayCountThe number of slices in the array ( 1, 2, 3, 4, 8, etc. ).
int32ArraySizeThe number of slices in the array ( 1, 2, 3, 4, 8, etc. ).
int32BindAsLinearGets or sets the BindAsLinear flag. If true, data is bound on the GPU as linear.
int32BoundaryOpRefers to the BOUNDARY_OP enumeration. Please see TYPE_SERVICE_ENUMERATION_UTIL.SSL in the application scripts folder for more information.
int32ExportSubdivideThis member is used to access or set whether the <Texture> should be subdivided during an export or terrain creation process.
int32ExternalThis member is 1 if the <Texture> object's primary <Image> object is stored as a file on disk, or 0 if the <Texture> imagery (including MIP maps if specified) are stored internally by the <Texture>.
stringFillAlgorithmGets or sets the <Texture> object's basic fill algorithm, which can be used to initialize an otherwise empty <Texture> to the values specified by the fill algorithm.
doubleFilterScaleXGets or sets the filter scale x, which is used during <Texture> resampling operations.
doubleFilterScaleYGets or sets the filter scale y, which is used during <Texture> resampling operations.
int32FilterTypeRefers to the ResampleFilterType enumeration. Please see TYPE_SERVICE_ENUMERATION_UTIL.SSL in the application scripts folder for more information.
doubleGammaGets or sets the amount of gamma correction to use during resampling.
uint64HandleGets or sets the handle associated with a <Texture>. A handle is only associated with <Texture> objects that are attached to dynamically created <Texture> buffers. A dynamic <Texture> can be used for instance to capture the contents of a rendering pass to a <Texture>, for use in future passes.
doubleImageFormatMaxThe maximum format value, which is a semantic value. For example, a floating point image can store data from <float32> min to <float32> max, but a particular implementation might need to define 1.0 as the maximum acceptable value.
doubleImageFormatMinThe minimum format value, which is a semantic value. For example, a floating point image can store data from <float32> min to <float32> max, but a particular implementation might need to define 0.0 as the minimum acceptable value.
int32LODReductionThis member is used to access or set the LOD reduction level of a <Texture>. The size of a <Texture> at each LOD reduction level is one half the size of the <Texture> at the level below. So a <Texture> with an LODReduction of 2 would be one eighth the size of the same <Texture> with LODReduction set to 0.
int32LinearSourceDataGets or sets the linear data flag, which provides hints to the GL driver that the data is in sRGB format.
int32MIPMapThis member is 1 if the <Texture> is mip-mapped, or 0 if the <Texture> is not mip-mapped.
int32MagFilterGets or sets the texture magnification filter. Refers to the Texture_Filter enumeration. Please see TYPE_SERVICE_ENUMERATION_UTIL.SSL in the application scripts folder for more information. These values correspond to OpenGL values such as GL_NEAREST. Please see https://www.khronos.org/registry/OpenGL-Refpages/es2.0/xhtml/glTexParameter.xml for more information.
int32MinFilterGets or sets the texture minification filter. Refers to the Texture_Filter enumeration. Please see TYPE_SERVICE_ENUMERATION_UTIL.SSL in the application scripts folder for more information. These values correspond to OpenGL values such as GL_NEAREST. Please see https://www.khronos.org/registry/OpenGL-Refpages/es2.0/xhtml/glTexParameter.xml for more information.
stringPathToExportFileThis member is used to access or set the image file name used by the <Texture> during export.
stringPathToFileGets or sets the file referenced by the <Texture> node.
int32RenderDepthThe depth of the rendering ( 1, 2, or 3 ).
int32RenderFormatGets or sets the <Texture> object's render format flag. This refers to the IPF enumeration. Please see TYPE_SERVICE_ENUMERATION_UTIL.SSL in the application scripts folder for more information.
int32RenderHeightGets or sets the height of the <Texture> to be used by the rendering system. This is typically used either to scale a <Texture> to a larger or smaller power of two, or when a <Texture> has a height that is not a power of two but the rendering system requires <Texture> sizes that are powers of two.
int32RenderWidthGets or sets the width of the <Texture> to be used by the rendering system. This is typically used either to scale a <Texture> to a larger or smaller power of two, or when a <Texture> has a width that is not a power of two but the rendering system requires <Texture> sizes that are powers of two.
stringSamplerVariableGets or sets the sampler variable value which is used when binding this <Texture> to the GPU. This should match the sampler name in the GLSL declaration. For example, to bind a <Texture> that is compatible with the following GLSL 'uniform sampler2D my_sampler', the <Texture> object's sampler variable value should be set as 'my_sampler'.
int32SourceHeightGets or sets the number of rows from the image to be used by the <Texture>.
int32SourceWidthGets or sets the number of columns from the image to be used by the <Texture>.
int32SourceXGets or sets the first column of the image to be used by the <Texture>.
int32SourceYGets or sets the first row of the image to be used by the <Texture>.
int32TextureTypeThe type of the <Texture> ( 2D, 3D, Cube Map, Render Buffer ).
int32TileRThe member indicates how rendering interprets R-axis texture coordinates outside the interval [0,1]. The value one indicates clamping, meaning the coordinates clamp to the interval [0,1]. Two indicates the coordinates wrap (also called repeating or tiling) outside [0,1], so the rendering uses only the fractional part of the texture coordinate.
int32TileSThe member indicates how rendering interprets S-axis texture coordinates outside the interval [0,1]. The value one indicates clamping, meaning the coordinates clamp to the interval [0,1]. Two indicates the coordinates wrap (also called repeating or tiling) outside [0,1], so the rendering uses only the fractional part of the texture coordinate.
int32TileTThe member indicates how rendering interprets T-axis texture coordinates outside the interval [0,1]. The value one indicates clamping, meaning the coordinates clamp to the interval [0,1]. Two indicates the coordinates wrap (also called repeating or tiling) outside [0,1], so the rendering uses only the fractional part of the texture coordinate.