Divide iteration

  • 2 Replies

0 Members and 1 Guest are viewing this topic.

Offline mdudley

  • *
  • Fractal Phenom
  • ****
  • Posts: 44
« on: September 17, 2018, 10:20:37 PM »
If I understand the math in the color setup box,  you have a set of colors in the palette, which repeat continuously.  Then you have a iteration divide constant, which divides the iteration count down before indexing the palette array.

That is the color selected will be

@color[int(($iteration/$divide_constant)%pallet_size)] -- (Perl code, % is the modulo operator)

What I don't understand is the significance of having a divisor that is less than one, like .1, or .01.  It seems that if you apply such a constant to the above formula you will get a different color for each consecutive number, but just in a different order than if you used 1.

What is the purpose of that? Or am I missing something?


Offline gerrit

  • *
  • 3f
  • ******
  • Posts: 1681
« Reply #1 on: September 17, 2018, 10:48:45 PM »
<1 is mainly useful for distance rendering to get enough color variation.

Offline Dinkydau

  • *
  • Fractal Furball
  • ***
  • Posts: 217
    • DeviantART gallery
« Reply #2 on: September 20, 2018, 10:06:39 PM »
If you use a gradient in which the color change is very gradual you can use a divisor less than 1 to make it change in color faster. Kalles Fraktaler achieves this by dividing the iteration count, while I think Mandel Machine and Fractal eXtreme do it by stretching or shrinking the gradient itself.

Welcome to Fractalforums - the next Iteration

Started by Fractalforums Team on Meet & Greet

13 Replies
Last post July 12, 2019, 02:51:24 PM
by Sabine62
iteration based color

Started by mclarekin on Code Snippets (fragments)

2 Replies
Last post February 24, 2019, 02:33:32 AM
by mclarekin
Generic operations for the start of each iteration

Started by FractalDave on Programming

2 Replies
Last post November 30, 2018, 04:02:01 PM
by FractalDave
Iteration count per zoom level

Started by mrmath on Fractal Mathematics And New Theories

0 Replies
Last post December 31, 2017, 08:15:31 PM
by mrmath
Voxels at certain iteration depth with OpenCL

Started by ouoertheo on Mandelbulber

3 Replies
Last post January 13, 2018, 06:54:48 PM
by zebastian