axnjaxn / ReiTrei

A ray tracer in C++ / SDL supporting Monte Carlo effects
http://www.axnjaxn.com/
0 stars 0 forks source link

Reimplement ideal shapes #47

Open axnjaxn opened 10 years ago

axnjaxn commented 10 years ago

Cylinder, Cone, Torus would be good choices.

axnjaxn commented 10 years ago

Cone and Cylinder can be the same if the right transformations are used. The no-caps option is probably a good idea, too. I think cone should be defined by two points and two radii, while the torus could be represented by a point, an axis vector, and two radii.

axnjaxn commented 10 years ago

Basic intersection code for cone works. Still needs a better way of defining it.

axnjaxn commented 10 years ago

Until pinch works, the cone will have to be implemented separately from the cylinder.