开发者

Is it possible for OpenGL to work with .NET form?

开发者 https://www.devze.com 2023-03-31 02:08 出处:网络
I know that Open开发者_开发知识库GL can work with a classic window created by CreateWindow and handles through device context (GetDC), but is it possible for OpenGL to work with .NET form? I mean turn

I know that Open开发者_开发知识库GL can work with a classic window created by CreateWindow and handles through device context (GetDC), but is it possible for OpenGL to work with .NET form? I mean turning .NET form into a OpenGL window.


Yes, this is possible. OpenGL requires window handle, which is available through Form.Handle property. To get device context, call GetDC with this handle.

http://www.codeproject.com/KB/miscctrl/OpenGLViewWinForms.aspx

0

精彩评论

暂无评论...
验证码 换一张
取 消