Added support for wglCreateContextAttribsARB.

This commit is contained in:
the_fiddler 2009-02-28 19:51:58 +00:00
parent f84cc5678f
commit cf20b474f6
3 changed files with 548 additions and 506 deletions

View file

@ -522,6 +522,37 @@ namespace OpenTK.Platform.Windows
public static partial class Arb
{
[CLSCompliant(false)]
unsafe public static
IntPtr CreateContextAttribs(IntPtr hDC, IntPtr hShareContext, int* attribList)
{
return Delegates.wglCreateContextAttribsARB((IntPtr)hDC, (IntPtr)hShareContext, (int*)attribList);
}
public static
IntPtr CreateContextAttribs(IntPtr hDC, IntPtr hShareContext, ref int attribList)
{
unsafe
{
fixed (int* attribList_ptr = &attribList)
{
return Delegates.wglCreateContextAttribsARB((IntPtr)hDC, (IntPtr)hShareContext, (int*)attribList_ptr);
}
}
}
public static
IntPtr CreateContextAttribs(IntPtr hDC, IntPtr hShareContext, int[] attribList)
{
unsafe
{
fixed (int* attribList_ptr = attribList)
{
return Delegates.wglCreateContextAttribsARB((IntPtr)hDC, (IntPtr)hShareContext, (int*)attribList_ptr);
}
}
}
[System.CLSCompliant(false)]
public static
IntPtr CreateBufferRegion(IntPtr hDC, int iLayerPlane, UInt32 uType)

View file

@ -83,6 +83,9 @@ namespace OpenTK.Platform.Windows
internal unsafe delegate Boolean UseFontOutlinesW(IntPtr hDC, Int32 first, Int32 count, Int32 listBase, float thickness, float deviation, Int32 fontMode, GlyphMetricsFloat* glyphMetrics);
internal unsafe static UseFontOutlinesW wglUseFontOutlinesW;
[System.Security.SuppressUnmanagedCodeSecurity()]
internal unsafe delegate IntPtr CreateContextAttribsARB(IntPtr hDC, IntPtr hShareContext, int* attribList);
internal unsafe static CreateContextAttribsARB wglCreateContextAttribsARB;
[System.Security.SuppressUnmanagedCodeSecurity()]
internal delegate IntPtr CreateBufferRegionARB(IntPtr hDC, int iLayerPlane, UInt32 uType);
internal static CreateBufferRegionARB wglCreateBufferRegionARB;
[System.Security.SuppressUnmanagedCodeSecurity()]

File diff suppressed because it is too large Load diff