herez some of the code that might help
“setviewport code”
…
wglMakeCurrent mlngPic1hDC, mlngWindowcontext
Pic1.Scale (-100, 100)-(100, -100)
intWidth = Pic1.ScaleWidth
intHeight = Pic1.ScaleHeight
If intHeight = 0 Then
intHeight = 1
End If
glViewport -100, -100, intWidth, intHeight
“setting the projection”
glMatrixMode GL_PROJECTION
glLoadIdentity
glFrustum -100, 100, -100, 100, 10, 210
glMatrixMode GL_MODELVIEW
glLoadIdentity
gluLookAt dblXCam, dblYCam, dblzcam, 0, 0, 100, 0, 1, 0
glShadeModel smSmooth
glEnable glcDepthTest
glEnable (glcBlend)
“rendering function”
glMatrixMode GL_MODELVIEW
glLoadIdentity
glEnable (GL_DEPTH_TEST)
'set back color of map
glClearColor 0, 0, 0, 1
glClear clrColorBufferBit
glClear clrDepthBufferBit
gluLookAt dblXCam, 0, dblzcam, 0, 0, 100, 0, 1, 0
glEnable (glcLighting)
glEnable glcLight0
glEnable glcColorMaterial
glColorMaterial faceFrontAndBack, cmmAmbientAndDiffuse
glPushMatrix
glLineWidth 2
glColor3f 0, 1, 0
glBegin bmLines
glVertex3f -99, -99, 209
glVertex3f -99, 199, 209
glEnd
glColor3f 1, 1, 1
glBegin bmLines
glVertex3f -99, -99, 209
glVertex3f -99, -99, 11
glVertex3f -99, -99, 209
glVertex3f 99, -99, 209
glEnd
…