Implemented compatibility overloads for the changes introduced by the

4.3 .spec files.
Added DebugProc definition required in the 4.3 specs.
This commit is contained in:
Stefanos A. 2013-10-22 11:57:18 +02:00
parent 15120f3bef
commit c49f9cd4a1

View file

@ -1322,7 +1322,7 @@ namespace OpenTK.Graphics.OpenGL
#region DrawElements
public static void DrawElements(BeginMode mode, int count, DrawElementsType type, int offset)
public static void DrawElements(PrimitiveType mode, int count, DrawElementsType type, int offset)
{
DrawElements(mode, count, type, new IntPtr(offset));
}
@ -1457,13 +1457,75 @@ namespace OpenTK.Graphics.OpenGL
#region Obsolete
[AutoGenerated(Category = "VERSION_1_0_DEPRECATED", Version = "1.0", EntryPoint = "glBegin")]
[Obsolete("Use BeginMode(PrimitiveType) instead")]
public static void Begin(OpenTK.Graphics.OpenGL.BeginMode mode)
{
Begin((PrimitiveType)mode);
}
[AutoGenerated(Category = "Version11Deprecated", Version = "1.1", EntryPoint = "glDisableClientState")]
[Obsolete("Use DisableClientState(ArrayCap) instead.")]
[Obsolete("Use DisableClientState(ArrayCap) instead")]
public static void DisableClientState(OpenTK.Graphics.OpenGL.EnableCap array)
{
DisableClientState((ArrayCap)array);
}
[AutoGenerated(Category = "VERSION_1_1", Version = "1.1", EntryPoint = "glDrawArrays")]
[Obsolete("Use DrawArrays(PrimitiveType) instead")]
public static void DrawArrays(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 first, Int32 count)
{
DrawArrays((PrimitiveType)mode, first, count);
}
[AutoGenerated(Category = "VERSION_3_1", Version = "3.1", EntryPoint = "glDrawArraysInstanced")]
[Obsolete("Use DrawArraysInstanced(PrimitiveType) instead")]
public static void DrawArraysInstanced(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 first, Int32 count, Int32 primcount)
{
DrawArraysInstanced((PrimitiveType)mode, first, count, primcount);
}
[AutoGenerated(Category = "VERSION_1_1", Version = "1.1", EntryPoint = "glDrawElements")]
[Obsolete("Use DrawElements(PrimitiveType) instead")]
public static void DrawElements(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 count, OpenTK.Graphics.OpenGL.DrawElementsType type, IntPtr indices)
{
DrawElements((PrimitiveType)mode, count, type, indices);
}
[AutoGenerated(Category = "VERSION_1_1", Version = "1.1", EntryPoint = "glDrawElements")]
[Obsolete("Use DrawElements(PrimitiveType) instead")]
public static void DrawElements<T3>(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 count, OpenTK.Graphics.OpenGL.DrawElementsType type, [InAttribute, OutAttribute] T3[] indices)
where T3 : struct
{
DrawElements((PrimitiveType)mode, count, type, indices);
}
[AutoGenerated(Category = "VERSION_1_1", Version = "1.1", EntryPoint = "glDrawElements")]
[Obsolete("Use DrawElements(PrimitiveType) instead")]
[CLSCompliant(false)]
public static void DrawElements<T3>(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 count, OpenTK.Graphics.OpenGL.DrawElementsType type, [InAttribute, OutAttribute] T3[,] indices)
where T3 : struct
{
DrawElements((PrimitiveType)mode, count, type, indices);
}
[AutoGenerated(Category = "VERSION_1_1", Version = "1.1", EntryPoint = "glDrawElements")]
[Obsolete("Use DrawElements(PrimitiveType) instead")]
[CLSCompliant(false)]
public static void DrawElements<T3>(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 count, OpenTK.Graphics.OpenGL.DrawElementsType type, [InAttribute, OutAttribute] T3[,,] indices)
where T3 : struct
{
DrawElements((PrimitiveType)mode, count, type, indices);
}
[AutoGenerated(Category = "VERSION_1_1", Version = "1.1", EntryPoint = "glDrawElements")]
[Obsolete("Use DrawElements(PrimitiveType) instead")]
public static void DrawElements<T3>(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 count, OpenTK.Graphics.OpenGL.DrawElementsType type, [InAttribute, OutAttribute] ref T3 indices)
where T3 : struct
{
DrawElements((PrimitiveType)mode, count, type, ref indices);
}
[AutoGenerated(Category = "Version11Deprecated", Version = "1.1", EntryPoint = "glEnableClientState")]
[Obsolete("Use EnableClientState(ArrayCap) instead.")]
public static void EnableClientState(OpenTK.Graphics.OpenGL.EnableCap array)
@ -1517,8 +1579,36 @@ namespace OpenTK.Graphics.OpenGL
GetActiveUniforms(program, uniformCount, uniformIndices, (ActiveUniformParameter)pname, @params);
}
[AutoGenerated(Category = "VERSION_1_4", Version = "1.4", EntryPoint = "glMultiDrawArrays")]
[Obsolete("Use MultiDrawArrays(PrimitiveType) instead")]
public static void MultiDrawArrays(OpenTK.Graphics.OpenGL.BeginMode mode, Int32[] first, Int32[] count, Int32 primcount)
{
MultiDrawArrays((PrimitiveType)mode, first, count, primcount);
}
[AutoGenerated(Category = "VERSION_1_4", Version = "1.4", EntryPoint = "glMultiDrawArrays")]
[Obsolete("Use MultiDrawArrays(PrimitiveType) instead")]
public static void MultiDrawArrays(OpenTK.Graphics.OpenGL.BeginMode mode, ref Int32 first, ref Int32 count, Int32 primcount)
{
MultiDrawArrays((PrimitiveType)mode, ref first, ref count, primcount);
}
[AutoGenerated(Category = "VERSION_1_4", Version = "1.4", EntryPoint = "glMultiDrawArrays")]
[Obsolete("Use MultiDrawArrays(PrimitiveType) instead")]
unsafe public static void MultiDrawArrays(OpenTK.Graphics.OpenGL.BeginMode mode, Int32* first, Int32* count, Int32 primcount)
{
MultiDrawArrays((PrimitiveType)mode, first, count, primcount);
}
public static partial class Arb
{
[AutoGenerated(Category = "ARB_draw_instanced", Version = "2.0", EntryPoint = "glDrawArraysInstancedARB")]
[Obsolete("Use DrawArraysInstanced(PrimitiveType) instead.")]
public static void DrawArraysInstanced(OpenTK.Graphics.OpenGL.BeginMode mode, Int32 first, Int32 count, Int32 primcount)
{
DrawArraysInstanced((PrimitiveType)mode, first, count, primcount);
}
[AutoGenerated(Category = "ArbGeometryShader4", Version = "3.0", EntryPoint = "glProgramParameteriARB")]
[Obsolete("Use ProgramParameter(..., AssemblyProgramParameterArb, ...) instead.")]
public static void ProgramParameter(Int32 program, ArbGeometryShader4 pname, Int32 value)
@ -1570,4 +1660,8 @@ namespace OpenTK.Graphics.OpenGL
public delegate void DebugProcArb(int id,
ArbDebugOutput category, ArbDebugOutput severity,
IntPtr length, string message, IntPtr userParam);
public delegate void DebugProc(int id,
ArbDebugOutput category, ArbDebugOutput severity,
IntPtr length, string message, IntPtr userParam);
}