Dark Bit Factory & Gravity

PROGRAMMING => General coding questions => Topic started by: spathi on August 26, 2013

Title: Simple 3D transform?
Post by: spathi on August 26, 2013
I am looking for a very simple method for coding 3D engines similar to those in early demos where things like spinning spheres made of pixels were featured.

Hidden line and surface elimination is not necessary, nor is rotation of the camera.

Something like this would be nice though pixels would satisfy, and shading is not necessary-- I can do that myself with surface normals on a lookup table.  (I do realize what vectorballs are.)

http://www.youtube.com/watch?v=XUGHoqM7myk

As Z moves away from the camera toward the horizon, how are X and Y transformed by Z?
Title: Re: Simple 3D transform?
Post by: Rbz on August 27, 2013
Take a look on this source code:
http://www.dbfinteractive.com/forum/index.php?topic=5220.msg69873#msg69873
and here
http://www.dbfinteractive.com/forum/index.php?topic=4580.msg61911#msg61911
it might help you out.
Title: Re: Simple 3D transform?
Post by: spathi on August 27, 2013
Thank you.  This is for a game similar to Space Harrier-- needs scaling, pseudo-3D terrain and possibly atmospheric perspective (blending toward sky color toward horizon) and that's about it.

Looks like Shockwave's code is exactly what I needed.
Title: Re: Simple 3D transform?
Post by: lambertodini on November 07, 2013
Thanks for sharing useful information.



http://www.kickexam.com/odeskexams (http://www.kickexam.com/odeskexams)