imageData and resizing

Mark Schonewille m.schonewille at economy-x-talk.com
Fri Jun 14 18:24:06 EDT 2013


Hi Tom,

This won't work, unless the imageData fit the image rect exactly. To 
solve this, set the imageData first and then resize. Better yet: don't 
use imageData but use the original PNG or JPEG data to set the text of 
the image object. Set the lockLoc to false, then set the text, resize, 
and set the lockLoc to true.

--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Use Color Converter to convert CMYK, RGB, RAL, XYZ, H.Lab and other 
colour spaces. http://www.color-converter.com

Buy my new book "Programming LiveCode for the Real Beginner" 
http://qery.us/3fi

Fill out this survey please
http://livecodebeginner.economy-x-talk.com/survey/

On 6/14/2013 15:19, Thomas McGrath III wrote:
> I'm trying to find a solution to images getting messed up after doubling their size for retina and then trying to set the imageData after they have been resized. The images get messed up with either horizontal lines or color shifts.
>
> This works for one image but not for a group of images. As soon as I try to set the imageData of a group of images about half way through the images start to screw up.
>
> set the resizeQuality of image x of group "images" to "best"
> set the lockLoc of image x of group "images" to true
> set the width of image x of group "images" to (the width of image x of group "images" * 2)
> set the height of image x of group "images" to (the height of image x of group "images" * 2)
> set the imageData of image x to tempimage
>
> Any ideas or workarounds???
>
> Thanks
>




More information about the use-livecode mailing list