Is it possible to declare a Global Variable such that its value persists across animation frames? This is necessary when one frame of the animation is dependent on some computational state information of the previous frame, behond what is stored in the Parameters.

For example, the fractals produced in diffusion models, where the pictorial fractal is a representation of a computational state which involves multiple data sets.

It is clear that UltraFractal has a very robust computational model, which provides an impressive amount of flexibility. However, I do not see a way to carry forward large amounts of state data, for example, computational data per point in the fractal coordinate space.

Any pointers or ideas on how to do this?

Is it possible to declare a Global Variable such that its value persists across animation frames? This is necessary when one frame of the animation is dependent on some computational state information of the previous frame, behond what is stored in the Parameters. For example, the fractals produced in diffusion models, where the pictorial fractal is a representation of a computational state which involves multiple data sets. It is clear that UltraFractal has a very robust computational model, which provides an impressive amount of flexibility. However, I do not see a way to carry forward large amounts of state data, for example, computational data per point in the fractal coordinate space. Any pointers or ideas on how to do this?
 
0
reply

Currently the global section is executed for every frame. It should be possible though for UF to determine whether it uses any parameters or location settings that are animated. But then the memory of the formula also needs to be saved and restored with the render job, so although this looks simple, it really isn't. I'll think about it though.

Currently the global section is executed for every frame. It should be possible though for UF to determine whether it uses any parameters or location settings that are animated. But then the memory of the formula also needs to be saved and restored with the render job, so although this looks simple, it really isn't. I'll think about it though.

Ultra Fractal author

 
0
reply

If I may offer some initial thoughts, keeping in mind that I do not know any of the internal details of UltraFractal's runtime system.

If the qualifier 'persistent' (or 'static)' was available for variable declarations, the compiler would be instructed to initialize those variables once, at the beginning of execution, prior to and outside of the Global section.

The Linker would then be instructed to position the persistent variables in a section of memory which would be treated as a persistent block. When computing animation frames, the persistent variables and their contents would be preserved in memory from one frame to the next.

It would be up to the application, in this case, the Transformations, the Fractal Formulas and the Colouring Algorithms, to keep track of what is stored in the Persistent Variables, and how and when to use and modify the data stored in them.

The motivation for this functionality is, as I see it, this: currently, the computational model of UF is powerful and elegant. The animation engine allows for the creation of sequential frames, with a very flexible mechanism to modify computational parameters. The result is very robust. However, the frames in the animation form a set of computational states which are connected via the computational threads of the parameters only. The limitation is that the parameters determine the computational states, but do not constitute them. To access anything in the previous computational state, that state would need to be re-created. Doing so is not only computationally expensive, but, in my opinion, would violate the design principles of UF's runtime computational model. Persistent Variables are a common (and efficient) solution to this limitation.

Thank you for considering this idea.

If I may offer some initial thoughts, keeping in mind that I do not know any of the internal details of UltraFractal's runtime system. If the qualifier 'persistent' (or 'static)' was available for variable declarations, the compiler would be instructed to initialize those variables once, at the beginning of execution, prior to and outside of the Global section. The Linker would then be instructed to position the persistent variables in a section of memory which would be treated as a persistent block. When computing animation frames, the persistent variables and their contents would be preserved in memory from one frame to the next. It would be up to the application, in this case, the Transformations, the Fractal Formulas and the Colouring Algorithms, to keep track of what is stored in the Persistent Variables, and how and when to use and modify the data stored in them. The motivation for this functionality is, as I see it, this: currently, the computational model of UF is powerful and elegant. The animation engine allows for the creation of sequential frames, with a very flexible mechanism to modify computational parameters. The result is very robust. However, the frames in the animation form a set of computational states which are connected via the computational threads of the parameters only. The limitation is that the parameters determine the computational states, but do not constitute them. To access anything in the previous computational state, that state would need to be re-created. Doing so is not only computationally expensive, but, in my opinion, would violate the design principles of UF's runtime computational model. Persistent Variables are a common (and efficient) solution to this limitation. Thank you for considering this idea.
 
0
reply
128
views
2
replies
2
followers
live preview
Enter at least 10 characters.
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft