POV-Ray : Newsgroups : povray.general : Help with cutaway_textures : Help with cutaway_textures Server Time
29 Jul 2024 18:29:44 EDT (-0400)
  Help with cutaway_textures  
From: Solar Mike
Date: 13 Dec 2010 23:20:00
Message: <web.4d06f017fc8a40ac374ca5240@news.povray.org>
Hi,

I don`t seem to be able to get cutaway_textures to work the way I`m expecting
and I am hoping someone here could set me straight.  The following is a snippit
of code and I would have expected the intersection to have left the texture of
wood.

#macro myWood()
    union {
        #local wPos = 0;
        #while (wPos < wWood)
        object {
            board(lWood, tWood, wWood/3)
            translate <0, 0, wPos>
        }
        #local wPos = wPos + wWood/3;
    #end
    translate 50*y
    }
#end

intersection {
    myWood()
    object {
        cylinder {<wWood/2, 0, lWood/2>,<wWood/2, 150, lWood/2>, lWood/4 }
        texture { pigment { rgb <.1, .2, .8>}}
    }
    cutaway_textures
}

I end up with a cylinder with a wood grained top but blue sides.

Any suggestions?
Thanks.


Post a reply to this message

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