Sign in to follow this  

C#: OpenGL extension loading (or mapping a function pointer to a delegate).

This topic is 4546 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Anyone who's ever tried to load OpenGL extensions under C# may have encountered a interesting problem. Extensions, function pointers in C, can be mapped nicely to delegates in C#. Under the 2.0 framework there is a Marshal.GetDelegateFromFunctionPointer() method that, well, does what its name suggests ;) All would be nice and well, but for one little thing: there is no such method under the 1.1 (either MS or Mono implementation) framework. Up to now I haven't been able to find a way to do the same under the current standard - and now I'm completely stuck. I now have two options: a) ditch C# and return to C++ (bad), b) ditch OpenGL and goto DirectX (very bad) or c) turn to the Gamedev for help. (I know that makes three, but hey!) Please, take a shot at this problem. A Cookie and an honorable mention in my games' credits await any who help this poor developer! :D

Share this post


Link to post
Share on other sites

This topic is 4546 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this