POV-Ray : Newsgroups : povray.advanced-users : Question3. Simple Raytracer : Re: Question3. Simple Raytracer Server Time
28 Jul 2024 18:24:03 EDT (-0400)
  Re: Question3. Simple Raytracer  
From: Sascha Ledinsky
Date: 28 Apr 2004 12:59:34
Message: <408fe2f6@news.povray.org>
If you don't need reflections or refractions, a z-buffer approach might be the 
better choice here because it's got no memory problems when rendering zillions 
of triangles (as they are passed through the pipeline one by one).

If you need shadows, you could precompute shadow-maps for each lightsource. For 
transparency, a modified z-buffer (which stores a list of rgba-colors and 
z-values for each pixel) is needed. For the things you described, Java3D or one 
of the Java OpenGL wrappers might have all the features you're looking for - if 
not, I have written some Java code that uses a zBuffer to render phong-shaded 
triangles (but without transparency yet), just send me an email if you are 
interested in the code.

If you need very high resolutions or high levels of supersampling, you'll 
quickly run into another memory problem with this approach: you'd need to store 
at least color and z-value for each pixel (with the modified "transparency" 
version even more) in memory. The usual solution is to render "buckets", e.g. 32 
x 32 pixel regions - so you would end up with something like REYES.

There's even a RenderMan compatible REYES renderer, written in Java, out there - 
check out http://jrman.sourceforge.net

-Sascha


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.