|
|
|
@ -27060,6 +27060,353 @@ namespace OpenTK.Graphics.ES20
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D(OpenTK.Graphics.ES20.All target, Int32 level, OpenTK.Graphics.ES20.All internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, IntPtr pixels)
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels);
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, OpenTK.Graphics.ES20.All internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] T8[] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, OpenTK.Graphics.ES20.All internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] T8[,] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, OpenTK.Graphics.ES20.All internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] T8[,,] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, OpenTK.Graphics.ES20.All internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] ref T8 pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
pixels = (T8)pixels_ptr.Target;
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
@ -27457,7 +27804,7 @@ namespace OpenTK.Graphics.ES20
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D(OpenTK.Graphics.ES20.All target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, IntPtr pixels)
|
|
|
|
|
void TexImage2D(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, OpenTK.Graphics.ES20.PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, IntPtr pixels)
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
@ -27519,7 +27866,7 @@ namespace OpenTK.Graphics.ES20
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] T8[] pixels)
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, OpenTK.Graphics.ES20.PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] T8[] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
@ -27590,7 +27937,7 @@ namespace OpenTK.Graphics.ES20
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] T8[,] pixels)
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, OpenTK.Graphics.ES20.PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] T8[,] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
@ -27661,7 +28008,7 @@ namespace OpenTK.Graphics.ES20
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] T8[,,] pixels)
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, OpenTK.Graphics.ES20.PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] T8[,,] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
@ -27732,354 +28079,7 @@ namespace OpenTK.Graphics.ES20
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.All target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.All format, OpenTK.Graphics.ES20.All type, [InAttribute, OutAttribute] ref T8 pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
pixels = (T8)pixels_ptr.Target;
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, IntPtr pixels)
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels);
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] T8[] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] T8[,] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] T8[,,] pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|
using (new ErrorHelper(GraphicsContext.CurrentContext))
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
GCHandle pixels_ptr = GCHandle.Alloc(pixels, GCHandleType.Pinned);
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
Delegates.glTexImage2D((OpenTK.Graphics.ES20.TextureTarget2d)target, (Int32)level, (Int32)internalformat, (Int32)width, (Int32)height, (Int32)border, (OpenTK.Graphics.ES20.PixelFormat)format, (OpenTK.Graphics.ES20.PixelType)type, (IntPtr)pixels_ptr.AddrOfPinnedObject());
|
|
|
|
|
}
|
|
|
|
|
finally
|
|
|
|
|
{
|
|
|
|
|
pixels_ptr.Free();
|
|
|
|
|
}
|
|
|
|
|
#if DEBUG
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>[requires: v2.0 and ES_VERSION_2_0]
|
|
|
|
|
/// Specify a two-dimensional texture image
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="target">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the target texture. Must be GL_TEXTURE_2D, GL_PROXY_TEXTURE_2D, GL_TEXTURE_1D_ARRAY, GL_PROXY_TEXTURE_1D_ARRAY, GL_TEXTURE_RECTANGLE, GL_PROXY_TEXTURE_RECTANGLE, GL_TEXTURE_CUBE_MAP_POSITIVE_X, GL_TEXTURE_CUBE_MAP_NEGATIVE_X, GL_TEXTURE_CUBE_MAP_POSITIVE_Y, GL_TEXTURE_CUBE_MAP_NEGATIVE_Y, GL_TEXTURE_CUBE_MAP_POSITIVE_Z, GL_TEXTURE_CUBE_MAP_NEGATIVE_Z, or GL_PROXY_TEXTURE_CUBE_MAP.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="level">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image. If target is GL_TEXTURE_RECTANGLE or GL_PROXY_TEXTURE_RECTANGLE, level must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="internalFormat">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the number of color components in the texture. Must be one of base internal formats given in Table 1, one of the sized internal formats given in Table 2, or one of the compressed internal formats given in Table 3, below.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="width">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the width of the texture image. All implementations support texture images that are at least 1024 texels wide.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="height">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the height of the texture image, or the number of layers in a texture array, in the case of the GL_TEXTURE_1D_ARRAY and GL_PROXY_TEXTURE_1D_ARRAY targets. All implementations support 2D texture images that are at least 1024 texels high, and texture arrays that are at least 256 layers deep.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="border">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// This value must be 0.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="format">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the format of the pixel data. The following symbolic values are accepted: GL_RED, GL_RG, GL_RGB, GL_BGR, GL_RGBA, GL_BGRA, GL_RED_INTEGER, GL_RG_INTEGER, GL_RGB_INTEGER, GL_BGR_INTEGER, GL_RGBA_INTEGER, GL_BGRA_INTEGER, GL_STENCIL_INDEX, GL_DEPTH_COMPONENT, GL_DEPTH_STENCIL.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="type">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies the data type of the pixel data. The following symbolic values are accepted: GL_UNSIGNED_BYTE, GL_BYTE, GL_UNSIGNED_SHORT, GL_SHORT, GL_UNSIGNED_INT, GL_INT, GL_FLOAT, GL_UNSIGNED_BYTE_3_3_2, GL_UNSIGNED_BYTE_2_3_3_REV, GL_UNSIGNED_SHORT_5_6_5, GL_UNSIGNED_SHORT_5_6_5_REV, GL_UNSIGNED_SHORT_4_4_4_4, GL_UNSIGNED_SHORT_4_4_4_4_REV, GL_UNSIGNED_SHORT_5_5_5_1, GL_UNSIGNED_SHORT_1_5_5_5_REV, GL_UNSIGNED_INT_8_8_8_8, GL_UNSIGNED_INT_8_8_8_8_REV, GL_UNSIGNED_INT_10_10_10_2, and GL_UNSIGNED_INT_2_10_10_10_REV.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
/// <param name="data">
|
|
|
|
|
/// <para>
|
|
|
|
|
/// Specifies a pointer to the image data in memory.
|
|
|
|
|
/// </para>
|
|
|
|
|
/// </param>
|
|
|
|
|
[AutoGenerated(Category = "ES_VERSION_2_0", Version = "2.0", EntryPoint = "glTexImage2D")]
|
|
|
|
|
public static
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] ref T8 pixels)
|
|
|
|
|
void TexImage2D<T8>(OpenTK.Graphics.ES20.TextureTarget target, Int32 level, OpenTK.Graphics.ES20.PixelInternalFormat internalformat, Int32 width, Int32 height, Int32 border, OpenTK.Graphics.ES20.PixelFormat format, OpenTK.Graphics.ES20.PixelType type, [InAttribute, OutAttribute] ref T8 pixels)
|
|
|
|
|
where T8 : struct
|
|
|
|
|
{
|
|
|
|
|
#if DEBUG
|
|
|
|
|