On 2024-07-23 14:23, jbv via use-livecode wrote:
Hi list,

I have the following script :

 create image
 put number of imgs into ni
 put id of img ni into tid
 set filename of img id tid to myFile
 put imageData of img id tid into pimage
-- many lines for imagedata analysis
 crop image id tid to rect trect

I get this error :
 crop: object is not an image

That is a slightly misleading error...

'crop' does not operate on images which are referenced - i.e. use a filename

To crop such an image, load the data into the image:
   set the text of img id tid to url ("binfile:" & myFile)

Hope this helps.

Warmest Regards,

Mark.

--
Mark Waddingham ~ m...@livecode.com ~ http://www.livecode.com/
LiveCode: Build Amazing Things

_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to