|
![](/i/fill.gif) |
Try rendering this in MegaPov 0.3 with and without the default{}
statement.
You'll see that the shadow from the transparent disc will become
black when default{} is present.
sig.
default {
texture { pigment { rgb x } }
}
disc { <0, 10, 0> y, 35, 10
pigment { color rgbf <1,.97,1, .9> }
//normal { wrinkles 0.01 scale <10,1,10> }
finish {
specular .8
roughness 0.001
ambient 0
diffuse 0
reflection .1
}
}
box { <-5, -1, -5 >*100 <5, -.001, 5>*100
pigment {colour rgb <0,0,.1>}
finish {
diffuse .9
brilliance .4
specular .6
roughness 0.2
ambient .05
}
}
camera {
location <2 ,5 ,9>*12
look_at <-1 , 0 ,13>
angle 50
}
light_source { <-2, 2, -5>*1000 color rgb 1 }
Post a reply to this message
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
Sigmund Kyrre Aas <as### [at] stud ntnu no> wrote...
> Try rendering this in MegaPov 0.3 with and without the default{}
> statement.
> You'll see that the shadow from the transparent disc will become
> black when default{} is present.
>
I found and fixed the problem.
Here's a detailed description:
The problem was with a flag (HAS_FILTER) and another flag (POST_DONE) that
are internal properties of pigments and textures. If a pigment has any
filter or transmit, then the HAS_FILTER flag should be set after the texture
has been parsed (what is called a post-process step). Once that
post-processing is done, POST_DONE gets set to true. Somehow the POST_DONE
of the default texture got copied to the object's texture. Because of this,
MegaPov thought it already did the post-processing, and therefore HAS_FILTER
never got set.
When doing shadow computations, POV uses a shortcut: if HAS_FILTER is not
set, then it knows that the object will block 100% of light, and therefore
does not need to waste computations calculating the texture.
In this case, HAS_FILTER was not set, so POV didn't even check to see if the
filter existed during shadow computations.
BTW, I do not know why this is not visible in the official version.
Probably a line got deleted in MegaPov during the addition of one of the
patches.
-Nathan
Post a reply to this message
|
![](/i/fill.gif) |