newimageRect without setting width & height.

Hi!
Am i the only one who thinks that it is a pain to being forced to set the width and height of an image when you are using display.newImageRect? For me it is annoying since i will probably change the image dimensions a lot of times during the deleveopment of the game.

Anyhow, i have created a class that will handle this for you, so the width & height settings won’t be needed.

What do you think?

Link:
http://monogames.se/post/33149912622/display-newimagerect [import]uid: 103182 topic_id: 31760 reply_id: 331760[/import]

You can make your life even easier by using something like this: http://web-c2.anscamobile.com/forum/2012/05/16/pnglib-extract-data-png-files-width-height-color-depth-etc [import]uid: 84637 topic_id: 31760 reply_id: 126780[/import]

Wow! Didn’t know about that one. Yeah, i guess that will work too =) thank you for the tip! [import]uid: 103182 topic_id: 31760 reply_id: 126786[/import]

Hi,
You can also take a look at this:

http://developer.coronalabs.com/code/different-way-managing-dynamic-image-resolution-and-scaling-font-size

I wrote this just in order to forget about the headache with image sizes - using this approach you can manage dynamic resolution images and not care at all about their dimensions.

I think this is not the last version of the code, if you are interested I can update the post

Michael [import]uid: 57266 topic_id: 31760 reply_id: 126873[/import]

You can make your life even easier by using something like this: http://web-c2.anscamobile.com/forum/2012/05/16/pnglib-extract-data-png-files-width-height-color-depth-etc [import]uid: 84637 topic_id: 31760 reply_id: 126780[/import]

Wow! Didn’t know about that one. Yeah, i guess that will work too =) thank you for the tip! [import]uid: 103182 topic_id: 31760 reply_id: 126786[/import]

Hi,
You can also take a look at this:

http://developer.coronalabs.com/code/different-way-managing-dynamic-image-resolution-and-scaling-font-size

I wrote this just in order to forget about the headache with image sizes - using this approach you can manage dynamic resolution images and not care at all about their dimensions.

I think this is not the last version of the code, if you are interested I can update the post

Michael [import]uid: 57266 topic_id: 31760 reply_id: 126873[/import]