Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by ismailmuayad · Aug 16, 2016 at 05:16 AM · 2d game

How does unity unity deal with screen resolution, screen aspect ration and what kind of units does it use?

Hi.

I am new to both unity and and game development, so I am not sure If I am using the proper terminology but I will try to explain my question as best I can, I started to learn unity aiming to learn how to make 2D games for mobile devices, it has been about a week since I started this hobby, I want as I progress in learning to make simple games so I see my self improving, however, I found myself lost in a certain area which is graphics ( I am not sure if that is its a proper name for my case ), and by that I don't mean where I am supposed to get them but if they fit or not, so if you can please just direct me to tutorials, documents, courses or anything that discuss the following points in complete details: ( I only want to know about the things that are related to 2D)

  1. What kind of units does unity use and how does it relate to pixels?

  2. How can I get to see in unity what will a player see in his phone, is there a setting that will change the game window to show me in the perspective of mobile? and what controls that is it the camera? if so how can I change it dimensions?

  3. How do I setup the screen resolution and aspect ratio, do I set those in pixels or in unity units?

  4. I am not sure how to say this one but hope you understand what I mean, does knowing about the previous points suffice to choose proper dimensions for my graphics? I mean will it display properly on the screen ? or there is more to it than that?

Thanks in advance.

PS: if you know of courses about building 2D games I will be really thankful if you post the link, thanks again.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
2

Answer by damagefilter · Aug 16, 2016 at 06:33 AM

I don't know any resources at the top of my head but I can tell you something to a couple of your points at least.

1) Units are Unitys way of measuring distances (simply speaking). It's up to you how you interpret them. You can define for yourself that a Unit is, perhaps, a meter. Or a cm. So that's kinda abstract.

How it relates to pixels on the other hand, is less abstract. There's an option when you import images as sprites. It's called pixels per unit. That's exactly what it says. How many pixels fit into one unit of space.

For instance, if you had a PPU ratio of 10 then there will be exactly 10 pixels of your image between x=1 and x=2. The same for y axis (and z axis in theory but in 2D you don't really have that of course).

For your second and third question, this may help to get you there: http://answers.unity3d.com/questions/673583/custom-resolution-and-aspect-ratio.html

4) It's kind of an abstract problem you are describing there. You see, the camera you will be using to get the scene rendered on a device can be "zoomed" in or/and out so if you feel that not enough stuff is visible on the real estate you have at your disposal, zoom it out. For pixel perfect rendering there's a bit of maths to be done to make it look 100% correct but I suggest you worry about that later when it really becomes an issue for you.

For a 2D igniter: https://unity3d.com/learn/tutorials/topics/2d-game-creation

There's everything you need. I recommend the live-session recordings.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image ismailmuayad · Aug 16, 2016 at 01:22 PM 0
Share

Thank you, I think I have a better idea of where and what to look for now, I will watch all of these tutorials, I hope I understand everything by then. Thanks again, you were great help.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

4 People are following this question.

avatar image avatar image avatar image avatar image

Related Questions

What happens when i select for android "ETC1 (split alpha channel)", but disable sprite packer for builds 0 Answers

2D Endless runner spawning on top of each other? 0 Answers

Sticking Assets please help.... I am Beginner.. 1 Answer

How to plot a 2d dotted line 0 Answers

Gameobject not moving unless starting at 0 transform 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges