Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new shading model to Filament for specularGlossiness. #1083

Merged
merged 2 commits into from
Apr 9, 2019

Conversation

prideout
Copy link
Contributor

@prideout prideout commented Apr 9, 2019

This adds a shading model based on KHR_materials_pbrSpecularGlossiness.
The corollary gltfio change will be in an upcoming PR.

This adds a shading model based on KHR_materials_pbrSpecularGlossiness.
The corollary gltfio change will be in an upcoming PR.
- Subsurface
- Cloth
- Unlit
- `lit` (or standard)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of changing the shading model names to the programmatic versions here, you should update the ### shadingModel section to add specularGlossiness to the list.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

This alternative lighting model exists to comply with legacy standards.

Similar to cloth, it encompasses all the parameters previously defined for the standard
lit mode except for _metallic_ and _reflectance_, and adds a _sheenColor_ parameter.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you update the ### Material fragment inputs section too? sheenColor is listed as cloth only. Also add a table to describe the parameter, like this:

       Parameter      |      Definition
---------------------:|:---------------------
**sheenColor**        | Specular tint to create two-tone specular fabrics (defaults to $\sqrt{baseColor}$)

       Property       |   Type   |            Range         |           Note
---------------------:|:--------:|:------------------------:|:-------------------------
**sheenColor**        | float3   |  [0..1]                  | Linear RGB

Except in a way that makes sense :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@prideout prideout merged commit 37cb924 into master Apr 9, 2019
@prideout prideout deleted the pr/specgloss3 branch April 9, 2019 20:22
Zefz pushed a commit to staaker/filament that referenced this pull request Apr 12, 2019
* Add new shading model to Filament for specularGlossiness.

This adds a shading model based on KHR_materials_pbrSpecularGlossiness.
The corollary gltfio change will be in an upcoming PR.

* Improve documentation for specular-glossiness
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants