Search found 4 matches

by AiSard
Sun Mar 24, 2019 9:45 pm
Forum: Amplify Shader Editor
Topic: Change Render Type during Runtime
Replies: 1
Views: 3717

Change Render Type during Runtime

Is it possible to change a shader's Render Type/Queue from Transparent/Transparent to Opaque/Geometry during runtime? By script or otherwise.

Trying to achieve a Depth of Field effect and found that Transparent objects don't play well with it as it doesn't have Depth Information. But manually ...
by AiSard
Thu Mar 21, 2019 7:46 pm
Forum: Amplify Shader Editor
Topic: Flat Shader according to World Position (Barycentric?)
Replies: 4
Views: 4060

Re: Flat Shader according to World Position (Barycentric?)

Not knowing the first thing about coding shaders, quickly dropped that avenue.

That said, found a way to access triangle centers. Posting for posterity's sake.

Calculated the center of each triangle in world space (made sure to unshare the vertices) and for each triangle corner assigning Mesh ...
by AiSard
Thu Mar 21, 2019 3:53 pm
Forum: Amplify Shader Editor
Topic: Flat Shader according to World Position (Barycentric?)
Replies: 4
Views: 4060

Re: Flat Shader according to World Position (Barycentric?)

Hmm, that is a shame :(

I shall try to bake the triangle center in to mesh.color instead (unshared vertices, identical value for all 3 corners).
Which I should be able to access via Vertex Color instead.

However, as the height is currently generated by the Noise Generator (Simplex2D) feeding in to ...
by AiSard
Wed Mar 20, 2019 8:33 pm
Forum: Amplify Shader Editor
Topic: Flat Shader according to World Position (Barycentric?)
Replies: 4
Views: 4060

Flat Shader according to World Position (Barycentric?)

Hi,

I am currently trying to do a flat shader (low poly) for procgen meshes (no UV mapping so far) where the colour changes according to the height in World Space.

So far I've referenced the Low Poly Water example to achieve the low poly effect.

But there doesn't seem to be an easy way to ...