[opensource-dev] Review Request: STORM-1823 - Replace current specular model with Normalized Blinn-Phong specularity

Geenz Spad geenz at geenzo.com
Sun Mar 25 15:36:38 PDT 2012



> On March 25, 2012, 2:56 p.m., Argent Stonecutter wrote:
> > Could we see some examples of SL scenes using the two models, particularly with avatars in them, because there have been a number of changes to the SL renderer over the years... and the main effect of increasing the "realism" of the renderer has been to throw the deficiencies of the SL avatar mesh into sharp relief. The current specular model was a deliberate compromise between the older even-toonier renderer and a more "realistic" model that made avatars look horrible.

Avatars are only ever effected if they're using attachments that make sure of the shiny attribute.

The diffuse shading on avatars remains unaffected.  I think the "compromise" you're thinking of is the environment map that typically gets applied in classic forward rendering, which was later re-added to the deferred renderer to mitigate content breakage that resulted when it was removed, which hasn't been changed with my modifications.

As I had mentioned previously, there are comparison pictures posted on the JIRA that everyone can see, and I would also very much appreciate it if people could post their own comparisons, and identify any in-world content breakage that relied on the previous model that was used.


- Geenz


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://codereview.secondlife.com/r/565/#review1191
-----------------------------------------------------------


On March 25, 2012, 2:07 p.m., Geenz Spad wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://codereview.secondlife.com/r/565/
> -----------------------------------------------------------
> 
> (Updated March 25, 2012, 2:07 p.m.)
> 
> 
> Review request for Viewer and David Parks.
> 
> 
> Description
> -------
> 
> For a while now, Second Life's deferred renderer has had a somewhat "toonish" looking specular model, as opposed to other platforms which try to go for more physically accurate looking models, such as blinn-phong and similar.
> 
> This feature changes the specular model to a technique called normalized blinn-phong. The specular model applies the usual blinn-phong term (assume NdotV to the power of n), multiplied by a normalization function of:
> ((n + 2) * (n + 4)) / (8 * PI * (powf(2, -n/2) + n))
> Where n is the specular exponent.
> 
> Gamma correction is also applied to the result to bring the visual results more in line with what you see in high end game engines such as Unreal Engine 3 and Frostbite 2, and stored in a lookup texture.
> 
> Test plan can be found in the JIRA.
> Repository can be found here: https://bitbucket.org/Geenz/viewer-nbp
> 
> 
> This addresses bug STORM-1823.
>     http://jira.secondlife.com/browse/STORM-1823
> 
> 
> Diffs
> -----
> 
>   indra/newview/app_settings/shaders/class1/deferred/softenLightF.glsl b32595c5170f92ac2dbab635955b1b86634f1475 
>   indra/newview/app_settings/shaders/class1/deferred/pointLightF.glsl b32595c5170f92ac2dbab635955b1b86634f1475 
>   indra/newview/app_settings/shaders/class1/deferred/multiPointLightF.glsl b32595c5170f92ac2dbab635955b1b86634f1475 
>   indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl b32595c5170f92ac2dbab635955b1b86634f1475 
>   indra/newview/llviewercontrol.cpp b32595c5170f92ac2dbab635955b1b86634f1475 
>   indra/newview/pipeline.cpp b32595c5170f92ac2dbab635955b1b86634f1475 
> 
> Diff: http://codereview.secondlife.com/r/565/diff/diff
> 
> 
> Testing
> -------
> 
> * Tested performance characteristics - both Normalized Blinn-Phong and the previous model seem to have the same performance
> * Checked the perceived "brightness" of the new highlights vs. the old ones - new ones seem much brighter at higher shiny values than the old ones, and seem much less "cartoonish" as such
> * Checked the impact on different bumpiness values at the test rig at Hippo Hollow - noticeable visual improvement across all objects (though low shiny seems to have a much more subtle light reflectance term - this is expected for normalized blinn-phong)
> * Tested different LUT resolutions - best looking seems to be 512x128 with seemingly no measurable decrease in performance
> 
> You can find the latest build here: http://automated-builds-secondlife-com.s3.amazonaws.com/hg/repo/oz_project-8/rev/251711/index.html
> 
> 
> Thanks,
> 
> Geenz Spad
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.secondlife.com/pipermail/opensource-dev/attachments/20120325/10dc95af/attachment.htm 


More information about the opensource-dev mailing list