Solved

openGL or active x for drawing 3d

Posted on 2009-05-09
12
881 Views
Last Modified: 2013-12-26
Hi.
I'd like to make my programming easier by using openGL or some active x to allow me to draw surfaces (square planes) and do rotation.
The reason that I don't want to do the transformations by myself is that its hard to draw planes that intersect.
I've tried:
http://www.ondotnet.com/pub/a/dotnet/2003/04/28/opengl.html
http://embedded.org.ua/opengles/lessons.html
and some other free dll's.
but I could not get them to work.
They complain about the missing glaux,glu,...
and then i realized that these are no longer in vb 2008, ...i tried to fix the errors, but there are still errors such as "Error spawning 'cmd.exe'."
Could you please submit a vb net 2008 code that actually works to draw a simple plane?
Thanks
0
Comment
Question by:kouroshparsa
  • 8
  • 4
12 Comments
 
LVL 20

Accepted Solution

by:
ikework earned 300 total points
ID: 24348573
hi kouroshparsa

if you want to start learning opengl, nehe has a lot of good tutorials, from first stepsto advanced technics, plus they have all tutorials as projects to download, so you dont have to worry about that. nehe is here:

http://nehe.gamedev.net

i recommend you to read particulary the first lessons ..

if you have any question, dont hesitate to ask .. :)


ike
0
 
LVL 2

Author Comment

by:kouroshparsa
ID: 24359727
Thanks for the comment.
I actually have looked at that website.
The sample codes do not work on VS Basic 2008 because of the header files:
#include <gl\gl.h>                                    
#include <gl\glu.h>      
#include <gl\glaux.h>
That's what I was talking about.
0
 
LVL 20

Expert Comment

by:ikework
ID: 24361805
there is visual basic code at the bottom of each lesson too ..
0
Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

 
LVL 20

Expert Comment

by:ikework
ID: 24361838
0
 
LVL 2

Author Comment

by:kouroshparsa
ID: 24370837
I finally got it working. It needs a CSGL library , and installing the library does not work on vista, so i copied the library to the project folder and linked the project to it.
Fankly, i wish to get to know openGL quickly.

by the way, do you know why we use the "translatef" method to draw something else?
Don't all the shapes use the same coordinate?
0
 
LVL 20

Expert Comment

by:ikework
ID: 24371871
>> by the way, do you know why we use the "translatef" method to draw something else?
>> Don't all the shapes use the same coordinate?

"translatef" is used to put an object to its position in 3D-space. imagine you have a chair and a table, you dont want to render them both at the same position, do you?
0
 
LVL 2

Author Comment

by:kouroshparsa
ID: 24400872
no. but still it's ambiguous.
Let's say i want to draw a line from (100,100) to (100,200).

The demo that i downloaded does this:

draws a line from (0,0) to (0,100)
then translates it by <100,100>

so, is there any problem with creating a line object directly from (100,100) to (100,200) in openGL ?
0
 
LVL 20

Expert Comment

by:ikework
ID: 24401695
>> so, is there any problem with creating a line object directly from (100,100) to (100,200) in openGL ?

no, you can draw it directly like that
0
 
LVL 20

Expert Comment

by:ikework
ID: 24401722
its used to move complex objects like a car. if you want to move and rotate it in the *world*, you can use "translate" and "rotate", without recalculating the cars data (local-coordinates).
all you have to *recalculate* in order to move it, are the parameters for the "translate"-function, without changing the cars local-coordinates.
0
 
LVL 20

Expert Comment

by:ikework
ID: 24401729
btw. if you have open-gl specific questions, there is an opengl area here too:

http://www.experts-exchange.com/Programming/Game/Game_Graphics/OpenGL/
0
 
LVL 2

Author Comment

by:kouroshparsa
ID: 24404251
Thanks alot ikework.
0
 
LVL 20

Expert Comment

by:ikework
ID: 24405590
you're very welcome .. good luck, eh .. :)
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
Recently, in one of the tech-blogs I usually read, I saw a post about the best-selling video games through history. The first place in the list is for the classic, extremely addictive Tetris. Well, a long time ago, in a galaxy far far away, I was…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now