|
![](/i/fill.gif) |
I have another question...
See, I was playing around with isosurfaces and created one for making a
cylinder:
isosurface {
function {sqrt(x*x+z*z)-1}
threshold 0
accuracy 0.001
max_gradient 4
contained_by{sphere{0,2}}
pigment {rgb 1}
}
Pretty simple stuff.
The thing is, that if I enclose the function sqrt(x*x+z*z)-1 with the abs()
command...
isosurface {
function {abs(sqrt(x*x+z*z)-1)}
threshold 0
accuracy 0.001
max_gradient 4
contained_by{sphere{0,2}}
pigment {rgb 1}
}
The cylinder is not shown anymore!
I just don't get it...
If the result of sqrt(x*x+z*z)-1 is 0, when I find the absolute value of it, it
should still be 0... and if it's any other value, it shouldn't matter, as when I
find the absolute value of it it would not be 0 anyway...
So the isosurface should exist in the same area that the one without the abs()
command. Or not?
I need some help here, as I'm trying to create some more complex isosurfaces
using the abs() command, and I can't get on it if I still can't understand how
isosurfaces work...
I thought that if you take any point inside the isosurface's container, replace
the x, y and z values in the function for the values of the point, and the
result of the operation is equal to the threshold, the isosurface exists in that
point...
Is that correct?
Post a reply to this message
|
![](/i/fill.gif) |