using System.Runtime.InteropServices;
namespace Raylib_cs
{
///
/// Texture parameters: filter mode
/// NOTE 1: Filtering considers mipmaps if available in the texture
/// NOTE 2: Filter is accordingly set for minification and magnification
///
public enum TextureFilter
{
///
/// No filter, just pixel aproximation
///
TEXTURE_FILTER_POINT = 0,
///
/// Linear filtering
///
TEXTURE_FILTER_BILINEAR,
///
/// Trilinear filtering (linear with mipmaps)
///
TEXTURE_FILTER_TRILINEAR,
///
/// Anisotropic filtering 4x
///
TEXTURE_FILTER_ANISOTROPIC_4X,
///
/// Anisotropic filtering 8x
///
TEXTURE_FILTER_ANISOTROPIC_8X,
///
/// Anisotropic filtering 16x
///
TEXTURE_FILTER_ANISOTROPIC_16X,
}
///
/// Texture parameters: wrap mode
///
public enum TextureWrap
{
///
/// Repeats texture in tiled mode
///
TEXTURE_WRAP_REPEAT = 0,
///
/// Clamps texture to edge pixel in tiled mode
///
TEXTURE_WRAP_CLAMP,
///
/// Mirrors and repeats the texture in tiled mode
///
TEXTURE_WRAP_MIRROR_REPEAT,
///
/// Mirrors and clamps to border the texture in tiled mode
///
TEXTURE_WRAP_MIRROR_CLAMP
}
///
/// Cubemap layouts
///
public enum CubemapLayout
{
///
/// Automatically detect layout type
///
CUBEMAP_LAYOUT_AUTO_DETECT = 0,
///
/// Layout is defined by a vertical line with faces
///
CUBEMAP_LAYOUT_LINE_VERTICAL,
///
/// Layout is defined by a horizontal line with faces
///
CUBEMAP_LAYOUT_LINE_HORIZONTAL,
///
/// Layout is defined by a 3x4 cross with cubemap faces
///
CUBEMAP_LAYOUT_CROSS_THREE_BY_FOUR,
///
/// Layout is defined by a 4x3 cross with cubemap faces
///
CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE,
///
/// Layout is defined by a panorama image (equirectangular map)
///
CUBEMAP_LAYOUT_PANORAMA
}
///
/// Texture2D type
/// NOTE: Data stored in GPU memory
///
[StructLayout(LayoutKind.Sequential)]
public partial struct Texture2D
{
///
/// OpenGL texture id
///
public uint id;
///
/// Texture base width
///
public int width;
///
/// Texture base height
///
public int height;
///
/// Mipmap levels, 1 by default
///
public int mipmaps;
///
/// Data format (PixelFormat type)
///
public PixelFormat format;
}
}