top of page

Create Your First Project

Start adding your projects to your portfolio. Click on "Manage Projects" to get started

Decal Shader

Unity Shader

The decal shader can manipulate a material as a "sticker", and add the image you like on other objects. It will be much straight forward if you view the pictures I captured below.

The brief idea of making a decal is:
(1) Record the coordinates of vertex in view space;
(2) Reconstruct the coordinates of fragments in view space using depth value;
(3) Convert the coordinates from view space back to object space
(4) Clip the fragments outside the cube box.
(5) Convert the coordinates in object space to uv coordinates, and sample the texture.

P.S. The four characters are Terra, Kafka, Exdeath and Chaos from Final Fantasy, which is one of my favorite game series.

bottom of page