Optimal sprite size for zooming

0 favourites
  • 7 posts
From the Asset Store
220 Food Sprites in 16x16 pixel size. Perfect for items for a retro style game.
  • Hello!

    I'm starting a game that will have zooming effect, both in and out.

    Let's think of this as some "metal slug" type game.

    I want to zoom IN from this view (aprox):

    <img src="http://andresborghi.com.ar/imagenes/screen1.jpg" border="0" />

    to this view here:

    <img src="http://andresborghi.com.ar/imagenes/screen2.jpg" border="0" />

    (the character shown is just an example, not the final one)

    This would NOT be a resize of the character only, the background would zoom too.

    Logic tells me that the sprite should be as big as the second screen, so when it zooms in I don't lose quality and I can even show more detail to the character. But this will be a 1920 x 1080 game. I made the test and 1 sprite of the character in PNG is near 600kb (i don't know if gets smaller when compiling or something)

    the question is: will the game run slow with a character this big? Even when it's resized inside the game.

  • 2 options:

    1- Change renderer adjust from linear to point.

    2- Create a high resolution such as 2560 x 1440 sprite, then import in C2 and resize to specificed size in sprite, the zoom quality on this sprite doesn't get blurred.

  • what does the that renderer setting alter?

  • Will there be an intermediate zoom or just the zoomed in and zoomed out viewWill there be an intermediate zoom or just the zoomed in and zoomed out view?

  • PNG size isn't important while playing. VRAM usage is:

    To figure out how much VRAM an image will use, you multiply the width and height together, multiply that by 4 to get bytes, then divide that by 1024 to get kilobytes. So a 32 x 32 image would be:

    (32 * 32 * 4) / 1024 = 4KB

    Transparency doesn't matter when considering VRAM, as the images are stored uncompressed.

    Also keep in mind that most video cards will store the image in a texture that is rounded up to the nearest power of 2 size, so for example, a sprite that is 280 x 280 pixels would be stored in a texture that is 512 x 512, taking up a much larger amount of VRAM.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Will there be an intermediate zoom or just the zoomed in and zoomed out viewWill there be an intermediate zoom or just the zoomed in and zoomed out view?

    There will be an intermediate zoom. Actually i wanna go changing the zoom depending on the zone or level. I still have no idea how to do the zoom stuff but I'll get to that when I need it. So, that's why I only included the 2 extremes of the zoom in this topic.

    PNG size isn't important while playing. VRAM usage is:...

    So then I really should make the character sprites as big as the nearest zoom, right?

  • If the sprites are animated C2 will make spritesheets out of them put into a power of 2.

    The most important thing to take into account is the weight of the graphics on the performance. Using a bigger sprite and reducing it's onscreen size give better results than using a smaller one and scaling it up, if you want it to look crisp. A disadvantage of this is that bigger sprites will take up far more VRAM and on less capable devices (Mobiles and older desktops) could be your bottleneck in performance.

    There are many topics about this on the forums.

    -Try to re-use sprites as much as possible.

    -Use tiled backgrounds if possible.

    -Use your VRAM wisely.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)