Search Unity

2D Graphics resolutions

Discussion in 'Getting Started' started by circleline, Jan 20, 2015.

  1. circleline

    circleline

    Joined:
    Nov 29, 2014
    Posts:
    42
    Hey Guys! So.. I make my graphics from .ai and.. umh i made a background with resolutions 328 x 568 and saved it as a png file. I opened unity and changed 'Game' resolution to 328 x 568. When i placed the background it looked really small why is that? I checked the Main Camera it was working fine. Why?


    Thanks
     
  2. TheZoran

    TheZoran

    Joined:
    Mar 6, 2012
    Posts:
    17
    Could you give more information?

    What do you mean with background and what are the camera-settings?
     
  3. circleline

    circleline

    Joined:
    Nov 29, 2014
    Posts:
    42
    I'll keep simple. I created an image (resolution 328 x 568) and then i changed the Game Aspect to 328 x 568 and imported the image. I placed the image infront of the camera. The image looked bigger that it is supposed to be, why is that?
     
  4. mgear

    mgear

    Joined:
    Aug 3, 2010
    Posts:
    9,406
    Have screenshot?

    How you placed the image in scene?
    Sprite, new UI element? Old GUI?

    Is your camera Orthographic or perspective?
     
  5. circleline

    circleline

    Joined:
    Nov 29, 2014
    Posts:
    42
    Sprite , its 2d.
     
  6. mgear

    mgear

    Joined:
    Aug 3, 2010
    Posts:
    9,406
    Sprites have also pixel ratio settings in the Importer (inspector) window.

    Camera orthographic size matters also..
     
  7. circleline

    circleline

    Joined:
    Nov 29, 2014
    Posts:
    42
    Well, I checked it all but i don't understand, Is there any tutorial out there which explains proper importing and resolution setting tutorial (Unity2d) out there?
     
  8. SiegfriedCroes

    SiegfriedCroes

    Joined:
    Oct 19, 2013
    Posts:
    569
    If I'm not mistaken the following should work:

    In the import settings of your background sprite you have the Pixels To Units value, by default it's 100, keep it that way.
    Select your camera and make sure it's set to Orthographic.
    The Size value of the camera should be:

    [resolution height] / 2 / [pixels to units]

    So in your case that's:

    568 / 2 / 100 = 2.84

    Try that and tell me if it works :)
     
  9. Ska0s

    Ska0s

    Joined:
    Feb 4, 2014
    Posts:
    32