SPPM renderer (CPU-only)

Discussion related to the implementation of new features & algorithms to the Core Engine.

Moderators: jromang, tomb, zcott, coordinators

Re: SPPM renderer (CPU-only)

Postby binarycortex » Wed May 04, 2011 9:54 am

Rom1 wrote:film.AddSampleCount(float(film.GetXPixelCount()*film.GetYPixelCount()));

in line 554 of hitpoints.cpp (just after Film &film(*scene.camera->film);)

I had something similar to this part already...
Rom1 wrote:and I stop the rendering by adding

if (scene.camera->film->enoughSamplesPerPixel)
{
renderer->Terminate();
}

in line 608 of sppmrenderer.cpp (just after hitPoints->IncPhotonPass();)

But this is the part i was missing.
Competition Coordinator.
Current Competition: Math is Beautiful / Abstract Wallpaper

Member of the first official jeanphi-fan club
User avatar
binarycortex
Developer
 
Posts: 1501
Joined: Fri Feb 22, 2008 10:44 pm

Re: SPPM renderer (CPU-only)

Postby binarycortex » Wed May 04, 2011 10:58 am

Dade wrote:
J the Ninja wrote:Idenctical scene, 3 passes each. Lowering startradius to 0.5 or so prevents the grid from being smudged out, so perhaps this is how it's supposed to work?


This is a consequence of using the BSDF of the photon hit point and not the eye path hit point. This was introduced and required by the latest patch, however as you have observed, it is noticeable only with very large start radius.

Don't forget that the initial radius is defined by an heuristic and it can indeed pick up a quite wrong value.

Dade, is that the reason for the outlining on the luxball ring and the base in this image?
sppm_outline.png
startradius 2.0, Alpha 0.7, 1mil P/pass

I noticed that when I start with an insanely small startradius this does not happen.
sppm_outline_2.png
startradius 0.1, Alpha 0.9, 1mil P/pass
Competition Coordinator.
Current Competition: Math is Beautiful / Abstract Wallpaper

Member of the first official jeanphi-fan club
User avatar
binarycortex
Developer
 
Posts: 1501
Joined: Fri Feb 22, 2008 10:44 pm

Re: SPPM renderer (CPU-only)

Postby Dade » Wed May 04, 2011 11:32 am

binarycortex wrote:Dade, is that the reason for the outlining on the luxball ring and the base in this image?


Yup, this was avoided by a normal check between hit point normal and photon hit point normal in previous version but I can restore that check. It will help to avoid case where the BSDF of the photon hit point has a normal too different from the one of eye path hit point.
User avatar
Dade
Developer
 
Posts: 4795
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: SPPM renderer (CPU-only)

Postby J the Ninja » Wed May 04, 2011 3:58 pm

Dade, last night in IRC BinaryCortex and I were messing around a bit with the eye pass sampler, and found the 20%+ speedup he reported with hilbert does indeed work with linear and tile as well. Wouldn't linear avoid the problem of "one tile is harder than the others" you mentioned with hilbert? Also, when used with low-discrepancy sampler for the classic renderer, the threads work on different rays in the same block, rather than on different blocks. I assume this is different for SPPM?
-Jason

Material DB Admin
User avatar
J the Ninja
Developer
 
Posts: 2207
Joined: Wed May 19, 2010 9:54 pm
Location: Portland, USA

Re: SPPM renderer (CPU-only)

Postby Dade » Thu May 05, 2011 4:14 am

J the Ninja wrote:Dade, last night in IRC BinaryCortex and I were messing around a bit with the eye pass sampler, and found the 20%+ speedup he reported with hilbert does indeed work with linear and tile as well. Wouldn't linear avoid the problem of "one tile is harder than the others" you mentioned with hilbert? Also, when used with low-discrepancy sampler for the classic renderer, the threads work on different rays in the same block, rather than on different blocks. I assume this is different for SPPM?


"Tile" would suffer of the same problem because a continuous group of adjacent pixels (i.e. a group of adjacent tiles) are assigned to the same thread. But the easy fix to this problem is just to give to the user the freedom to choose the pixelsampler to use.
User avatar
Dade
Developer
 
Posts: 4795
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: SPPM renderer (CPU-only)

Postby binarycortex » Thu May 05, 2011 10:02 am

Dade wrote:
J the Ninja wrote:Dade, last night in IRC BinaryCortex and I were messing around a bit with the eye pass sampler, and found the 20%+ speedup he reported with hilbert does indeed work with linear and tile as well. Wouldn't linear avoid the problem of "one tile is harder than the others" you mentioned with hilbert? Also, when used with low-discrepancy sampler for the classic renderer, the threads work on different rays in the same block, rather than on different blocks. I assume this is different for SPPM?


"Tile" would suffer of the same problem because a continuous group of adjacent pixels (i.e. a group of adjacent tiles) are assigned to the same thread. But the easy fix to this problem is just to give to the user the freedom to choose the pixelsampler to use.

I was working on this, but it wasn't going all that well since I'm new to c++. Perhaps it's time to try again.

I did however get halttime and haltspp to work. I am using pass count for haltspp. Are you ok with me committing this Dade?
Competition Coordinator.
Current Competition: Math is Beautiful / Abstract Wallpaper

Member of the first official jeanphi-fan club
User avatar
binarycortex
Developer
 
Posts: 1501
Joined: Fri Feb 22, 2008 10:44 pm

Re: SPPM renderer (CPU-only)

Postby Dade » Fri May 06, 2011 2:31 am

binarycortex wrote:I did however get halttime and haltspp to work. I am using pass count for haltspp. Are you ok with me committing this Dade?


As long as we stay in the experimental branch, we can test/try/commit whatever we want.
User avatar
Dade
Developer
 
Posts: 4795
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: SPPM renderer (CPU-only)

Postby J the Ninja » Fri May 06, 2011 2:39 am

Dade wrote:
binarycortex wrote:I did however get halttime and haltspp to work. I am using pass count for haltspp. Are you ok with me committing this Dade?


As long as we stay in the experimental branch, we can test/try/commit whatever we want.


Great, because he implemented user-selectable pixelsamplers while you were asleep. :D
-Jason

Material DB Admin
User avatar
J the Ninja
Developer
 
Posts: 2207
Joined: Wed May 19, 2010 9:54 pm
Location: Portland, USA

Re: SPPM renderer (CPU-only)

Postby SATtva » Fri May 06, 2011 10:07 am

Dade never sleeps! When you (and I and everyone else) sleep he's planning for world domination! :twisted:

funny-pictures-your-cat-plans-world-domination.jpg
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 5487
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: SPPM renderer (CPU-only)

Postby Dade » Fri May 06, 2011 10:47 am

SATtva wrote:Dade never sleeps! When you (and I and everyone else) sleep he's planning for world domination! :twisted:


MOAR CATZ !
User avatar
Dade
Developer
 
Posts: 4795
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

PreviousNext

Return to Architecture & Design

Who is online

Users browsing this forum: xsl and 2 guests