6 ms·
Show HN: FractalViewer: A JavaScript fractal explorer
- laser 10y agoThis is awesome :) The one feature request I have that would make navigating a lot less frustrating is for the zoom to go to where the cursor is located, instead of the center of the screen.
- valera_rozuvan 10y agoWill be implemented in version 2.0 of FractalViewer. See progress at https://github.com/valera-rozuvan/FractalViewer/issues/1 https://github.com/valera-rozuvan/FractalViewer/issues/1 .
- laser 10y agoGreat! :)
- laser 10y agoIs there a way to increase the max depth by just rendering the zoomed area, or is it unviable as the mathematics require calculating the entire object?
- elsurudo 10y agoLast time I implemented something like this was in uni about 10 years ago now, but I recall that not being the case – you should be able to render just the visible area, as (at least in the case of Mandelbrot) the data is independent.
- valera_rozuvan 10y agoDo you mean to render the same view (what you see), but at a higher resolution? So that, for example, you can print it out?
- laser 10y agoNo, I mean that at a certain level of zoom the fractal appears to stop being generated, and I end up just zooming into pixel blocks. For example, if you try to recreate https://www.youtube.com/watch?v=0jGaio87u3A https://www.youtube.com/watch?v=0jGaio87u3A you can only for for a bit before the fractal appears to stop generating.
- valera_rozuvan 10y agoIt's because currently FractalViewer is not designed to work around floating point precision limits in JavaScript. So, after zooming a bit, you hit the "pixelated wall". I plan to address this issue in future release of FractalViewer. See https://github.com/valera-rozuvan/FractalViewer/issues/10 https://github.com/valera-rozuvan/FractalViewer/issues/10 . More information on JS floating point numbers, their limitations, and ways to work around those limits - can be found in this informative article http://blog.chewxy.com/2014/02/24/what-every-javascript-developer-should-know-about-floating-point-numbers/ http://blog.chewxy.com/2014/02/24/what-every-javascript-deve... .
- johntiror 10y agoLove it! Nice job! Did you think about using a render technique like the maps one? (render smaller square intead of all the screen multiple times)
- valera_rozuvan 10y agoRight now FractalViewer is using a modified version of the Successive Refinement algorithm invented by Robert P. Munafo. See a description of the original algorithm http://mrob.com/pub/muency/successiverefinement.html http://mrob.com/pub/muency/successiverefinement.html . Version 2 of FractalViewer will use Web Workers (multipple threads) to render the image, so it will resemble "the maps one" (rendering multiple smaller squares at once). See progress on this at https://github.com/valera-rozuvan/FractalViewer/issues/3 https://github.com/valera-rozuvan/FractalViewer/issues/3 . By the way - maybe I got your question wrong. What do you mean by "a render technique like the maps one"? Can you point me to a resource where it is described?
- johntiror 10y agoYou got completely right! Version 2 answered my question, thanks!