Sign in to follow this  
Mulligan

[.net] C# and OpenGL

Recommended Posts

I want to write use C# to design the user interface of a 3D editor, and also display the 3D scene being constructed in one of the windows. I want to use OpenGL. In my head I see two approaches to make this work. Either 1 - Use a module someone wrote as an interface to the actual opengl functions OR 2 - Put the rendering code inside an unmanaged C++ dll and somehow display it in one of the C# windows. I would like to go with the second approach, but I dont know if it is possible. Has anyone dont this?

Share this post


Link to post
Share on other sites
If you want to use OpenGL and C#, don't reinvent the wheel:

Try http://csgl.sourceforge.net/. I used it last year intern-ing at a company who wanted to a 3d viewer using OpenGL and C#. The bad thing is that support has stopped for csGL and there are some known issues. Most likely it will remain this way.

However at the end of last summer I began writing the viewer using Managed DirectX. It is quite good and I highly recommend you look into that as a great alternative to OpenGL.

When it comes down to it, it doesn't really matter what graphics API you use as long as it gets the job done. Given that there is a lot of support for managed DirectX and that many developers are writing applications using it, you can be assured that it is a safe route to go.

Hope this helps.

Share this post


Link to post
Share on other sites

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