Questions tagged [unity-shader-graph]
Unity Shader Graph is a Unity tool that allows users to create shaders using a drag-and-drop graphical interface without writing any code.
112 questions
1
vote
0
answers
45
views
What is the best way to move a mask in a shader in a square path in Unity Shader Graph?
I would like to make the square move strictly along a square trajectory. The square will later be used to mask the main sprite.
How to achieve this result? How to move the square along the square's ...
0
votes
2
answers
194
views
Color local shader graph UVs for texture atlas
I'm going to use a texture atlas for my upcoming project, and am trying to find a way to create a color overlay for only a specific section of my texture.
Below what I'm trying to accomplish, only for ...
1
vote
0
answers
64
views
How to hide a Sprite unless it is illuminated by a Light 2D?
I want to have a sprite that is invisible when outside of light, and visible when inside of light.
I created a new Custom Lit Shader Graph in Unity 6 with the following setup:
I then created a player ...
1
vote
1
answer
693
views
How to add "Visual Effect" as an active target in a Unity 6 shader graph?
I've just started learning and getting into shader graphs in Unity and I was just watching some tutorials on Youtube and realized that in the video, when he created the shader graph, he could add &...
0
votes
0
answers
112
views
How to project textures on to the mesh and overlap them like in Let’s Play Pottery?
I want to learn how to project textures on to the mesh and overlap them like in Let’s Play Pottery. I have an idea for game. I created Models, 3d viewer but I can’t figure out how to implement texture ...
0
votes
1
answer
579
views
How to make this Triplanar Shader Graph follow object rotation
I have what is essentially a double triplanar shader. The first triplanar is a base rock texture, and the second triplanar is going to be an accent texture, such as grass, sand, etc, which is always ...
3
votes
1
answer
1k
views
If UV coordinate is Vector2, then why does UV node in shader graph output Vector4?
I'm new to shader, so please pardon my lack of knowledge. I am trying to understand what does UV node do in shader graph. I tried searching on google and in https://docs.unity3d.com/Packages/com.unity....
1
vote
1
answer
542
views
Unity shader to give thickness to flat plane
I have this hexagonal grate floor:
Which is a flat plane with the following shader:
The hex lattice created using the method by Andrew Hung. Albedo and metallic/smoothness shader are just simple ...
0
votes
0
answers
39
views
How can I sync the volume of an audiosource with how a material change alpha?
I am making a flickering light prefab, and have already made a shader and a material that make it turn on and off erratically.
I also want the light to emit a buzzing sound when it's turned on, but I ...
3
votes
1
answer
3k
views
How can I map a texture around a sphere without a seam?
I am attempting to wrap a texture around a sphere without any warping using Unity's Shader Graph. I have been following this StackExchange answer, and have semi-successfully converted their shader ...
0
votes
1
answer
256
views
How does vector raised to the power of another vector work?
I was watching this tutorial and at timestamp 3:03 he did this:
This blows my mind because I didn't expect that to actually work, how the heck does that work ???? For example, if I have vector (2, 3, ...
0
votes
1
answer
759
views
Make night sky with moon
I want to make skybox with moon (texture 2d) with shader graph and be able to modify moon radius.
Moon Texture 2d :
0
votes
1
answer
680
views
Cubemap rotation
I have a skybox with stars cubemap
So, how can I rotate stars cubemap on Z axis using "Rotate About Axis"?
0
votes
1
answer
524
views
Make moon using cubemap in shadergraph
I'm trying to make moon with a cubemap texture in shadergraph.
I made it, but the texture is incorrect.
I'm using a cubemap from NASA as a texture and it works, but it's bigger than moon shape and ...
1
vote
2
answers
3k
views
Sprite Shape & URP Custom 2D Lighting Shader
I've been losing my mind over this for a couple of days now, and can't find any concrete information about it.
I am trying to write a custom shader (shader graph to be specific) to light sprite shape ...
2
votes
0
answers
293
views
How to get wave height of a gerstner wave made in shader graph?
I have followed a gerstner wave shader graph tutorial. (YouTube Tutorial)
I am now trying to implement buoyancy by attaching the following script to a gameobject. (YouTube Tutorial)
...
0
votes
4
answers
5k
views
How can I rotate cubemap in shadergraph?
I know how to rotate cube map with legacy surface shader
Shader Rotation Matrix:
...
0
votes
0
answers
894
views
How to make shader graph RenderTexture deform effect more accurate?
I have followed a PolyToots tutorial (https://www.youtube.com/watch?v=3T8cKTQrMxk) to make a 'rug deform' effect.
This is great except for that the vertices aren't deforming faithfully enough to ...
1
vote
1
answer
3k
views
Why does setting blend mode in Unity shader graph to Multiply create artifacts on sprite?
I want my sprite to use a blend mode based on the background (like in Adobe programs) so I set shader graph blend mode to Multiply. The blend works, but I get strange artifacts on my sprite.
In this ...
5
votes
1
answer
5k
views
How to declare per-instance properties for instances rendering on a shader graph?
Unity Version: 2019.4.1f1
Render Pipeline: URP
I created a shader using Unity's Shader Graph, and I want to apply GPU Instancing on this shader, but there is no way to declare per-instance properties ...
0
votes
1
answer
650
views
How can I remove dither effect on player's shadow?
I am trying to make a dithering effect on the player so that when the camera comes below or very close to the player he will be dotted or transparent like in Genshin Impact. So, I followed a tutorial ...
1
vote
0
answers
117
views
How to create intersection shader that simulates squishing?
I want to create a shader that will make spheres/circles look like a blob when colliding.
I don't understand shadergraph at all, but I tried to follow intersection shader tutorials.
The problem is ...
0
votes
1
answer
841
views
make Shader Graph material flow aligned to the mesh UVs (like a river)
i need to add a flow effect to my river so that the water can flow along the path described by the mesh i created. Using ShaderGraph shader i added a time node ...
1
vote
1
answer
3k
views
Unity Shaders: Why is it recommended to use Time to animate things inside of a shader instead of DeltaTime?
In the "Built-in shader variables" section of the Unity Manual, underneath the Time header, there is a table that provides information about each time variable: _Time; _SinTime; _CosTime; ...
0
votes
1
answer
4k
views
Using ShaderGraph for UI elements with transparency
I am trying to design some UI elements using shader graph. In this case specifically a life bar that is transparent where empty.
For a normal life bar with a filled and empty color I got it working ...