NasimiAsl

ShaderBuilder alpha version

Recommended Posts

hi everybody

https://github.com/BabylonJS/Extensions/tree/master/ShaderBuilder

finally i create ( thanks @Deltakosh a lot  and @Temechon) BJS Shader Builder  And Now i complete Documentation it is easy

but in Alpha version we have

Solid  http://www.babylonjs-playground.com/#FT2RY#1

Back http://www.babylonjs-playground.com/#FT2RY#5

Transparency

Front

Wired

Light

Map  http://www.babylonjs-playground.com/#FT2RY#0

Reflect

ReflectMap

Multi   http://www.babylonjs-playground.com/#FT2RY#0

Reference http://www.babylonjs-playground.com/#FT2RY#5

Replace Red Yellow Green Blue Cyan Pink White Black http://www.babylonjs-playground.com/#FT2RY#5

Effect http://www.babylonjs-playground.com/#FT2RY#2

Event  http://www.babylonjs-playground.com/#FT2RY#0   http://www.babylonjs-playground.com/#FT2RY#1

Inline

Range http://www.babylonjs-playground.com/#FT2RY#3 http://www.babylonjs-playground.com/#FT2RY#4

NormalMap

SpecularMap

Vertex

in Beta version 

Shadow

PostProcess

ImportLight

Filters

 request all you have problem in material and challenge ShaderBuilder for make that :)

 

Share this post


Link to post
Share on other sites

looks like I forgot to paste my playground example . I think the only thing that forces you to press run again is the registerBeforeRender call. simply put it inside the onload, and it will actually work the first time - 

like this - http://www.babylonjs-playground.com/#FT2RY#16

Share this post


Link to post
Share on other sites

 http://www.babylonjs-playground.com/#FT2RY#38

http://www.babylonjs-playground.com/#FT2RY#39  with alpha

http://www.babylonjs-playground.com/#FT2RY#40 with back

is that your request?

 

new BABYLON.ShaderBuilder()

        .Range(
        BABYLON.Helper().InLine('discard;').Build(),  // material 1 : discard : hide all faces
        BABYLON.Helper().Solid({ r: 1. }).Build(),  // material 2 Color
        { start: 0., end: 0.,

direction: ' vec3(world * vec4(pos,1.)).y  ' });  // direction 
        
    sb.Setting.FragmentWorld  = true;  // for make Fragment World Matris


    ico.material = sb.Light({direction:'camera',normal:BABYLON.Normals.Flat,phonge:0.3,specular:3.}).BuildMaterial(scene);        
 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.