|
|
AQ <AQ### [at] worldcom> wrote:
>
> I have a virtual block made of several wood that I want use a sphere
> to cut a depression onto to make it into a bowl. When I try it the
> pigment of the sphere shown on the surface hiding the laminations. I
> am sure in the past I could get this to work. Any advice would be
> appreciated.
As Clipka said, the cutaway-textures feature has an *averaging* behavior-- but
that only occurs when you have *overlapping* textured objects (like concentric
solid spheres within spheres.) If you want to see the 'pure' textures of your
various pieces of wood when you carve your bowl, the way to do it is to build
your initial 'block' of laminated wood (prior to CSG) out of separate,
NON-overlapping pieces, each textured individually. It
appears that you have already done this. ;-) Then, use NON-textured spheres
as the cutaway objects, as has already been mentioned.
Here's some example code that I threw together (based on the POV-Ray features in
v3.6.2.) The separate wood 'layers' have very tiny gaps between them, to avoid
overlaps and any coincident-surface problems.
(Side note: The code uses the 'inverse' keyword for one of the cutaway spheres;
you might want to add an additional bounded_by object to the final CSG, for
efficiency.)
#declare Thin_Wood_Layer =
box{<0,0,0>,<2,.14999,2> // not quite .15000 in thickness
// no texture yet
}
#declare Total_Wood_Block= // prior to CSG
union{
object{Thin_Wood_Layer
texture{Wood_Texture_1}
}
object{Thin_Wood_Layer
texture{Wood_Texture_2}
translate .15*y
}
object{Thin_Wood_Layer
texture{Wood_Texture_3}
translate .3*y
}
object{Thin_Wood_Layer
texture{Wood_Texture_4}
translate .45*y
}
object{Thin_Wood_Layer
texture{Wood_Texture_5}
translate .6*y
}
object{Thin_Wood_Layer
texture{Wood_Texture_6}
translate .75*y
}
}
//----- the CSG and the cutaway ------
difference{
object{Total_Wood_Block translate <-1,0,-1>}
// to center it on origin in x and z, for ease of CSG.
// Block is <2,.9,2> in size (minus .00001 in y, actually}
sphere{0,.9 // to carve away the inside of the bowl
// no texture
scale <1,.7,1>
translate .75*y
}
sphere{0,.99 // to carve away the outside of the bowl
// no texture
inverse
scale <1,.7,1>
translate .72*y
}
cutaway_textures
rotate -60*x
rotate -30*y
translate 1.2*y
}
Post a reply to this message
|
|