|
|
Hello!
I have a problem with
intersection or difference
using objects I defined.
Thank you very much!
Greetings,
Chris
Code
// create a smooth blobby shape
#declare RadiusVal = 2.9; // 1.0; // (0 < RadiusVal) outer sphere of
influence on other components
#declare StrengthVal = 0.4; // (+ or -) strength of component's radiating
density
#declare MyBlob1 = object {
blob {
// threshold (0.0 < threshold <= StrengthVal) surface falloff threshold #
threshold 0.6
sphere { < 0.75, 0, 0>, RadiusVal, StrengthVal }
sphere { < 3.75, 0, 0>, RadiusVal, StrengthVal }
sphere { < 0.75, 0, 1.25>, RadiusVal, StrengthVal }
sphere { < 3.75, 0, 1.25>, RadiusVal, StrengthVal }
//sphere { <-0.375, 0.65, 0>, RadiusVal, StrengthVal }
//sphere { <-0.375, -0.65, 0>, RadiusVal, StrengthVal }
//cylinder { -z, +z, RadiusVal, StrengthVal }
// [sturm]
scale 2
texture {
pigment {
color rgb <0.8,0.8,1.0>
}
finish{
diffuse 0.3
ambient 0.0
specular 0.6
reflection {
0.8
metallic
}
conserve_energy
}
}
}
rotate <45, 45, 0>
}
#declare MyBox1 = object { box { <-1, -1, -1>, <1, 1, 1> inverse } }
// Test
// MyBlob1
// CSG difference, subtract intersections of shapes 2...N from Shape1
intersection {
MyBlob1
MyBox1
}
Post a reply to this message
|
|
|
|
You don't need the extra 'object' wrapper around your #declared objects...
#declare MyBox1 = object { box { <-1, -1, -1>, <1, 1, 1> inverse } }
could be written as
#declare MyBox1 = box { <-1, -1, -1>, <1, 1, 1> inverse }
It will still work the same when used as
object{MyBox1}
It has nothing to do with your 'problem' though...
Post a reply to this message
|
|