View Full Version : C++ Builder and OpenGL Rendering Contexts

10-03-2001, 11:46 PM
I need to use OpenGL with C++ Builder 5.
I need to create several drawing areas (with input focus) in my application's window. I tried using TImage, but the HDC thst I get (timage->Canvas->Handle) causes wglCreateContext() to fail.
From the documentation, I am now inclined towards switching to TCustomControl for the drawing areas.

I was hoping someone who has been down this road before could make some recommendations.

many thanks

10-04-2001, 12:58 AM
Hi there,

you could use a TPanel and to get the hdc call

HDC dc = GetDC(PanelName->Handle);


Hope it helps


[This message has been edited by MButchers (edited 10-04-2001).]