Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: How do I get the original size of the sprite before I scaled it  (Read 1548 times)

0 Members and 1 Guest are viewing this topic.

bryce910

  • Newbie
  • *
  • Posts: 31
    • View Profile
How do I get the original size of the sprite before I scaled it
« on: October 31, 2015, 12:53:18 am »
Hello guys!

I am working on scaling some textures accordingly and I am trying to figure out how do I get the original size of the sprite after I already scaled the item.

For example:

/* Sprite Size = 800X600 */
Sprite.setScale(2.0f, 2.0f);
/* New size 16200X1200 */
 

How would I obtain getting the value of the original size of the sprite (800 X 600) without rescaling it?


bryce910

  • Newbie
  • *
  • Posts: 31
    • View Profile
Re: How do I get the original size of the sprite before I scaled it
« Reply #2 on: October 31, 2015, 01:06:58 am »
Thank you. I just noticed the different between global and local!