Fake 2D Pixels and Camera Resolution

Hi, right now I am trying to setup a 3D scene and make it look like a retro pixel game.
Axionometric Orthographic Camera and its angles is done. Now I am failing to make things look pixelized.
So I tried to set a low resolution for my camera and then scale things up to fill the screen.
Let’s say I want the camera to use only 320 x 240 pixels and then scale it up.

  1. Does Screen.SetResolution actually do anything? It seems like nothing changes, when setting different resolutions.
  2. Has anyone tried to use Pixel Perfect Camera in 3D environments?

Using Pixel Perfect Camera helps actually doing what I am trying to do. But when I move the camera or things around, the pixel are wildly flickering around. Of course setting Pixel Snapping to true doesn’t help in 3D environments.

  1. Has anyone else experience in trying to fake pixelized 2D with a 3D setup?

If someone asks, why I am trying to do this, or what i am trying to achieve, have a look at games like “Pathway”, where they also achieved a fake 2D look with the help of voxels, that have the exact size of one pixel in the used screen resolution.

Every kind of help, snippets, pointer to articles and demos welcome.

Yes.*

  • But it’s not what you want. The SetResolution function is to set the screen / window resolution. If you’re rendering windowed or windowed fullscreen you can choose any resolution you want, however in windowed mode it’ll change the window size to match, and in windowed fullscreen it’ll use bilinear filtering to upscale it. In “real” fullscreen it can only use the resolutions your monitor has listed, and it’s unlikely 320x240 will be one of them. The real solution is to override your camera’s target to a render texture of the resolution you want, then upscale that in whatever way you want. Luckily …

One of the things the Pixel Perfect Camera does is setup that render texture for you. I have not used it, but there’s no reason it shouldn’t work with 3D environments. The big issue is the pixel snap feature is something only built into Unity’s Sprite shaders. However it’s possible to write custom shaders that implement the same pixel snapping code used by the Sprite shaders. You should also build your 3D meshes to be on pixel perfect grid to begin with, unless you’re looking for something akin to the PS1 “wiggly mesh” look.

There are a ton of examples if you search for them with different looks and techniques employed. Some have free example projects. Some are on the store as paid assets. Most of it comes down to good clean art that reads well at low resolutions.

Pathway is an extreme case. The results are amazing, but that took several years of custom tools and engine work to produce, as well as I’m sure a long learning curve for the artists.

Also, a bit of pedantry, but the term “voxel” has been horribly corrupted over the last several years. Technically speaking Pathway is neither a voxel nor a 2D game. Every “sprite” is a fully 3D mesh, it’s just that the mesh started out life as 2D pixel art that was then extruded with their custom tools into what people today refer to as voxels (really just a mesh made of connected box shapes).