Twokinds ARCHIVE Forums

This forum is for the preservation of old threads from before the forum pruning.
It is currently Sun Apr 20, 2025 5:49 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Advanced 3D programming.
PostPosted: Sun Mar 23, 2008 4:22 am 
Offline
Citizen
User avatar

Joined: Mon Mar 17, 2008 5:06 am
Posts: 66
Location: Perth, Australia
Hey guys.. I'm currently doing a unit at university at the moment on Advanced 3D Programming... and my current task is to implement a terrain generator. I need to use the diamond/square fractal terrain algorithm and then export the terrain data to an image file (preferably PGM/PPM format.).

The second task in this is to render the terrain by importing the greyscale image as a heightmap and generate and render the 3d mesh.

Any ideas/help?

(Btw.. I'm using C++ OpenGL.)

I've found code examples online, but they are generally in C. I also have a base code which I can use to call a TerrainGenerator class.

Thanks in advance for the help.

Oh, and I'm not worried if no one knows what I'm talking about, everyone in my class struggles with this unit.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Mar 23, 2008 11:24 pm 
Offline
Templar Inner Circle
User avatar

Joined: Wed Jan 17, 2007 12:33 pm
Posts: 2879
Location: Nebraska, USA
Check into Prima Tech's Game Development Series book "OpenGL Game Programming" by Hawkins and Astle. Doing a heightfield mapped 3D terrain map from a greyscale image is literally one of the examples in Chapter 8.

Otherwise, we're going to need to know more about what you need help with -- especially since you've got a base class to work with that we know nothing about.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 27, 2008 9:28 pm 
Offline
Master
User avatar

Joined: Thu Nov 22, 2007 9:07 pm
Posts: 262
Location: Gatineau, QC, CA
this is why i dont do modelling. it's too much trouble, there are so many 3d modelling programs you always have to master each and every one thats out for like 300 - 1000 dollars a program each. For example swbfii uses xsi.
sorry but i cant help you on this one :( but i can point you in the right direction, pspad- it's better for open source coding. it has a hex feature which is nifty too. If your doing any type of code, trust me, get pspad. it has C# C+ C++ or whatever that is on it with tons of snippets too.
pspad.com


Top
 Profile  
 
 Post subject:
PostPosted: Sat Apr 12, 2008 6:34 am 
Offline
Grand Templar
User avatar

Joined: Sat Mar 15, 2008 10:19 am
Posts: 1155
Location: In your armory stealing your weapons
Don't you the regular render proccess use ray-tracing. I acctually runs better with more polygons then with less. It also does perfect reflections and other stuff that normal rendering can't do well. It is very insuficiant though, some much processing power needed, it has an up side though you don't need a graphics card.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 16, 2008 6:06 am 
Offline
Templar Inner Circle
User avatar

Joined: Tue Mar 04, 2008 7:51 pm
Posts: 3468
Location: In the Ikki Tousen world. Leave me alone.
ooh, C++. my fave programming language, and i know A LOT of programming languages for a nearly 18 year old guy


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 1 guest


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

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group