|
 |
That's impressive image!
"Christoph Hormann" wrote
> I wonder if adaptive accuracy would be useful for isosurfaces.
Have you tried "adaptive max_gradient" technique, which is already
implemented in 3.5 beta?
I think "adaptive accuracy" is not so useful as "adaptive max_gradient",
The below code is an example.
If you render it with accuracy=0.002 instead of 0.0001, you will
see artifacts near the top of small peaks.
On the other hand, if you render it with adaptive max_gradient
(e.g. "evaluate 2, 1.2, 0.9" instead of "max_gradient 5") and with
accuracy=0.0001, the image quality will be much better and the
rendering speed will be comparable or rather faster than the above.
Note that this technique does not guarantee artifact-free image
and requires experiences to determine the "evaluate" parameters.
(So, this should be only for advanced users.)
BTW, have you tried normal function pattern like below
(commented out) for the foreground? I usually use it in such
cases.
R. Suzuki
//--- the code ------
#version 3.5;
#include "functions.inc"
#declare Radiosity=off;
global_settings {
assumed_gamma 1.0
//max_trace_level 25
#if (Radiosity)
radiosity {
pretrace_start 0.08
pretrace_end 0.04
count 35
nearest_count 5
error_bound 0.05
recursion_limit 3
low_error_factor .5
gray_threshold 0.0
minimum_reuse 0.015
brightness 1
adc_bailout 0.01/2
}
#end
}
#default {
texture {
pigment {rgb 1}
#if (Radiosity)
finish {
ambient 0.0
diffuse 0.6
specular 0.3
}
#else
finish {
ambient 0.1
diffuse 0.6
specular 0.3
}
#end
}
}
// ----------------------------------------
camera {
right x*image_width/image_height
location <0,1.15,-4>
look_at <0,0.8,0>
}
light_source {
<500,500,-500>
color rgb <1, 1, 1>
}
sky_sphere {
pigment {
gradient y
color_map {
[0.0 rgb <0.6,0.7,1.0>]
[0.7 rgb <0.0,0.1,0.8>]
}
}
}
isosurface {
function { y+f_noise3d(x/6,0,z/6)*0.5
+f_noise3d(x*12,y*1,z*12)*0.1
+f_noise3d(x*56,y*20,z*56)*0.04
+f_noise3d(x*120,y*20,z*120)*0.01
+f_noise3d(x*311,y*53,z*311)*0.005
}
contained_by { box { <-150,-3,-150>, <150,0,150> } }
accuracy 0.0001
max_gradient 5
// evaluate 2, 1.2, 0.9
texture {
pigment {
checker
color rgb <1.0, 0.8, 0.6>
color rgb <1.0, 0.0, 0.0>
scale 0.5
}
/* normal{ function{
f_crackle(x*670,y*270,z*670)*0.2}
slope_map {
[0 <0, 1>]
[0.4 <1, 1>]
[0.65 <1,-1>]
[1 <0,-1>] }
}
*/
}
translate y*1.3
}
Post a reply to this message
|
 |