Kalles Fraktaler
|
|
« on: March 28, 2014, 12:14:12 PM » |
|
I am playing a little with Kalles Fraktaler and trying to implement Supersampling. Supersampling means, according to wikipedia, taking the average of several points in each pixel. http://en.wikipedia.org/wiki/Supersampling - I have tried the "Grid algorithm". However the result isn't improving!?! I have already implemented Multisampling, which, according to wikipedia, means render a bigger image in memory and stretching it smaller, and this gives a very good result. http://en.wikipedia.org/wiki/Multisample_anti-aliasingEdges are smoothed and structures are revealed in areas that are noisy when rendered in the same size as displayed. My question: Is it a known fact that supersampling does not improve Mandelbrot rendering? Or am I simply doing it wrong?? Attached image shows - 1. no antialias, 2. supersampling 4x4, 3. multisampling 4x4
|
|
|
Logged
|
|
|
|
cKleinhuis
|
|
« Reply #1 on: March 28, 2014, 03:01:20 PM » |
|
as far as i understand it your supersampling algorithm is wrong various strategies exist for supersampling, either use a random sub-pixel or divide the pixel in a regular grid manner, and i think supersampling with a regular grid should provide *nearly* exact same result as multisampling a 4 times bigger pictue
|
|
|
Logged
|
---
divide and conquer - iterate and rule - chaos is No random!
|
|
|
laser blaster
Iterator
Posts: 178
|
|
« Reply #2 on: March 28, 2014, 05:04:30 PM » |
|
Make sure that you iterate and color each supersampled point seperately, and then average them at the end. If you do that, it should work.
|
|
|
Logged
|
|
|
|
Kalles Fraktaler
|
|
« Reply #3 on: March 28, 2014, 07:49:39 PM » |
|
Make sure that you iterate and color each supersampled point seperately, and then average them at the end. If you do that, it should work.
Yeah, and that is just what the problem is! Because I want to have an average of the iteration count (and smooth coefficient) on each pixel so that I can make color cycling animations. But it seems not possible... And since you wrote what you wrote, I assume you have also encountered this?
|
|
|
Logged
|
|
|
|
cKleinhuis
|
|
« Reply #4 on: March 28, 2014, 07:52:24 PM » |
|
check your averaging method, it can happen that you do something like value=(value+newValue)/2 assuming to create a 50 percent average over all, but what this method actually does is weighting just the last added 50% so, the aliasing effect might be too small because last pixel is taking 50%
|
|
« Last Edit: March 28, 2014, 07:58:44 PM by cKleinhuis, Reason: corrected formula »
|
Logged
|
---
divide and conquer - iterate and rule - chaos is No random!
|
|
|
Syntopia
|
|
« Reply #5 on: March 28, 2014, 08:05:45 PM » |
|
I have already implemented Multisampling, which, according to wikipedia, means render a bigger image in memory and stretching it smaller, and this gives a very good result. http://en.wikipedia.org/wiki/Multisample_anti-aliasingEdges are smoothed and structures are revealed in areas that are noisy when rendered in the same size as displayed. Multisampling is not the same as rendering a bigger image and downscaling. Multisampling (MSAA) is a OpenGL technique, that works by only sampling the edges of polygons at higher resolutions. You cannot do MSAA on a fractal, since there are no polygons. My guess is that you are doing Full-Screen Anti-Alias (FSAA) - that is rendering the scene at a higher resolution and downscaling it. An alternative is to just sample more times per pixel - which results in quite similar results if using the same number of pixels as in FSAA - however you can improve the sampling pattern by using jittering or stratifying the samples. But you should supersample the final color, not the iteration count.
|
|
|
Logged
|
|
|
|
Kalles Fraktaler
|
|
« Reply #6 on: March 28, 2014, 08:40:21 PM » |
|
check your averaging method, it can happen that you do something like value=(value+newValue)/2 assuming to create a 50 percent average over all, but what this method actually does is weighting just the last added 50% so, the aliasing effect might be too small because last pixel is taking 50% No, I sum the iterations and divide the value at the end. Strangely enough, it gives a good anti-alias effect when the iteration division has an significant value, but without iteration division the result is sometimes worse than when one sample per pixels is used. Multisampling is not the same as rendering a bigger image and downscaling. Multisampling (MSAA) is a OpenGL technique, that works by only sampling the edges of polygons at higher resolutions. You cannot do MSAA on a fractal, since there are no polygons. My guess is that you are doing Full-Screen Anti-Alias (FSAA) - that is rendering the scene at a higher resolution and downscaling it.
An alternative is to just sample more times per pixel - which results in quite similar results if using the same number of pixels as in FSAA - however you can improve the sampling pattern by using jittering or stratifying the samples. But you should supersample the final color, not the iteration count.
Sorry I am not quite familiar with the terminology. Anyway, also you write that I must super-sample the final color (i.e. not the iteration count value), and that is just what I don't want, since I want to be able to do color cycling! Render in higher resolution works very well, but it requires a lot of memory and therefore sampling several times in the same pixels is faster in practice. But I take your replies as this is not possible so that I can thankfully discard this method Thanks a lot!
|
|
|
Logged
|
|
|
|
lycium
|
|
« Reply #7 on: March 28, 2014, 09:05:42 PM » |
|
You're really not going to do anti-aliasing just so that palette cycling works?
I sometimes make jokes about fractal rendering tech generally being stuck in the 80s, and such a situation is concrete proof!
|
|
|
Logged
|
|
|
|
Sockratease
|
|
« Reply #8 on: March 28, 2014, 09:38:42 PM » |
|
You're really not going to do anti-aliasing just so that palette cycling works?
I sometimes make jokes about fractal rendering tech generally being stuck in the 80s, and such a situation is concrete proof!
So... How would you suggest bringing it into the 21st Century? If you're going to make such a critical statement it's only fair to offer a better solution at the same time, right?
|
|
|
Logged
|
Life is complex - It has real and imaginary components. The All New Fractal Forums is now in Public Beta Testing! Visit FractalForums.org and check it out!
|
|
|
lycium
|
|
« Reply #9 on: March 28, 2014, 10:23:26 PM » |
|
Lack of AA, especially for the sake of palette cycling, is very very 80s fractal rendering. Is deeper zooming really the essence of modernity for you?
Several people in this thread have already suggested how to do better rendering (since, you know, we have more than 256 colours these days) but the 80s style aliased palette cycling is somehow more appealing... is it really that difficult to see how one might think it's a bit oldskool?
Edit: Here's a concrete example: Frax. Yes, it doesn't zoom to 1e234603760376, but it does has the crucial advantage of making images that are actually kind of new and interesting, nice to look at. So you're really telling me, you prefer the nasty crunchy pixels of the same old repeating structure at some unholy depth, to new and interesting ways of visualising the Mandelbrot set, adding effects etc? Am I really alone in this crazy idea that the obsession with deep zooming at the expense of any kind of artistic creativity is ridiculous? Has anyone even seen anything genuinely new in the M-set in the last 30 years?
|
|
« Last Edit: March 28, 2014, 10:39:20 PM by lycium »
|
Logged
|
|
|
|
lycium
|
|
« Reply #10 on: March 28, 2014, 10:26:51 PM » |
|
If only we could zoom to 1e100000000000000000000000, then fractal art would *really* be amazing and modern, and no new programs are needed for at least another hundred years!
|
|
|
Logged
|
|
|
|
laser blaster
Iterator
Posts: 178
|
|
« Reply #11 on: March 28, 2014, 11:16:43 PM » |
|
Lycium, I think you're misunderstanding him a bit. I think he wants to create color cycling animations out of still renders, which means rendering out the raw iteration depth and applying color as a post-process, which won't work if the samples have already been averaged together. Thus the need to render in a higher resolution and downsample.
Also, I can understand if you're bored of pictures of the good old M-set with simple coloring methods, but there's plenty of people out there who experiment with interesting new formulas and colorings.
|
|
|
Logged
|
|
|
|
Kalles Fraktaler
|
|
« Reply #12 on: March 28, 2014, 11:19:17 PM » |
|
No I agree with you. Modern programs should be able to have more than 256 colors. With perturbation we have also seen amazing views not so deep but in high density areas, passing close to several, up to 8!, minibrots for example. That's indeed news since the last 30 years!!
Have you ever consider adding perturbation to your frax program, and combine it with your effects?
Anyway, my initial question was if it is feasible to super sample the iteration value and the answer is no, which is according to what I found out. I am thankful of the responses I got on that question. Your opinions are interesting but a side track. Color cycling is not possible at all if you render the final colors of each pixel, regardless if you use 80-stylish 256 colors or, as I do, fractional cycling on palettes with tens of thousands of colors resulting in hundreds of thousands of colors... But I may indeed prefer other things than you do, we may have different preferences you know.
|
|
|
Logged
|
|
|
|
lycium
|
|
« Reply #13 on: March 29, 2014, 12:02:08 AM » |
|
Lycium, I think you're misunderstanding him a bit. I think he wants to create color cycling animations out of still renders, which means rendering out the raw iteration depth and applying color as a post-process, which won't work if the samples have already been averaged together. I understood that just fine Thus the need to render in a higher resolution and downsample. Ah but this isn't correct, because: AA(colouring_function(iteration)) != colouring_function(AA(iteration)) Also, I can understand if you're bored of pictures of the good old M-set with simple coloring methods, but there's plenty of people out there who experiment with interesting new formulas and colorings. On the contrary, this is precisely the point I was making about Frax
|
|
|
Logged
|
|
|
|
lycium
|
|
« Reply #14 on: March 29, 2014, 12:05:13 AM » |
|
No I agree with you. Modern programs should be able to have more than 256 colors. With perturbation we have also seen amazing views not so deep but in high density areas, passing close to several, up to 8!, minibrots for example. That's indeed news since the last 30 years!! I think you deliberately dodged my question about whether anything genuinely new has been seen in the M-set in the last 30 years. Previously I made what I think is a good analogy: deeper zooming into the M-set, although never repeating, introduces about as much exciting novelty as never-repeating digits of pi. Have you ever consider adding perturbation to your frax program, and combine it with your effects? Frax is not my program, and since I value reliable rendering I wouldn't use perturbation methods even if I did want to make the 9769343904750760237563th M-set renderer that can zoom 236034634564643x deeper than any previous renderer. To me deep zooming is the most artistically shallow aspect of fractals. There are SO many amazing fractals waiting to be created, but humankind seems to be largely stuck on getting more minibrots onscreen (not even any more interestingly visualised than was done in the 80s) and comparing zoom exponents...
|
|
« Last Edit: March 29, 2014, 12:18:58 AM by lycium »
|
Logged
|
|
|
|
|