You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a scene with a mix of StandardMeshNodeMaterial and custom NodeMaterial. I get an error message only when i set the scene.environment, If I use MeshBasicNodeMaterial instead of NodeMaterial it works.
// error when using NodeMaterialUncaught TypeError: properties.nodesisnotiterableatProxy.analyze(chunk-OPBR7TQE.js?v=ac4c42a7:4013:35)atProxy.build(chunk-OPBR7TQE.js?v=ac4c42a7:411:12)
Reproduction steps
Create a scene with an hdr set to scene.environment, add a mesh with a NodeMaterial into the scene.
Code
import{BackSide,Color,IcosahedronGeometry,Mesh}from'three'import{NodeMaterial,uniform,uv,mul,add,vec4,mix,sub,clamp}from'three/examples/jsm/nodes/Nodes.js'import{MeshBasicNodeMaterial}from'three/addons/nodes/Nodes'//...consttopColor=uniform(newColor(0x020f56))constbottomColor=uniform(newColor(0x41b883))constopacity=uniform(0)constUV=add(mul(sub(uv().y,.5),4),0)constskyColor=mix(bottomColor,topColor,clamp(UV,0.,1.))constmaterial=newNodeMaterial()// BUG : if NodeMaterial no problem except if scene.environment!=null, work with MeshBasicNodeMaterial.material.colorNode=vec4(skyColor,opacity)material.side=BackSidematerial.depthWrite=falsematerial.depthTest=truematerial.transparent=true
Live example
Is there a fiddle. with hdr used on latest ?
Screenshots
No response
Version
r166.1
Device
No response
Browser
No response
OS
No response
The text was updated successfully, but these errors were encountered:
Description
I have a scene with a mix of StandardMeshNodeMaterial and custom NodeMaterial. I get an error message only when i set the scene.environment, If I use MeshBasicNodeMaterial instead of NodeMaterial it works.
Reproduction steps
Create a scene with an hdr set to scene.environment, add a mesh with a NodeMaterial into the scene.
Code
Live example
Is there a fiddle. with hdr used on latest ?
Screenshots
No response
Version
r166.1
Device
No response
Browser
No response
OS
No response
The text was updated successfully, but these errors were encountered: