Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411283 Posts in 69325 Topics- by 58380 Members - Latest Member: bob1029

March 29, 2024, 02:47:49 AM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsDeveloperTechnical (Moderator: ThemsAllTook)Postprocessing/Shader basics?
Pages: [1]
Print
Author Topic: Postprocessing/Shader basics?  (Read 814 times)
roguesleipnir
Level 0
**



View Profile
« on: September 12, 2016, 07:26:37 PM »

I've been a gameplay/mechanics dev by trade. I can handle game complexity.
One thing I've been down about is my games don't look that complex visually.

I'd like to learn more about common postprocessing effects like blur, bloom, displacements.
I'm using Unity for a 2D game right now so I'd like to start with that.
I've only dabbled with simple masking shaders for now.

Can you point me to a good place to start? Thanks!
Logged
oahda
Level 10
*****



View Profile
« Reply #1 on: September 13, 2016, 12:04:10 AM »

A good start:




After that you might feel ready to start stepping through these docs a bit:
https://docs.unity3d.com/Manual/SL-VertexFragmentShaderExamples.html

And then there is some more advanced, cool stuff here:
https://www.youtube.com/channel/UCEklP9iLcpExB8vp_fWQseg

But perhaps most importantly, once you get the very basics, don't just follow tutorials, but start playing with stuff yourself to see what happens, and try to achieve simple stuff.
Logged

roguesleipnir
Level 0
**



View Profile
« Reply #2 on: September 13, 2016, 01:20:35 AM »

> https://www.youtube.com/channel/UCEklP9iLcpExB8vp_fWQseg

Just what I needed. Thanks!
Logged
rozza
Level 0
**



View Profile WWW
« Reply #3 on: September 27, 2016, 11:28:16 PM »

I went through the Unity Cookie series on shader writing while I was also studying it at uni and they were pretty great if you want to learn CG/HLSL.

Shader Forge is also pretty good as a node-based editor where you can see everything and don't have to write code, but does cost money.
Logged
Friez
Level 0
**



View Profile
« Reply #4 on: September 28, 2016, 06:50:43 AM »

I would start here:
https://docs.unity3d.com/Manual/WritingImageEffects.html

When you have a script attached to a camera with an OnRenderImage() function you are passed a RenderTexture for the screen 'prior' to your tinkering and should write an 'output' render texture, you can do this via a Blit() function by passing in a material with a custom shader.

https://docs.unity3d.com/ScriptReference/Camera.OnRenderImage.html for an example of a basic blit with a material

A really simple shader you could try to get working is a color inverter: Take the input rgb values and 1-source.rgb in the pixel shader. Then play around! It's the best way to learn how to do things.
Logged

Twitter @friezdj
Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic