buddhi1980 / mandelbulber2

Official repository for Mandelbulber v2
GNU General Public License v3.0
894 stars 116 forks source link

fractal vanishes when activating limits #877

Closed taurus66 closed 2 years ago

taurus66 commented 3 years ago
System information (version)
Detailed description

The parameter below contains a hybrid fractal - asurf pseudo - and renders normal until you activate limits (rendering engine). Then you got a super fast rendered uni color screen. No fractal left.

Steps to reproduce

Mandelbulber settings file

version 2.25

only modified parameters

[main_parameters] ambient_occlusion_color c800 c800 c800; ambient_occlusion_enabled true; ambient_occlusion_quality 10; basic_fog_enabled true; brightness 1,15; camera -2,59089172797078 -0,78976239486172 2,25074477097736; camera_distance_to_target 2,86634681696843; camera_rotation -72,059088705557 -34,5224016222199 1,74810453448461; camera_top 0,548316917839529 0,145469404426531 0,82352122619077; check_for_bailout_1 false; contrast 1,13; DE_factor 0,75; detail_level 2,5; dont_add_c_constant_1 true; dont_add_c_constant_2 true; formula_1 73; formula_2 1613; formula_iterations_1 20; formula_iterations_2 50; gamma 1,1; glow_intensity 0,05; hybrid_fractal_enable true; image_height 768; image_proportion 3; image_width 1152; julia_c 0 0 -0,0303343148569927; julia_mode true; light1_is_defined true; light1_rotation -33,9 44,75 0; mat1_is_defined true; MC_soft_shadows_enable true; N 40; target -0,344128542877221 -0,0623056155798132 0,62630459062904; [fractal_1] mandelbox_scale 1; transf_addition_constant_111 0,985 0,985 1; transf_minimum_radius_05 0; transf_rotation 0 90 0; [fractal_2] transf_offset_0005 0,01; transf_scale_1 0,48;

TasMania17 commented 3 years ago

Same result with MDBB 2.26 on Xubuntu. No console error message and a blank work area. Really nice fractal Taurus :)

TasMania17 commented 3 years ago

When I click 'Reset view' on the RHS navigation pane the fractal also disappears but with a white screen.

TasMania17 commented 3 years ago

I found by increasing the maxiter (Maximum number of iterations) at the top of the Rendering engine tab to 5120, then Limits can be used. It slows down rendering a lot.

Reset view still goes to nothing.

buddhi1980 commented 3 years ago

It is very strange case. There must me something wrong in the code. I will find it.

buddhi1980 commented 3 years ago

To find the issue I have reduced problem to this case

# Mandelbulber settings file
# version 2.26
# only modified parameters
[main_parameters]
camera -2,44662749347816 -1,75131386312656 2,44212502971273;
camera_distance_to_target 3,36567556858063;
camera_rotation -52,4488252845148 -38,2219016139387 1,74810453448451;
camera_top 0,508881909389058 0,352723790213931 0,785254818586722;
formula_1 73;
image_proportion 2;
julia_c 0 0 -0,104400847517897;
keyframe_last_to_render 0;
light1_is_defined true;
limit_max -0,056284444090149 0,655338735330185 1,98630969082133;
limit_min -2,22736840747235 -0,788551818337997 -0,696807047305702;
mat1_is_defined true;
mat1_surface_color_gradient 0 fd6029 999 698403 1999 fff59b 2999 f5bd22 3999 0b5e87 5000 c68876 5999 a51c64 7000 3b9fee 7999 d4ffd4 9000 aba53c;
N 31;
target -0,350325908648698 -0,139788272117639 0,359752112124391;
[fractal_1]
mandelbox_scale 1;
transf_rotation 0 90 0;

This simple example still reproduces the problem when limits are enabled. These settings are specific, because fractal scale = 1.0, so fractal calculation goes always to maxiter. I suppose here is some hidden problem.

TasMania17 commented 2 years ago

I found another solution to this issue. Limits can be enabled by reducing the iterations in the first and second slots and adding another fractal in the third slot. I think the problem could be caused by too high iterations values as well as a DIFS fractal in the last slot. I've found a DIFS rarely works in the last slot for hybrid fractals.

# Mandelbulber settings file
# version 2.26
# only modified parameters
[main_parameters]
ambient_occlusion_color c800 c800 c800;
ambient_occlusion_enabled true;
ambient_occlusion_quality 10;
basic_fog_enabled true;
brightness 1.15;
camera -2.59089172797078 -0.78976239486172 2.25074477097736;
camera_distance_to_target 2.86634681696843;
camera_rotation -72.059088705557 -34.5224016222199 1.74810453448461;
camera_top 0.548316917839529 0.145469404426531 0.82352122619077;
check_for_bailout_1 false;
contrast 1.13;
DE_factor 0.75;
detail_level 2.5;
dont_add_c_constant_1 true;
dont_add_c_constant_2 true;
formula_1 73;
formula_2 1613;
formula_3 66;
formula_iterations_2 4;
gamma 1.1;
glow_intensity 0.05;
hybrid_fractal_enable true;
image_height 768;
image_proportion 3;
image_width 1152;
julia_c 0 0 -0.0303343148569927;
julia_mode true;
keyframe_last_to_render 0;
light1_is_defined true;
light1_rotation -33.9 44.75 0;
limits_enabled true;
mat1_is_defined true;
mat1_surface_color_gradient 0 fd6029 999 698403 1999 fff59b 2999 f5bd22 3999 0b5e87 5000 c68876 5999 a51c64 7000 3b9fee 7999 d4ffd4 9000 aba53c;
MC_soft_shadows_enable true;
N 40;
target -0.344128542877221 -0.0623056155798132 0.62630459062904;
[fractal_1]
mandelbox_scale 1;
transf_addition_constant_111 0.985 0.985 1;
transf_minimum_radius_05 0;
transf_rotation 0 90 0;
[fractal_2]
transf_offset_0005 0.01;
transf_scale_1 0.48;
taurus66 commented 2 years ago

Indeed Buddhi, with the tdifs formulas Asurf Pseudo always goes to Maxiter. And only there, the issue occurs. With other formulas (Abox, Bulb, Menger etc.) this iteration cycle stays within limits in iteration count. And here limits are no problem. Anyhow, it would be nice, to have this fixed, because theese are ideal, to create 3d meshes. Good luck!

taurus66 commented 2 years ago

If that helps:

  1. Without limits, but in maxiter mode the same thing happens.
  2. mesh export is not affected. With the right custom limits, you get marvellous meshes.
buddhi1980 commented 2 years ago

Fixed in commit https://github.com/buddhi1980/mandelbulber2/commit/511bbc1251f792c95c5a744f4388026af4842666