|
|
(this may be a slightly unusual subject here - I hope it's not off-topic)
A few days ago I posted a message on povray.general about problems I had
getting a torus to render properly - the rendering of it (see
http://www.mmedia.is/~bjj/torus.jpg for instance) looks noisy.
A reply from Micha Riser <mri### [at] gmxnet> pointed out that scaling
everything down by a factor of 0.01 gets rid of the "noise", e.g.:
#include "colors.inc"
camera {
location <-5000,-25000,-40000>
look_at <300,-1300,-1500>
angle 1
scale 0.01 // Omitting this...
}
union {
light_source {
<-5000,-16000,-30000>
color White
}
torus {
66,33 sturm
rotate x*90
translate <-66,116,0>
rotate z*90 rotate y*180 translate <175.5,-970,-1027>
pigment {White}
}
scale 0.01 // ... and this results in a 'noisy' torus ??
}
I then started experimenting with the scale in my original POV file which
contains many more primitives than this and found that when using "scale
0.1" some noise appears but not as much as when not using scale. But
what's really weird is that if I make scale considerably *bigger* than 1
(e.g. 1000) some primitives (including the torus, a parabolic 'antenna'
and more) disappear and also the rendering time increases by a factor of
more than 10 !??
In povray.general Micha Riser, <mri### [at] gmxnet wrote:
>There are some magic constants in the pov source code which control
>that; so I could reduce an other such misbehavior (showing up with very
>small numbers and blobs) by changing one of the constants. Therefore it
>seems to me that some of these contants are chosen quite arbitrarly.
So I started messing with the POV source and managed to make a custom
version of POV. I experimented by changing some magic constants in
torus.c (e.g. ROOT_TOLERANCE from 1.0e-4 1.0e-10) but this did not affect
the torus.
Is anyone here familiar with problems like this ? In particular, it looks
very odd to me that two identical scenes, except for their scale, can
result in two very different rendering results. After all, the relative
size of objects has not changed (a simple example: the biggest sphere is
still 1000 times bigger than the smallest one). So it looks like there
may be *some* magic constant I should change, an 'epsilon value' or
something, however, there are lots of these constants, both in the .c and
.h files. In particular I'm wondering if it might be useful to be able to
change these values depending on the scale of the model. A difference of
1.0e-10 between two numbers may be the smallest difference that is
significant if you have a model where the primitives are of a size on the
order of 10 but if you multiply the model's size by 1.0e10 then 1.0e-10
is no longer significant, something like 1.0 would make more sense as an
'epsilon value'.
Does anyone know which constants I should experiment with changing and in
which source files ?
--
Bjorn Jonsson / bjj### [at] zzzmmediais
Address changed to avoid junk email. Remove yyy and
zzz to reply.
Post a reply to this message
|
|