Jump to content
  • Advertisement
Sign in to follow this  
Mia Blue

OpenGL How do I make a Pseudo 3D Road?

This topic is 1547 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How would you go about making a pseudo 3D road? I'm not sure. The effect I'm trying to get is something that looks like Pole Position or Outrun. To get this effect, you would render each scanline separately, yes? That's what I got from Lou's Pseudo 3D page (http://www.extentofthejam.com/pseudo/) and a few other sites...but I still don't understand how they're doing it graphically. Furthermore, SDL can't scale, and I haven't learned OpenGL yet (I want to use just SDL for now so I can learn it before moving into OpenGL too). Any help would be appreciated.

Share this post


Link to post
Share on other sites
Advertisement

Yeah, that's the gist of it. Scale down each scanline more as its closer to the horizon, and shift it left or right to show turns. you can get the lay of the road by defining a 2D vector representation of the track -- a spline would do nicely. With a little extra work you can extend the spline to 3D to simulate valleys and hills.

 

SDL can certianly scale and do everything you need it to. There's an Outrun style engine written in C and SDL called Cannonball. Have a look at the source.

Edited by Ravyne

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!