Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

2D Parallax Background Resolution

Discussion in '2D' started by Abhinav91, Oct 31, 2014.

  1. Abhinav91

    Abhinav91

    Joined:
    Oct 21, 2013
    Posts:
    67
    Alright so I'm developing a 2D RPG Platformer for the PC platform. The background is parallax, meaning it's in many layers moving at different speeds to give the illusion of perspective. For the level, rather than use multiple images, I was thinking about using one long image (meaning multiple long layers) instead.
    How would I go about doing this?
    What should the resolution of my images (layers) be? PS: I'm setting the Texture Type as Sprite.

    Also, I'm having a lot of trouble understanding what Max Size is. I looked around, and found very little info. I asked on some Unity groups, I get the answer that it scales down the image to whatever you have slected (64, 128, 256, 512, 1024, 2048, 4096). So just to test, I exported two images from Photoshop - one 6600x1800 and another 12000x3000. I imported them both into Unity and set their Max Size to 4096. Both were still of different sizes. So I'm confused as to what Max Size is actually doing.
     
  2. imaginaryhuman

    imaginaryhuman

    Joined:
    Mar 21, 2010
    Posts:
    5,834
    The texturing hardware has a maximum size of texture that it can reference and use in rendering. Most devices these days including most mobile devices, can support 2048x2048 as the maximum size. Other higher-end and modern desktop cards can go to 4096, some even larger. If you look at `Unity's webplayer stats` you can get a feel for how many people have whatever max texture sizes (i think). Most likely 6600 and 12000 are WAAAAAY too big for the hardware to handle in a single texture, so then it will scale them down to whatever size you suggested.