Fun with shaders

Hello somebody!

I think writing shaders is some of the best fun you can have programming. The way we humans are wired we really are suckers for visuals. So it’s no wonder if some find working with shaders fun, since it offers very strong instant reward.

However “instant” reward applies only to those who already know how to do it and only have to make their creative vision happen. I’m still very much at the beginning of learning the basics so it’s still a lot of headache, but also a lot of “Ah!” moments to be fair.

One of the best exercises imo is the implementation of the Team Fortress 2 shader. It’s very well documented and explained, and you can usually find someone who has already done it before. So translating it in to the environment you are currently working in should be manageable even for a newbie. Not to mention it’s a pretty cool looking shader.

So that’s what I set out to do in Unity. Writing shaders is very convenient in Unity. They implemented a system where you pretty much only have to write the parts you want to be customized. I’m pretty happy with the result, though I have no idea if it could be done better.

A demo of the shader can be found here.

Next step will be reading the Cg Tutorial book for more information. After that I want to make something I call the Sadowski shader. Aandrzej Sadowski is a painter, but I don’t know much about him. Judging by his name he’s probably Polish. I saw a couple of pictures at hyperrealist exhibition, though I think his paintings would rather be considered photorealistic. I really liked the picture below, so I will try recreating it the best I can.

Group Picture With the Yellow Renault (I think that was the title)

Bye and have a nice day!


Tags: , , , , , ,

3 responses to “Fun with shaders”

  1. Fas says :

    Yes, he’s a polish painter, still alive, and this painting has much political conotations, because it was made when Poland was a communist country under Soviet Union 😉 this is my licence work for art history studies, so if You want to know more let me know.

    • onetinyleap says :

      It’s very hard to find anything about him online. I could only find 3 of his pictures: this one, the one with the horse, and another one of a city street. I started work on the shader, but I didn’t get very far. I suppose as a first step I should analyze the picture to determine the characteristics I want to recreate.

  2. Fas says :

    and title is correct.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: