-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
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
WIP: Added anisotropic roughness to mainline #17391
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Conflicts: # src/materials/MeshPhysicalMaterial.js # src/renderers/WebGLRenderer.js # src/renderers/shaders/ShaderChunk/common.glsl.js # src/renderers/shaders/ShaderChunk/envmap_physical_pars_fragment.glsl.js # src/renderers/shaders/ShaderChunk/lights_fragment_begin.glsl.js # src/renderers/shaders/ShaderChunk/lights_fragment_maps.glsl.js # src/renderers/shaders/ShaderChunk/uv_pars_fragment.glsl.js # src/renderers/shaders/ShaderChunk/uv_pars_vertex.glsl.js # src/renderers/shaders/ShaderChunk/uv_vertex.glsl.js # src/renderers/webgl/WebGLProgram.js # src/renderers/webgl/WebGLPrograms.js
…t anisotropic roughness
# Conflicts: # examples/webgl_materials_envmaps_anisotropy.html
…latShading # Conflicts: # examples/jsm/nodes/materials/nodes/StandardNode.js # examples/webgl_materials_envmaps_anisotropy.html # src/renderers/shaders/ShaderLib/meshphysical_frag.glsl.js
…e material # Conflicts: # examples/jsm/nodes/accessors/ReflectNode.js
# Conflicts: # examples/jsm/nodes/materials/nodes/StandardNode.js
Signed-off-by: Daniel Sturk <danielsturk1@gmail.com>
DanielSturk
changed the title
Added anisotropic roughness to mainline
WIP: Added anisotropic roughness to mainline
Aug 30, 2019
Mainline anisotropy
mrdoob
reviewed
Aug 30, 2019
Mugen87
reviewed
Sep 2, 2019
Mugen87
reviewed
Sep 2, 2019
Mugen87
reviewed
Sep 2, 2019
Mugen87
reviewed
Sep 2, 2019
Mugen87
reviewed
Sep 2, 2019
Can you please add the new example to |
NodeMaterial Revision
# Conflicts: # src/renderers/shaders/ShaderChunk/common.glsl.js
Seems like this got stale. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is made with the intention of aligning three.js with the next-gen glTF model KhronosGroup/glTF#1442 and the Enterprise PBR #16977
The code was sourced from Google's Filament https://google.github.io/filament/Materials.html#materialmodels/litmodel/anisotropy
Likely before merging, the intention is to switch the parameterization from strength/direction to a 2d vector. The reasoning for this is that for interpolated rotation maps, there will be a discontinuity where the direction wraps around (360 -> 0 will not wrap naturally, it will interpolate backwards from 360 to 0). This is discussed in several places in the glTf thread KhronosGroup/glTF#1442 (comment)
In fact, this is visible in the screenshot
Another intended feature is to try to combine the anisotropy and sheen brdfs. For IBL this is easy (bent normal from anisotropy + sheen env DFG lookup). For direct lighting this is more complex.