POV-Ray : Newsgroups : povray.general : Scanline rendering in POV-Ray : Re: Raytracing individual objects Server Time
4 Aug 2024 22:13:46 EDT (-0400)
  Re: Raytracing individual objects  
From: Christopher James Huff
Date: 4 Jun 2003 01:28:09
Message: <cjameshuff-4545C9.00205104062003@netplex.aussie.org>
In article <3edcd7d5$1@news.povray.org>,
 "Ray Gardener" <ray### [at] daylongraphicscom> wrote:

> One difficulty I have with doing that is that
> sometimes its easier to drive a shader using
> some stepped coordinate system of the primitive rather
> than the world locations a raytracer returns.

What stops you from doing the same thing with raytracing? What makes you 
think you can only compute world coordinates?


> For example, when scanlining a heightfield,
> I do it cell by cell, so rocks can be distributed
> based on how likely a cell is to be occupied.
> With raytracing, I have to derive the cell
> coords, and then maintain some kind of map
> to keep track of which cell was painted with what.

No you don't...why would you do this? You're just scattering rocks 
around. Just use trace() to place them on the surface at random 
locations. If you want an uneven distribution, use some function to 
control the probability of a rock landing.


> Displacement shading is also easier when scanlining.
> At least, I haven't figured an easy way to do it
> when raytracing.

Sounds like you're talking about something like this:
http://www.cs.utah.edu/~bes/papers/height/paper.html

There is a landscape example with the equivalent of 1,000,000,000,000 
triangles. And instead of generating and discarding millions (or 
billions) of unused microtriangles, it generates them as needed.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

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