|
TextureLoaderHasTransparentPixels Method |
HasTransparentPixels returns true when the loaded image contains transparent pixels (where alpha is less the 1); for fully opaque image false is returned.
Namespace: Ab3d.DirectXAssembly: Ab3d.DXEngine (in Ab3d.DXEngine.dll) Version: 7.0.8865.1045
Syntax public static bool HasTransparentPixels(
byte[] textureBytes,
int width,
int height,
int stride,
int alphaOffset = 3,
int pixelSize = 4
)
Parameters
- textureBytes Byte
- byte array with texture data
- width Int32
- texture width in pixels
- height Int32
- texture height in pixels
- stride Int32
- one row size in bytes
- alphaOffset Int32 (Optional)
- specifies the offset of the alpha byte in the pixel bytes (for BGRA the correct value is 3)
- pixelSize Int32 (Optional)
- size of one pixel in bytes (4 by default for BGRA)
Return Value
Booleantrue when the loaded image contains transparent pixels (where alpha is less the 1); for fully opaque image false is returned
See Also