Class representing a cube texture. More...
Public Member Functions | |
TextureCube (int width, bool mipmap, PixelFormat format) | |
Creates a cube texture. | |
TextureCube (int width, bool mipmap, PixelFormat format, PixelBufferOption option) | |
Creates a cube texture (with options) | |
TextureCube (string fileName, bool mipmap) | |
Creates a cube texture (from a file) | |
TextureCube (string fileName, bool mipmap, PixelFormat format) | |
Creates a cube texture (from a file, with format conversion) | |
TextureCube (byte[] fileImage, bool mipmap) | |
Creates a cube texture (from a file image) | |
TextureCube (byte[] fileImage, bool mipmap, PixelFormat format) | |
Creates a cube texture (from a file image, with format conversion) | |
override Object | ShallowClone () |
Creates a copy of a cube texture. | |
void | SetPixels (int level, TextureCubeFace cubeFace, Array pixels) |
Sets pixel data. | |
void | SetPixels (int level, TextureCubeFace cubeFace, Array pixels, int dx, int dy, int dw, int dh) |
Sets pixel data (with range) | |
void | SetPixels (int level, TextureCubeFace cubeFace, Array pixels, int offset, int pitch) |
Sets pixel data (with byte offset) | |
void | SetPixels (int level, TextureCubeFace cubeFace, Array pixels, PixelFormat format) |
Sets pixel data (with format conversion) | |
void | SetPixels (int level, TextureCubeFace cubeFace, Array pixels, PixelFormat format, int offset, int pitch, int dx, int dy, int dw, int dh) |
Sets pixel data (with format conversion, with byte offset, with range) | |
void | GenerateMipmap () |
Automatically creates a mipmap image. | |
Protected Member Functions | |
TextureCube (TextureCube texture) | |
Creates a copy of a cube texture. |
Class representing a cube texture.
TextureCube | ( | int | width, |
bool | mipmap, | ||
PixelFormat | format | ||
) |
Creates a cube texture.
width | Texture width |
mipmap | Existence/Lack of mipmap |
format | Pixel format |
Creates the cube texture using the specified parameters. The texture width must have a power of 2. Rgba, Rgba4444, Rgba5551, Rgb565, LuminanceAlpha, Luminance, Alpha, RgbaH, LuminanceAlphaH, LuminanceH, AlphaH, Dxt1, Dxt2, Dxt3, Dxt4, or Dxt5 can be specified to the pixel format.
TextureCube | ( | int | width, |
bool | mipmap, | ||
PixelFormat | format, | ||
PixelBufferOption | option | ||
) |
Creates a cube texture (with options)
width | Texture width |
mipmap | Existence/Lack of mipmap |
format | Pixel format |
option | Pixel buffer creation option |
Creates the cube texture using the specified parameters. The texture width must have a power of 2. Rgba, Rgba4444, Rgba5551, Rgb565, LuminanceAlpha, Luminance, Alpha, RgbaH, LuminanceAlphaH, LuminanceH, AlphaH, Dxt1, Dxt2, Dxt3, Dxt4, or Dxt5 can be specified to the pixel format. However, if the Renderable option is specified, only Rgba, Rgba4444, Rgba5551, or Rgb565 can be specified.
TextureCube | ( | string | fileName, |
bool | mipmap | ||
) |
Creates a cube texture (from a file)
fileName | Filename |
mipmap | Existence/Lack of mipmap |
Creates a cube texture from a specified file. The usable file formats are DDS, PNG, JPG, BMP, and GIF (however, animated GIFs are not supported). The texture width must have a power of 2. The short side of the image must be a power of 2, and the long side must be 6 times the short side.
When a DDS file, the image must be a cubemap, and the mipmap argument is ignored.
TextureCube | ( | string | fileName, |
bool | mipmap, | ||
PixelFormat | format | ||
) |
Creates a cube texture (from a file, with format conversion)
fileName | Filename |
mipmap | Existence/Lack of mipmap |
format | Pixel format |
Creates a cube texture from a specified file. The usable file formats are DDS, PNG, JPG, BMP, and GIF (however, animated GIFs are not supported). The texture width must have a power of 2. The short side of the image must be a power of 2, and the long side must be 6 times the short side. Rgba, Rgba4444, Rgba5551, Rgb565, LuminanceAlpha, Luminance, Alpha, RgbaH, LuminanceAlphaH, LuminanceH, or AlphaH can be specified to the pixel format.
When a DDS file, the image must be a cubemap, and the mipmap and format arguments are ignored.
TextureCube | ( | byte[] | fileImage, |
bool | mipmap | ||
) |
Creates a cube texture (from a file image)
fileImage | File image |
mipmap | Existence/Lack of mipmap |
Creates a cube texture from a specified file image. The usable file formats are DDS, PNG, JPG, BMP, and GIF (however, animated GIFs are not supported). The texture width must have a power of 2. The short side of the image must be a power of 2, and the long side must be 6 times the short side.
When a DDS file, the image must be a cubemap, and the mipmap argument is ignored.
TextureCube | ( | byte[] | fileImage, |
bool | mipmap, | ||
PixelFormat | format | ||
) |
Creates a cube texture (from a file image, with format conversion)
fileImage | File image |
mipmap | Existence/Lack of mipmap |
format | Pixel format |
Creates a cube texture from a specified file image. The usable file formats are DDS, PNG, JPG, BMP, and GIF (however, animated GIFs are not supported). The texture width must have a power of 2. The short side of the image must be a power of 2, and the long side must be 6 times the short side. Rgba, Rgba4444, Rgba5551, Rgb565, LuminanceAlpha, Luminance, Alpha, RgbaH, LuminanceAlphaH, LuminanceH, or AlphaH can be specified to the pixel format.
When a DDS file, the image must be a cubemap, and the mipmap and format arguments are ignored.
TextureCube | ( | TextureCube | texture | ) | [protected] |
Creates a copy of a cube texture.
texture | Cube texture |
Creates a copy of a cube texture. The 2 cube textures will then share unmanaged resources. When Dispose() is called for all copies, the shared unmanaged resources will be freed.
void GenerateMipmap | ( | ) |
Automatically creates a mipmap image.
Automatically creates a mipmap image from the current zero level image. Nothing will be performed if mipmaps are not present.
When the pixel format is DXT, nothing will be performed.
void SetPixels | ( | int | level, |
TextureCubeFace | cubeFace, | ||
Array | pixels, | ||
int | dx, | ||
int | dy, | ||
int | dw, | ||
int | dh | ||
) |
Sets pixel data (with range)
level | Mipmap level (0 to LevelCount-1) |
cubeFace | Cube surface |
pixels | Pixel data |
dx | X coordinate of the transfer destination |
dy | Y coordinate of the transfer destination |
dw | Width of the transfer destination |
dh | Height of the transfer destination |
Sets the pixel data to the cube surface of the specified mipmap level.
When the pixel format is DXT, the dx, dy, dw, and dh must be a multiple of 4.
void SetPixels | ( | int | level, |
TextureCubeFace | cubeFace, | ||
Array | pixels, | ||
PixelFormat | format, | ||
int | offset, | ||
int | pitch, | ||
int | dx, | ||
int | dy, | ||
int | dw, | ||
int | dh | ||
) |
Sets pixel data (with format conversion, with byte offset, with range)
level | Mipmap level (0 to LevelCount-1) |
cubeFace | Cube surface |
pixels | Pixel data |
format | Pixel format |
offset | Byte offset of pixel data |
pitch | Byte pitch of pixel data |
dx | X coordinate of the transfer destination |
dy | Y coordinate of the transfer destination |
dw | Width of the transfer destination |
dh | Height of the transfer destination |
Sets the pixel data to the cube surface of the specified mipmap level. Rgba or the same format as the texture can be specified to the pixel format.
When the pixel format is DXT, the dx, dy, dw, and dh must be a multiple of 4. Conversion of DXT pixel format is not supported.
void SetPixels | ( | int | level, |
TextureCubeFace | cubeFace, | ||
Array | pixels, | ||
PixelFormat | format | ||
) |
Sets pixel data (with format conversion)
level | Mipmap level (0 to LevelCount-1) |
cubeFace | Cube surface |
pixels | Pixel data |
format | Pixel format |
Sets the pixel data to the cube surface of the specified mipmap level. Rgba or the same format as the texture can be specified to the pixel format.
Conversion of DXT pixel format is not supported.
void SetPixels | ( | int | level, |
TextureCubeFace | cubeFace, | ||
Array | pixels, | ||
int | offset, | ||
int | pitch | ||
) |
Sets pixel data (with byte offset)
level | Mipmap level (0 to LevelCount-1) |
cubeFace | Cube surface |
pixels | Pixel data |
offset | Byte offset of pixel data |
pitch | Byte pitch of pixel data |
Sets the pixel data to the cube surface of the specified mipmap level.
void SetPixels | ( | int | level, |
TextureCubeFace | cubeFace, | ||
Array | pixels | ||
) |
Sets pixel data.
level | Mipmap level (0 to LevelCount-1) |
cubeFace | Cube surface |
pixels | Pixel data |
Sets the pixel data to the cube surface of the specified mipmap level.
This overload sets data to all pixels of the specified mipmap level's cube surface. When the size of the array differs from the required size, an exception is thrown. When the array size is bigger than the required size, please use a different overload.
override Object ShallowClone | ( | ) | [virtual] |