Pixel to Unity Unit

When creating a 2D level plan like the one shared in the resources, you mostly work in pixels. You then import this image into Unity to use it as a basis for your 3D level design. And 3D level design is made within Unity using Unity units. Is there a conversion between pixel dimensions and Unity unit dimensions? In other words, how many pixels is a Unity unit?
Thank you.

Hi,

Pixels refer to the lights in our screen. World Units refer to nothing outside Unity. Their dimension in pixel depend on the camera. If the camera renders 10 World Units, and the result is a 1000 x 1000 px image, each World Unit would be 100 x 100 px. If the camera renders a 500 x 500 px image, each WU would be 50 x 50 px.

Since we also have depth in the 3D game world, it is impossible to tell how many pixels game objects will have when being rendered unless we do some fancy maths.

Please feel free to discuss this topic further over on our Discord chat server. :slight_smile:


See also:

Thanks for your help.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms