TextureCreate2D Method (Int32, Int32, Boolean, Int32, TextureFormat, TextureFlags, NullableMemoryBlock) |
Creates a new 2D texture.
Namespace:
Internal.SharpBgfx
Assembly:
NeoAxis.Core (in NeoAxis.Core.dll) Version: 2024.1.1.0 (2024.1.1.0)
Syntax public static Texture Create2D(
int width,
int height,
bool hasMips,
int arrayLayers,
TextureFormat format,
TextureFlags flags = TextureFlags.None,
Nullable<MemoryBlock> memory = null
)
Parameters
- width
- Type: SystemInt32
The width of the texture. - height
- Type: SystemInt32
The height of the texture. - hasMips
- Type: SystemBoolean
Indicates that texture contains full mip-map chain. - arrayLayers
- Type: SystemInt32
Number of layers in texture array. Must be 1 if Texture2DArray caps flag not set. - format
- Type: Internal.SharpBgfxTextureFormat
The format of the texture data. - flags (Optional)
- Type: Internal.SharpBgfxTextureFlags
Flags that control texture behavior. - memory (Optional)
- Type: SystemNullableMemoryBlock
If not null, contains the texture's image data.
Return Value
Type:
Texture
The newly created texture handle.
See Also