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

Rename: MeshSSSPhysicalNodeMaterial -> MeshSSSNodeMaterial #27506

Merged
merged 1 commit into from
Jan 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/jsm/nodes/materials/Materials.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ export { default as MeshLambertNodeMaterial } from './MeshLambertNodeMaterial.js
export { default as MeshPhongNodeMaterial } from './MeshPhongNodeMaterial.js';
export { default as MeshStandardNodeMaterial } from './MeshStandardNodeMaterial.js';
export { default as MeshPhysicalNodeMaterial } from './MeshPhysicalNodeMaterial.js';
export { default as MeshSSSPhysicalNodeMaterial } from './MeshSSSPhysicalNodeMaterial.js';
export { default as MeshSSSNodeMaterial } from './MeshSSSNodeMaterial.js';
export { default as PointsNodeMaterial } from './PointsNodeMaterial.js';
export { default as SpriteNodeMaterial } from './SpriteNodeMaterial.js';
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import PhysicalLightingModel from '../functions/PhysicalLightingModel.js';
import MeshPhysicalNodeMaterial from './MeshPhysicalNodeMaterial.js';
import { float, vec3 } from '../shadernode/ShaderNode.js';

class SSSPhysicalLightingModel extends PhysicalLightingModel {
class SSSLightingModel extends PhysicalLightingModel {

constructor( useClearcoat, useSheen, useIridescence, useSSS ) {

Expand Down Expand Up @@ -37,7 +37,7 @@ class SSSPhysicalLightingModel extends PhysicalLightingModel {

}

class MeshSSSPhysicalNodeMaterial extends MeshPhysicalNodeMaterial {
class MeshSSSNodeMaterial extends MeshPhysicalNodeMaterial {

constructor( parameters ) {

Expand All @@ -60,7 +60,7 @@ class MeshSSSPhysicalNodeMaterial extends MeshPhysicalNodeMaterial {

setupLightingModel( /*builder*/ ) {

return new SSSPhysicalLightingModel( this.useClearcoat, this.useSheen, this.useIridescence, this.useSSS );
return new SSSLightingModel( this.useClearcoat, this.useSheen, this.useIridescence, this.useSSS );

}

Expand All @@ -79,6 +79,6 @@ class MeshSSSPhysicalNodeMaterial extends MeshPhysicalNodeMaterial {

}

export default MeshSSSPhysicalNodeMaterial;
export default MeshSSSNodeMaterial;

addNodeMaterial( 'MeshSSSPhysicalNodeMaterial', MeshSSSPhysicalNodeMaterial );
addNodeMaterial( 'MeshSSSNodeMaterial', MeshSSSNodeMaterial );
2 changes: 1 addition & 1 deletion examples/webgpu_materials_sss.html
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
const thicknessTexture = loader.load( 'models/fbx/bunny_thickness.jpg' );
imgTexture.wrapS = imgTexture.wrapT = THREE.RepeatWrapping;

const material = new Nodes.MeshSSSPhysicalNodeMaterial();
const material = new Nodes.MeshSSSNodeMaterial();
material.color = new THREE.Color( 1.0, 0.2, 0.2 );
material.roughness = 0.3;
material.thicknessColorNode = Nodes.texture( thicknessTexture ).mul( Nodes.vec3( 0.5, 0.3, 0.0 ) );
Expand Down