|
|
On 05/16/2016 12:22 PM, EdR wrote:
> Hi,
>
> I'm having a problem rendering emitting objects, where transparent objects seem
> to be blocking the light from others behind.
>
> It can be seen in the minimal code (part of a larger scene) below and in this
> render https://www.dropbox.com/s/fki0av19wjwnbvu/minimal_bug_example.png?dl=0
>
> The left hand cylinder seems to obscure the right hand one, and I can't work out
> why. Can anyone help?
>
> Thanks!
>
> ----
> #include "colors.inc"
> camera {
> location <15,0,40>
> look_at <5,0,0>
> angle 45
> }
>
> //background
> background { color Black }
>
> #declare thick = 1.5;
> union {
> #for (ii, 8, 9)
> cylinder{
> (ii*thick*x), (((ii+1)*thick*x)-0.000001), 1
> pigment { Clear }
> hollow
>
> interior {
> media {
> emission White * 0.03
> }
> }
> scale <1,12.4,12.4>
> }
> #end
> }
> ----
>
>
>
>
I believe you are running into an internal a numerical cut off in the
media sampling code(1). If you increase the overlap between cylinders,
things work in my tests.
In addition, it would be more normal to use a merge (which eliminates
internal boundaries) when using media or transparency vs a union - but
maybe you want some different effect. The pigment and hollow can also be
applied to the entire merge/union instead of each cylinder when they are
identical.
My version of your code following some of the advice above :
merge {
//cylinder{ (1.5*x), ((3.0*x)-0.000001), 1 pigment { Red } }
//cylinder{ (3.0*x), ((4.5*x)-0.000001), 1 pigment { Green } }
//cylinder{ (1.5*x), ((3.0*x)-0.00001), 1 pigment { Clear } } // Fail
//cylinder{ (3.0*x), ((4.5*x)-0.00001), 1 pigment { Clear } }
cylinder{ (1.5*x), ((3.0*x)-0.0001), 1 pigment { Clear } } // OK
cylinder{ (3.0*x), ((4.5*x)-0.0001), 1 pigment { Clear } }
hollow
interior {
media {
emission White * 0.03
}
}
//scale <1,12.4,12.4>
}
Bill P.
(1) - How individual rays move through the shapes likely will also
affect where this accuracy / cut off issue is seen. As would, I expect,
changing the media sampling criteria.
Post a reply to this message
|
|