Unity3D canvas config for HD resolution ( 2D games )

Trabla: Unity3D canvas config for HD ( 720 x 1280 ) resolution ( 2D games )


Unity3D canvas config for HD resolution ( 2D games )


This tutorial explains how to proper config canvas (and camera) for HD resolution in 2d games.

Solving:

1. Run Unity3D, create new 2D project

Unity3D canvas config for HD resolution ( 2D games ) tutorial 1


2. Right mouse click on "Main Camera" - select "Panel". Canvas element with be created automatically.

Unity3D canvas config for HD resolution ( 2D games ) tutorial 2

3. Click on "Canvas" in Hierarchy windows.
Than set "Canvas Render Mode" to "Screen Space - Camera"

Unity3D canvas config for HD resolution ( 2D games ) tutorial 3

4. Drag-n-drop "Main Camera" into Canvas "Render Camera"

Unity3D canvas config for HD resolution ( 2D games ) tutorial 4

Unity3D canvas config for HD resolution ( 2D games ) tutorial 5


5. In Canvas Scaler (Script)
change Screen Match Mode to "Scale With Screen Size"

Unity3D canvas config for HD resolution ( 2D games ) tutorial 6

6. Set reference resolution - 720 x 1280  - HD

Unity3D canvas config for HD resolution ( 2D games ) tutorial 7


7. Save Project

Now you can add standart UI button and see how it looks in HD resolution

Unity3D canvas config for HD resolution ( 2D games ) tutorial 8

No comments:

Post a Comment