Node Material beta stage

You have some videos in the doc :slight_smile:

I think placing new nodes in the center of the screen would be great to solve my particular problem :ok_hand: (moving existing nodes works flawlessly). this could then some day be extended to a more intelligent version as dad72 suggested (if so desired).

Do you want to try to submit a PR?

I would love to (but not sure if I will have time the next few days though).

Besides, I found some strange behaviour concerning the (automatic?) reorganize feature.

If I go to

https://nme.babylonjs.com/#XDUFVU#19

and hit f5, my graph looks like this:

If i then go back a version to
https://nme.babylonjs.com/#XDUFVU#18
and then again to the latest one
https://nme.babylonjs.com/#XDUFVU#19

the correct layout is applied again:

Hahaha Yeah the auto layout is not perfect. If you add a few nodes it can change a lot the way it dispatches things

Finally got the time to get into this, really really cool Dave. I can’t wait to dig deeper, gonna try to convert some of my older shaders into this new system.

Are there any PBR examples?

Nope as we need some more complex nodes to achieve it so I hope to find time in 4.2

Im trying to work up a TBN matrix, will the mesh.tangent attribute always assumed to be populated or will I need to calculate it manually just to make sure?

BTW, a TBN3x3 node would be pretty cool to include in 4.2

        // Exclude known varyings
        this.variableNames["vTBN"] = 0;

Why, what does that mean? Do I have access to a TBN already?

UPDATE
Just some clarity really quick @Deltakosh, the viewProjection Matrix is the same as gl_ModelViewMatrix? If not what would be the equivalent?

Then my gl_NormalMatrix would be the transpose(inverse(viewProjection)?

Im trying to do this:

  Normal = normalize((gl_NormalMatrix * gl_Normal)).xyz;
  vec3 Tangent = -vec3(abs(gl_Normal.y) + abs(gl_Normal.z), abs(gl_Normal.x), 0);
  vec3 Binormal = cross(Tangent, gl_Normal);
  Tangent = normalize(gl_NormalMatrix * cross(Binormal, gl_Normal));
  Binormal = normalize(gl_NormalMatrix * Binormal);

hmmm actually its looking like its not possible yet, without more matrix manipulation nodes.

Aye we have noise now ^_^.

1 Like