top of page

3D Pixel Render Pipeline (3D PRP)

A custom render pipeline I made in Unity designed to turn 3D worlds into pixel art.

3D PRP Example

Features

Pixel Perfect Rendering

To achieve the pixel art look, the pipeline renders the scene at a lower, user-defined resolution. However, this alone is not enough as it would result in jittering pixels, ruining the pixel art aesthetic. To remove the jittering artifact the camera's view matrix has to be snapped to the nearest pixel. However, to calculate this the rotation of the camera has to be taken into consideration. Luckily this can be accounted for by using some relatively simple trigonometry.

Anchor 1
Sub-Pixel Camera Movement

This pipeline can also optionally support sub-pixel camera movement. To achieve sub-pixel camera movement the final blit to the screen has it's viewport offset exactly opposite to the difference between the camera's unsnapped and snapped positions.

Anchor 2
Stylized Outlines

This pipeline also features stylized outlines that react to lighting changes. The outlines are achieved by using Sobel edge detection within the material's shader. This allows the outlines to blend with the material's output color creating a subtle outline effect. In addition, the color of the outline is separated into two colors depending on if the edge was detected by depth or normals.

Anchor 3
bottom of page