Fragmentarium FAQ

Here is a small collection of questions, I’ve have been asked from time to time about Fragmentarium.

Why does Fragmentarium crash?

The most common cause for this is, that a drawing operation takes too long to complete. On Windows, there is a two seconds maximum time limit on jobs executing on the GPU. After that, a GPU watchdog timer will kill the graphics driver and restore it (resulting in unresponsive, possible black, display for 5-10 seconds). The host process (here Fragmentarium) will also be shut down by Windows.

If this happens, you will get errors like this:

Try lowering the number of ray steps, the number of iterations or use the preview feature. Notice that for high-resolution renders, the time limit is for each tile, so it is still possible to do high resolution images.

Another solution is to change the watchdog timer behaviour via the TDR Registry Keys:

The TDR registry keys were not defined in my registry, but I added a

and a

key to

which sets a 30 second window for GPU calculations. You have to restart Windows to apply these settings. Be advised that changing these settings may render your system completely unresponsive if the GPU crashes.

Why does Fragmentarium not work on my GPU?

Even though GLSL is a well-defined standard, the are differences between different vendor implementations and different drivers. The computers I have use have Nvidia cards, so Fragmentarium is most tested on Nvidia’s platform.

Typical problems:

The ATI compiler is more strict about casting. For instance, adding an integer to a float results in an error, and not in a warning:

The ATI compiler also seems to suffer from some loop optimization problems: some of the fractals in Fragmentarium does not work on my ATI card, if the number of iterations is not locked (or hard-coded in the fragment code). Inserting a condition into the loop also solves the problem.

The Intel GPU compiler also has some issues: for instance, some operations on literal constants results in errors:

I get weird errors about disabled widgets?

If you see warnings like:

it does not indicate a problem. For instance, the warning above appears when the EnableFloor checkbox is locked and disabled. In this case, the GLSL will optimize the floor code away, and the FloorNormal uniform variable will no longer be part of the compiled program – hence the warning. These warnings can be safely ignored.

Why does your Fragmentarium images look much nicer than the ones I get in Fragmentarium?

The images I post are always rendered at a higher resolution using the High Resolution Render option. I then downscale the images to a lower resolution. This reduces alias and rendering artifacts. Use a painting program with a proper downscaling filter – I use Paint.NET which seems to work okay.

Before rendering in hi-res, use the Tile Preview to zoom in, and adjust the details level and number of ray steps, so the image looks okay in the Tile Preview resolution.

Why is Fragmentarium slower than BoxPlorer/…?

The default ray tracer in Fragmentarium has grown somewhat complex. It is possible to gain speed by locking variables, but this is somewhat tedious. Another solution is to change to another raytracer, e.g. change

to either

(a faster version of the ones above, which will remember all settings)


(Tom Beddards raytracer, which uses a set of different parameters)

Can I use double precision in my shaders?

Most modern graphics cards support double precision numbers in hardware, so in principle, yes, if your card supports it. In practice, it is much more difficult:

First, the Fragmentarium presets and sliders (including camera settings), will only transfer data (uniforms) to the GPU as single precision floats. This is not the biggest problem, since you might only need double precision for the numbers that accumulate errors. The Qt OpenGL wrappers I use doesn’t support double types, but it would be possible to work around this if needed.

Second, while newer GLSL versions do support double precision numbers (through types such as double, dvec3, dmat3), not all of the built-in functions support them. In particular, there are no trigonometric or exponential functions. So no cos(double), exp(double), etc. The available functions are described here.

Third, it might be slow: When Nvidia designed their Fermi architecture, used in their recent graphic cards, they built it, so that is should be able to process double precision operations with half the speed of single precision operations (which is optimal given the double size of the numbers). However, they decided that their consumer branch (the Nvidia cards) should be artificially limited to run double precision calculations at 1/8 the speed of single precision numbers. Their Tesla line of graphics card (which shares architecture with the Geforce branch), is not artifically throttled and will run double precision at half the speed of single precision. As for the AMD/ATI cards, I do not think they have similar limitations, but I’m not sure about this.

If you really still want to try, you must insert this command at the top of the script:

