Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: VB
I would like to Develop OpenGL Applications with VB. I used to do it with C++WinApi Programming. The Problem with using it with VB is: How will i insert an OpenGL view port in VB. I used Tao to Make a View port. I initialized its Contexts. Everything was fine Except the Output Was Terrifically Ridiculous.
for Eg: if I give a simple code:
                   glClearColor(0.0, 0.0, 0.0, 0.0)
                   glColor3f(1.0, 1.0, 1.0)
                   glOrtho(−1.0, 1.0, −1.0, 1.0, −1.0, 1.0)
                   glVertex2f(−0.5, −0.5)
                   glVertex2f(−0.5, 0.5)
                   glVertex2f(0.5, 0.5)
                   glVertex2f(0.5, −0.5)
the normal output must be like a White Rectangle, the output is like some Deformed Polygon.
I know Tao is Usually used with C#.What will I do with VB. thanks IN advance!!
Posted 28-Sep-12 19:25pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

I think the glBegin(GL_POLYGON) is wrong. Change it into glBegin(GL_TRIANGLES)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 225
1 Richard MacCutchan 100
2 kbrandwijk 90
3 ChauhanAjay 80
4 ProgramFOX 80
0 Sergey Alexandrovich Kryukov 9,050
1 OriginalGriff 8,151
2 CPallini 2,613
3 Richard MacCutchan 2,221
4 Abhinav S 1,928

Advertise | Privacy | Mobile
Web03 | 2.8.140827.1 | Last Updated 29 May 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100