POV-Ray : Newsgroups : povray.general : ISO optimization : Re: ISO optimization Server Time
5 Aug 2024 18:26:28 EDT (-0400)
  Re: ISO optimization  
From: Christopher James Huff
Date: 5 Aug 2002 14:31:05
Message: <chrishuff-5AF2BF.13205905082002@netplex.aussie.org>
In article <Xns### [at] 204213191226>,
 "Rafal 'Raf256' Maj" <raf### [at] raf256com> wrote:

> > Yes, slow down. Computing a value from a voxel field is obviously
> > slower than using an existing variable. 
> 
> not computing is needed, this voxel field will have no interpolation
> 
> just, for pixels in <0,0,0>-<1,1,1> tak max_gradient 2.0 
> etc

Have you ever done any programming? It doesn't sound like it.
You still have to find the correct voxels and get their value. It is 
very obvious that this will have more overhead than simply using a 
single value.
BTW, I was wrong: you wouldn't just need the gradient value at each end 
of each interval, you would need the gradient values for all the voxels 
the interval goes through. That's quite a bit more overhead...best thing 
would probably be to build a list of all voxels the ray passes through 
and process using the list instead of directly accessing the voxel 
field, sub-intervals could then just use segments of this list. And it 
still isn't foolproof, there could be a high gradient area that falls 
between the voxel samples, though you could supersample the voxels to 
reduce that risk, at a cost of increasing the parse time. It would be 
considerably slower than accessing a constant max_gradient, though it 
might be fast enough to speed up some surfaces.


> while I was thinking of something that.. hmm how to say it... like uhm 
> antialias, or 3d version of binary-tree 

You are thinking of something closer to lossy compression, throwing out 
low-amplitude variations. I believe you are talking about an oct-tree, 
each node is a cube divided into 8 sub-cubes...that could help reduce 
the memory requirements if you are willing to throw away information, 
which shouldn't be a problem for this. In some cases where there is a 
lot of variation in the gradient, it would require more memory...most of 
the voxels and a lot of node pointers. It would also make it even slower 
to find a particular voxel: you would have to descend the tree instead 
of just accessing an element of an array.

-- 
Christopher James Huff <chr### [at] maccom>
POV-Ray TAG e-mail: chr### [at] tagpovrayorg
TAG web site: http://tag.povray.org/


Post a reply to this message

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