forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


OpenGL with GadgetX DEMO

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> Other Product Support/Announcements
View previous topic :: View next topic  
Author Message
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Mon Jul 23, 2007 7:48 pm    Post subject: OpenGL with GadgetX DEMO Reply with quote

Hi All,
Just wanted to give you a peek of what I have been working on over this past month. I have attached a demo that uses VDS/GadgetX/OpenGL. It's just a demo and it is Exe only. You will need GadgetX in the path to execute the demo. I will be releasing the source code on my forum as soon as I get a few more demos built.



Triangle_GadgetXdemo.zip
 Description:
OpenGL and GadgetX DEMO needs GadgetX.dll, OpenGL32.dll, and GLU32.dll

Download
 Filename:  Triangle_GadgetXdemo.zip
 Filesize:  190.6 KB
 Downloaded:  1428 Time(s)


_________________
Home of

Give VDS a new purpose!
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Rubes_sw
Valued Contributor
Valued Contributor


Joined: 11 Jun 2001
Posts: 625
Location: Northern Ireland

PostPosted: Mon Jul 23, 2007 8:05 pm    Post subject: Reply with quote

Very Cool !

Nathan
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Mon Jul 23, 2007 8:10 pm    Post subject: Reply with quote

Here is a ScreenShot of the demo running in the VDS IDE.


opengl_IDE.png
 Description:
Big ScreenShot OpenGL running in the VDS IDE.
 Filesize:  209.94 KB
 Viewed:  1513 Time(s)

opengl_IDE.png



_________________
Home of

Give VDS a new purpose!
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Mon Jul 23, 2007 8:40 pm    Post subject: Reply with quote

Thanks Nathan,
Just so you know this demo did not take a month to write. I spent most of the past month looking for suitable 3D graphics engines that were simple and freely available. Most of those engines had stuff that I did not like or I felt that they required too much of a learning curve. OpenGL is a simple state machine and can be accessed from it's API functions. Due to all the constants and structures it would not be easy to use OpenGL directly with the VDS @lib() function so I decided to build the demos with GadgetX since it has built-in facilities for these and it was less confusing than using @Substr() to parse out the structure fields. Also I had a question about how VDS calls all floating point numbers as REAL's (Delphi implementation of a Double floating point number). Much of the OpenGL functions require Single's. If you try using doubles in place of floats in a function call you can corrupt the functions stack and crash the program.

Here is a few of the 3D engines I looked at.
SDL
RAGE
3DState
Parrot
Xtreme3D
GLFW (OpenGL FrameWork)
OGRE
mmEngine
AC3D
Bolt3D
CrystalSpace
Dreamotion
Genesis3D
Irrlicht
Jet3D
Panda3D
R3D

Out of all these 3D engines there were very few that I liked. The main one that is of interest to me is SDL. Most others want to make their own window which I did not like because I wanted a 3D engine that you could integrate with the VDS Dialog and enhance what was already there. The reason I choose to start writting demos with OpenGL for 1 the DLL comes with windows and or your video card and 2 there is lots of information out there about it and 3 most other 3D engines are wrappers for either OpenGL or DirectX anyway so I am cutting out the middle man so to speak.

After the OpenGL series of demos I will probably do several SDL demos since SDL is more than just a graphics engine it is a full 3D game engine and it is free. Keyword here is free because many of the above have steep Royalities attached for building programs for commercial use with them.

_________________
Home of

Give VDS a new purpose!
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Aslan
Valued Contributor
Valued Contributor


Joined: 31 May 2001
Posts: 589
Location: Memphis, TN USA

PostPosted: Mon Jul 23, 2007 9:31 pm    Post subject: Reply with quote

Very Nice! Surprised
Back to top
View user's profile Send private message Send e-mail
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Mon Jul 23, 2007 9:40 pm    Post subject: Reply with quote

Also if you guys have not noticed yet. That demo above uses 100% CPU. This is due to the fact that I am trying to follow along with the tutorials at NeHe In these tutorials they show how they bypass the message pump which gives a little speed to the animation but really hard on the rest of the system. Also for really smooth graphics I used the following lines in the demo.

Code:

OPTION PRIORITY,HIGH
OPTION SLEEPTIME,1


This just chews up your CPU but makes for an impressive demo Wink Very Happy

_________________
Home of

Give VDS a new purpose!
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
DaveR
Valued Contributor
Valued Contributor


Joined: 03 Sep 2005
Posts: 413
Location: Australia

PostPosted: Tue Jul 24, 2007 3:08 am    Post subject: Reply with quote

Aslan wrote:
Very Nice! Surprised

Yep, very nice indeed.

If by SDL you're referring to 'Simple DirectMedia Layer' then technically it's not free as in freeware. It's distributed under GNU LGPL version 2.

_________________
cheers

Dave
Back to top
View user's profile Send private message
vdsalchemist
Admin Team


Joined: 23 Oct 2001
Posts: 1448
Location: Florida, USA

PostPosted: Tue Jul 24, 2007 10:57 am    Post subject: Reply with quote

DaveŽ wrote:

If by SDL you're referring to 'Simple DirectMedia Layer' then technically it's not free as in freeware. It's distributed under GNU LGPL version 2.


Dave,
Yes Free as in no coin or paper money is required to use the software as part of your product for commercial or free. With that said I always give credit where credit is due. Also when it comes to open source software I normally send an email to the authors requesting permission to use their software with mine reguardless if I plan to sale my software or not. I do this out of respect for the authors. I also display their copyright somewhere promnately in my software and documentation. I do this for all third party software that my software uses even software that I bought and paid for. Emails are called insurance in this game. If you use this method you will be protected and will not need to worry about it byting you later.

_________________
Home of

Give VDS a new purpose!
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> Other Product Support/Announcements All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group