Title: mmm, chocolate Post by: Qythyx on November 23, 2009, 01:42:46 PM I've finally got my renderer working so I wanted to share and discuss ideas.
First, you can see all of the following in their full 4x X 4k size at http://mager.smugmug.com/Art/Mandelbulb (http://mager.smugmug.com/Art/Mandelbulb). Here're are few examples: 6,7, and 8 iterations: (http://mager.smugmug.com/Art/Mandelbulb/full-6-4kx4k/721591136_LAemr-S.jpg) (http://mager.smugmug.com/Art/Mandelbulb/full-7-4kx4k/721591162_mfnKS-S.jpg) (http://mager.smugmug.com/Art/Mandelbulb/full-8-4kx4k/721591179_5Qd9n-S.jpg) Some analysis of my program shows a lot of time in the function that calculates the {x, y, z} ^ 8. I'm still using a pretty straight forward trig version, because the algebraic versions I've seen don't work for me. One problem is that they all seem to have a division such that the denominator can by zero and therefore cause problems. Does anyone have an algebraic version working? For reference, my function is below (in C#). Code: private static void VectorToThe8thTrig2(ref double x, ref double y, ref double z) Title: Re: mmm, chocolate Post by: fractalrebel on November 23, 2009, 05:44:47 PM Some analysis of my program shows a lot of time in the function that calculates the {x, y, z} ^ 8. I'm still using a pretty straight forward trig version, because the algebraic versions I've seen don't work for me. One problem is that they all seem to have a division such that the denominator can by zero and therefore cause problems. I add Title: Re: mmm, chocolate Post by: Qythyx on November 25, 2009, 01:33:17 AM Fractalrebel, thanks for the tip. Doing that now works with the algebraic version, which is somewhat faster than the trig version. Here's an angled view of the bulb at 6 iterations. The 4k version is at http://mager.smugmug.com/Art/Mandelbulb (http://mager.smugmug.com/Art/Mandelbulb). (http://mager.smugmug.com/Art/Mandelbulb/full-angle-6-4kx4k/723040970_2fHb2-S.jpg) I'm now working on optimizing my ray marching. My basic algorithm now is as follows.
What I want to try is to increase my ray marching step size by taking advantage of the magnitude of the of the mandelbulb formula instead of just looking at the inside/outside binary result. Here's what I'm thinking.
Has anyone tried anything like this? I'm worried it could miss some hits. I'm also not sure how much of a speed up it'll provide. |