Crazy imageData

Frank Leahy frank at backtalk.com
Mon Jun 21 17:15:47 EDT 2004


On Jun 21, 2004, at 9:41 PM, use-revolution-request at lists.runrev.com 
wrote:

> From: Troy Rollins <troy at rpsystems.net>
> Subject: Re: Crazy imageData
> To: How to use Revolution <use-revolution at lists.runrev.com>
> Message-ID: <C7DEF6B0-C3AF-11D8-BDF0-000A95A09CF8 at rpsystems.net>
> Content-Type: text/plain; charset=US-ASCII; format=flowed
>

> Anything else? This is driving me nuts, as it will appear to be
> resolved... work for a LONG time (many data transactions), and then
> suddenly start failing. But basically, it either will work in a run of
> the program, or not. Once it doesn't, it never seems to work again,
> until I change something about the code. Then, it works for a while,
> and then... well, you get the... picture.
> --
>

You might consider not using imageData  -- you could import/export 
using temp files instead -- I do it that way, and it's pretty fast, and 
much less error prone.

But best of all you won't be munging with imageData.  Fooling around 
with imageData is a bit like playing with fire -- I'm a bit surprised 
that they support imageData at all, it's really the one place in RR 
that you can touch 1's and 0's directly.  I would guess that the 
imageData is a binary data structure (probably a QuickDraw CGrafPort on 
the Mac), and I can definitely see how it could get screwed up (imagine 
the height and width not matching the grafPort data), and that after 
it's been screwed up (however that happens), it stays screwed up.  
Actually I'm surprised you haven't seen any crashes.

-- Frank



More information about the use-livecode mailing list