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

NodeMaterial: updates and revision #23872

Merged
merged 1 commit into from
Apr 11, 2022
Merged

NodeMaterial: updates and revision #23872

merged 1 commit into from
Apr 11, 2022

Conversation

sunag
Copy link
Collaborator

@sunag sunag commented Apr 9, 2022

Description

NodeMaterial & WebGPU

  • physicallyCorrectLights is default in WebGPURenderer
  • Split all BRDFs in individual files
  • ToneMappingNode support
    • use renderer.toneMappingNode = new Nodes.ToneMappingNode( ... )
  • add FogNode.mix()
  • add NodeMaterial.generateOutput() and revision to add IBL soon
  • add WebGPUNodeBuilder.getSamplerBias()
  • VarNode.op( ... ) support
  • add ReflectedLightNode
  • update examples

ShaderNode

  • ShaderNode( ... ) was deprecated, use ShaderNode.call( .. ) instead of to call a function
  • addTo( varNode, ... ) was deprecated, use varNode.add( ... ) instead of
  • add context, reflectedLight

NodePlayground

  • Update WebGPU and WebGL examples

This contribution is funded by Google via Igalia

@sunag sunag added this to the r140 milestone Apr 9, 2022

} );

const PhysicalLightingModel = new ShaderNode( ( inputs/*, builder*/ ) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

Can it be just const PhysicalLightingModel = RE_Direct_Physical?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

At this moment it make more sense but I will add others functions like RE_IndirectSpecular_Physical soon...

@sunag sunag merged commit a31c66e into mrdoob:dev Apr 11, 2022
@sunag sunag deleted the dev-pbr-1 branch April 11, 2022 01:46
@mrdoob
Copy link
Owner

mrdoob commented Apr 11, 2022

Thanks!

@mrdoob
Copy link
Owner

mrdoob commented Apr 11, 2022

  • use scene.toneMappingNode = new Nodes.ToneMappingNode( ... )

Hmm, do you think we should move renderer.toneMapping to scene.toneMapping? 🤔

@sunag
Copy link
Collaborator Author

sunag commented Apr 11, 2022

Hmm, do you think we should move renderer.toneMapping to scene.toneMapping? 🤔

No, no! I made a mistake in the description only.
https://github.com/sunag/three.js/blob/bbb7841dcfcb53e1657de737c18b3ff8c6fd649b/examples/webgpu_nodes_playground.html#L111

abernier pushed a commit to abernier/three.js that referenced this pull request Sep 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants