|
|
I'd like to convert the following isosurface into a height_field with a
function, but I'm having trouble getting the effect to work. As it is, it
renders INCREDIBLY slowly.
#declare P1 =
function {
pigment {
crackle
color_map { [0.0 rgb 0 ] [0.08 rgb 1 ] }
turbulence 0.2
}
}
#declare P2 =
function {
pigment {
crackle
color_map { [0 rgb 0] [0.025 rgb 1] }
}
}
#declare P3 =
function {
pigment {
wrinkles
color_map {
[0 rgb 0]
[0.025 rgb 0.8]
[0.05 rgb 0.07]
[0.25 rgb 0.02]
[0.275 rgb 1.0]
[0.32 rgb 0.0]
}
turbulence 0.8
}
}
#declare Scale1 = 1.5*ft ;
#declare Scale2 = 0.3*ft ;
#declare Scale3 = 3.0*ft ;
#declare Height1 = 0.6*ft ;
#declare Height2 = 0.3*ft ;
#declare Height3 = 0.5*ft ;
isosurface {
function { y - P1(x/Scale3,0,z/Scale3).x*Height3 -
P3(x/Scale3,0,z/Scale3).y*Height3 - P2(x/Scale2,0,z/Scale2).x*Height2 }
//max_gradient 10
evaluate 1.2 4, 0.7
accuracy 0.01
threshold -(Height1+Height2)
contained_by { box { <-1e9, -3.0, -1e9> <1e9, Height3, 1e9> } }
all_intersections
}
And no, a patterned texture won't do.
A.D.B.
Post a reply to this message
|
|
|
|
"Anthony D. Baye" <Sha### [at] spamnomorehotmailcom> wrote:
> I'd like to convert the following isosurface into a height_field with a
> function, but I'm having trouble getting the effect to work. As it is, it
> renders INCREDIBLY slowly.
Isosurfaces do that, but sometimes the speed can be improved. The part that
caught my attention was this:
> evaluate 1.2 4, 0.7
> accuracy 0.01
> threshold -(Height1+Height2)
> contained_by { box { <-1e9, -3.0, -1e9> <1e9, Height3, 1e9> } }
> all_intersections
> }
You didn't post the camera portion, so I can't tell whether or not this is
exactly what you want, but do you really need all intersections? Are you using
evaluate for every render? Once you've found a good max gradient that works,
specify it. Is that much of the object actually in view? If not, why does the
containing shape need to be so large?
It is hard to know what you wanted without knowing more about:
the camera - this may change the shape and size of the container shape, which
can greatly influence rendering times.
the isosurface texture - if it is partially transparent, the use of all
intersections would be important, so that you could see interior faces that
would not be visible otherwise.
> And no, a patterned texture won't do.
>
> A.D.B.
I'll take your word for it, I guess?
-Reactor
Post a reply to this message
|
|