its's picture

glGetBooleanv

I can not foutd the OpenGL funtion "glGetBooleanv" in the class "OepnTK.Graphics.GL",
but it is found as "OepnTK.Graphics.GL.NV.GetBoolea".
Version of OpenTK is 0.9.8.


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

It has been renamed to:

OpenTK.Graphics.GL.GetBoolean()

(no 'v' suffix)

its's picture

In the source code file "GL.sc",
OpenTK.Graphics.GL.GetBoolean() is defined as below.
This is "glGetBooleani_v()", OpenGL3.0 function.

[System.CLSCompliant(false)]
[AutoGenerated(Category = "Version30", Version = "3.0", EntryPoint = "glGetBooleani_v")]
public static 
void GetBoolean(OpenTK.Graphics.GetIndexedPName target, UInt32 index, [Out] bool[] data)
{
...
}

OpenTK.Graphics.GL.NV.GetBoolea() is defined as below.
This is "glGetBooleanv()".

[AutoGenerated(Category = "Version10", Version = "1.0", EntryPoint = "glGetBooleanv")]
public static 
void GetBoolea(OpenTK.Graphics.GetPName pname, [Out] bool[] @params)
{
...
}
the Fiddler's picture

Please file a bug.

In the meantime you use the following functions as a workaround:

using System.Runtime.InteropServices;
 
[DllImport("opengl32.dll", EntryPoint = "glGetBooleanv")]
public static extern void GetBoolean(OpenTK.Graphics.GetPName pname, out bool params);
 
[DllImport("opengl32.dll", EntryPoint = "glGetBooleanv")]
public static extern void GetBoolean(OpenTK.Graphics.GetPName pname, [Out] bool[] params);
the Fiddler's picture

Ok, found the cause of the issue: it seems the generator thought the function was a Nvidia extension and removed its ending, transforming it to GL.GetBoolea.

Fixed in trunk and 0.9.8 branch as of rev. 1855.