Logo by fractalwizz - Contribute your own Logo!

END OF AN ERA, FRACTALFORUMS.COM IS CONTINUED ON FRACTALFORUMS.ORG

it was a great time but no longer maintainable by c.Kleinhuis contact him for any data retrieval,
thanks and see you perhaps in 10 years again

this forum will stay online for reference
News: Visit us on facebook
 
*
Welcome, Guest. Please login or register. April 26, 2024, 07:52:49 PM


Login with username, password and session length


The All New FractalForums is now in Public Beta Testing! Visit FractalForums.org and check it out!


Pages: [1]   Go Down
  Print  
Share this topic on DiggShare this topic on FacebookShare this topic on GoogleShare this topic on RedditShare this topic on StumbleUponShare this topic on Twitter
Author Topic: HTML5 realtime mandelbrot explorer  (Read 4087 times)
0 Members and 1 Guest are viewing this topic.
khyperia
Guest
« on: May 20, 2012, 05:21:14 AM »

You need HTML5/webgl support to run the page, came standard on my machine/browser, so you should be good.

http://khyperia.com/projects/mandelbrot/

Drag the mouse to pan, and scroll to zoom. I heard rumors of firefox not supporting the mouse scroll event, but I don't know, didn't test it on firefox.

Made this as a "hello world" type webgl project in about 3 hours. Yeah, simple algorithm is simple, color is just the sin of iteration count over some Fibonacci numbers. The point is that its realtime, and in a browser, not looks cool.

And then I realized I called it "mandelbox" because I type in mandelbox a LOT more than mandelbrot. Fail.

Edit: Updated URL to reflect what's actually displayed, and added buttons for Firefox users.
« Last Edit: May 30, 2012, 12:25:18 AM by khyperia » Logged
panzerboy
Fractal Lover
**
Posts: 242


« Reply #1 on: May 20, 2012, 09:34:21 AM »

Cool.
The mousewheel zoom is a little slow for my preference.
I saved the link to my Harddrive and altered the onMouseWheel function to divide by 1000 rather than 10000
ie.

        function onMouseWheel(event) {
            var wheelData = event.wheelDelta;
            zoom *= Math.exp(-wheelData / 1000.0);
        }

I don't know much about Javascript and even less about WebGL.
Is the GPU doing the calculation through OpenGL?
The first script "shader-fs" would be the WebGL not javascript?
Logged
taurus
Fractal Supremo
*****
Posts: 1175



profile.php?id=1339106810 @taurus_arts_66
WWW
« Reply #2 on: May 20, 2012, 12:23:43 PM »


I heard rumors of firefox not supporting the mouse scroll event, but I don't know, didn't test it on firefox.


yepp, firefox doesn't scroll...
Logged

when life offers you a lemon, get yourself some salt and tequila!
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« Reply #3 on: May 20, 2012, 03:54:55 PM »

Lol too bad hat fireo dlol too bad that firefox doesnt support wheelie events but since it is just 2d ican live with it, well done anyways
Logged

---

divide and conquer - iterate and rule - chaos is No random!
khyperia
Guest
« Reply #4 on: May 20, 2012, 07:39:33 PM »

I don't know much about Javascript and even less about WebGL.
Is the GPU doing the calculation through OpenGL?
The first script "shader-fs" would be the WebGL not javascript?

Yeah, pretty sure its OpenGl, and yep, all calculations are done on the GPU, recalculating every single pixel in the frame 10 times a second. The shader-fs is the pixel/fragment shader, and shader-vs is the vertex shader. Oh, and WebStorm dosn't support webgl, so that's why theres no formatting in the shaders.
Logged
Pages: [1]   Go Down
  Print  
 
Jump to:  

Related Topics
Subject Started by Replies Views Last post
Mandelbrot Maps - A cross platform fractal explorer Fractal Programs mandelbrotmaps 4 7184 Last post March 20, 2012, 07:46:33 PM
by withad
Mandelbrot Maps: An open-source Mandelbrot/Julia explorer for Android Smartphones / Mobile Devices withad 0 10222 Last post March 20, 2012, 07:35:07 PM
by withad
Mandelbrot / Julia explorer, JavaScript / Canvas Programming asimes 4 3208 Last post August 18, 2013, 10:26:21 PM
by asimes
Jux 1.0 Julia/Mandelbrot explorer with lighting Announcements & News « 1 2 » xenodreambuie 22 11502 Last post September 04, 2015, 02:14:08 PM
by xenodreambuie
Juv v2.0 Julia/Mandelbrot explorer Announcements & News xenodreambuie 0 1947 Last post November 05, 2017, 11:19:28 PM
by xenodreambuie

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM
Page created in 0.296 seconds with 24 queries. (Pretty URLs adds 0.048s, 2q)