(Or use a #version command, but this will like cause problems with most of the existing examples).

Finally, what about emulating double precision numbers, instead of using the hardware versions? While this sounds very slow, it is probably not much slower than the throttled implementation. The downside is, the GLSL does not support operator overloading: there is no syntactically nice way to implement such functionality: instead of just changing your data types, you must convert all code from e.g.


If you are still interested, here is a great introduction to emulating doubles in GLSL.

How do I report errors, so that it is easiest for you to correct them?

(Well, actually nobody asks this questions)

If you find an error, please report the following:
– Operating system, and the graphics card you are using
– The version of Fragmentarium, and whether you built it yourself
– A reproducible description of the steps that caused the error (if possible).

You may mail errors to me at mikael (at)

18 thoughts on “Fragmentarium FAQ

  1. Sorry, I think I might have posted this to the wrong blog entry earlier.

    I’ve just stumbled upon Fragmentarium (via LibreGraphicsWorld), and as a lover of the old fractal apps such as Apophysis and Tierazon, I had to investigate. From what I can tell (by reading FAQ) one needs to know some kind of code to create the images (such as samples on Flickr). Is that the case, or is there a gui?

    Thanks for your help :-)

  2. Hi. Now I just tried Fragmentarium in my laptop and I think that is a great great work.
    Congratulations. I haven’t time to read more in your blog but I would like to know if it is possible to export the models as 3D format files.
    Congratulations again. ;)

  3. Thanks Mikael,
    I decided to give it a try. But after extracting files, I got an error message:
    “Windows found that this file is potentially harmful. To help protect your computer, Windows has blocked access to this file. Name: Fragmentarium.exe”. I did scan for malware, before extracting, all scans clean. So I can’t open it. I don’t know how to “Build”, even with instructions. I’m on Windows 7, 64-bit.

    Is there any way I can bypass whatever Windows has found, or convince Windows that it’s safe? I think I know how to access error logs, so maybe there will be some info there? Hhm, well nothing that appears to be associated with me trying to run Fragmentarium. Although there are a bunch of logs there, that I don’t know what they’re for.

    Well, if there’s any way around this problem, I’d still like to look at the program, in case I can actually operate it, and create some nice graphics. Any ideas?

    Thanks again :-)

  4. Hi Brynn,

    I think you can right-click the zip-file, choose properties, and click the ‘Unblock’ button there.

    What worries me, is that I don’t get the same kind of warning messages (even on Win7/64). If someone knows what triggers this, please let me know.

  5. Hey, that worked. I have Fragmentarium open and running, and now I have the challenge of learning how to use it! Off I go….:-)

    Thanks Mikael

  6. Hi again,
    Ok, well you probably already guessed this, but whatever are the coolest parts of this program are out of reach for me. I’ve been able to move the Mandlebulb around, zoom in and out, and change a few parameters. But without any tutorials, written for ordinary people, or help files, or the like, it’s probably going to be too difficult for me to enjoy very much.

    I have a lot of what are probably simple questions, which probably you don’t have time to answer. So I’m wondering if you have a forum somewhere? Or perhaps someone has written a tutorial somewhere? (I’ve read the Usage page, but it’s 95% over my head :-( ) Or are these things still off in the future somewhere?

    But I will continue to play around with it. It looks like I can find other things besides the Mandlebulb to explore. And there is a lot of text which I can try to decipher, which might teach me more.

    Thanks for making this program. I hope I can manage to learn a lot more :-)

    All best.

  7. Hmm. There’s probably more to this than I get at present. I downloaded the Mac Build and ran it only to get “Failed to compile script”. I’m probably missing something… OSX 10.7.5 on a 2 core duo.

    Any offer of direction would be appreciated.

  8. Thanks so much for this Michael(and the others for the fragments). I have it running very well on win7/64/quadcorei7 3770k 32gbram/nvidia gt640 .. I do get 2 second timeout crashes but usually when I am asking it to switch too quickly between sliders, If anyone (like myself) does not want to or doesn’t understand how to adjust your registry just make sure and save your process as often as possible that way you will not lose anything.

  9. Hello,
    I just start with Fragmentarium. When I try to include fragments it’s written :”Not a runnable fragment”. why does it happen?

  10. @Anna – When you open a Fragment which is intended to be included by other fragments (such as the raytracers), this is the error message you will get. To include other fragments, you should use the ‘#include “DE-raytracer.frag”‘ command.

  11. i’ve been playing with reaction-diffusion, every time i attempt to render to files the zoom factor on the camera resets and i appear to be zoomed in too close to make an image, the parameters for the camera don’t have locks on in this tab, can i lock the zoom in some other way?
    love it by the way.

Leave a Reply

Your email address will not be published. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">