Power of 2 question

  • I'm trying to understand the Power of 2. If I need a sprite to be at least 150x50, should I just make it 256x85 and scale it down in C2 to 150x50? Will there be any difference in load time or file size?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Fimbul

    I appreciate the link, but my question has nothing to do with event optimization. I'm more concerned with image quality and overall file size at the moment. Thanks though.

  • You don't need to *scale* the existing stuff . In fact, I'm quite sure this ain't anything you really need to spend time thinking off. There are some limitations on mobile systems, but it's nothing you'd need to worry about.

  • Joannak

    Visual quality is something I care about and scaling matters on high resolution devices. I should have mentioned that I'm not working 'on scale' because my game is intended for multiple screen sizes. My goal is to balance high quality visuals with a small file download size. I'm already pushing the limitations of the devices I'm testing on and I've had to cut certain things out because they create lag. Those things matter to me.

    I just need a simple answer. Basically, does an image the size of 150x50 take up the same amount of space as an image 256x256, or more to the point, does the Power of 2 still apply to current devices? Everything I've read about it is dated and technology changes. I'm just looking for a confirmation.

  • Fwumpy

    Power of 2 is still a thing, yes. It's less to do with visual quality and more to do with efficiently using available device memory based on the way GPUs process data. Images don't have to be square, so your 150x50 example would fit into 256x128 instead of 256x256. This will get done by the GPU itself, so you don't have to manually resize the image to 256x128, just be aware that a 150x50 image will have the same memory requirements as an image that's 256x128.

    Unless you're doing a hugely complex game with hundreds of unique animations, though, it's not something worth concerning yourself with. Mobile devices are pretty speedy these days.

  • Resizing action itself takes up GPU a little bit, so resizing the sprite on every tick is not that good. But in this case, it seems that doesn't matter. It doesn't have something with the power of 2.

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