Rev cannot open my jpeg ! - and some serious thinking

Mike Markkula acm at armas.com
Mon Jul 13 19:39:55 EDT 2009


Sarah, and anyone else wanting to use image files wider than 4091 pixels,

Here's a partial work around for working with files larger than 4091 pixels
wide. It's based in part on Devin Asay's idea of splitting the imageData
into pieces small enough for rev to handle & then displaying them side by
side. As it turns out, that won't work because rev corrupts all the pixels
in each row from 4047 to the end of the row, so even though you can read
image files of any width, only the first 4047 pixels of each row are usable.
With the help of my trusty sidekick Jerry Jensen, I wrote an example stack
that loads images wider than 4091 and creates a useful image object from the
first 4047 pixels of each row. For some applications it may be better than
no image at all... Here's a link to download the example stack:
http://acm.on-rev.com/WideImagePartialWorkAround.rev.zip

This is definitely a problem that rev needs to fix very soon!
Vote for bug # 4026 !!
http://quality.runrev.com/qacenter/show_bug.cgi?id=4026

Go Rev!

Mike Markkula

On 7/1/09 1:07 AM, "Sarah Reichelt" <sarah.reichelt at gmail.com> wrote:

>>> Me for one. My app Pic-a-POD <http://www.troz.net/Pic-a-POD/> suffers
>>> greatly from this problem as more and more large images appear on the
>>> internet. At the moment I am forced to check for images with more than
>>> 4000 pixels on any side, and if so, I just have to show a notice
>>> saying that the image is too big to display.
>> 
>> +1
>> 
>> Pic-a-POD sits on my desktop :-)
>> 
>> "POD" web sites do change their format from time to time, though...
>> For instance, National Geographic leads to a "Picture is not in the
>> correct format" warning.
>> and Wikipedia furnishes regurlarly too big images!
> 
> Just to confirm this after some tests:
> - the problem is on Mac only
> - the height of the image does not seem to matter
> - my test image displayed correctly at 4090 x 3000 pixels (72 dpi)
> - my test image sometimes displayed correctly at 4091 x 3000 pixels (72 dpi)
> - my test image failed at 4095 x 3000 pixels (72 dpi)
> 
> I have not yet done enough testing to tell whether the overall number
> of pixels or the dpi alters this slightly variable cut-off point.
> For Pic-a-POD, I intend to change "Can't display" message so it only
> shows if the width of the image is > 4000 and the platform is Mac.
> 
> BTW, Dom there is now an update to Pic-a-POD that fixes the National
> Geographic problem.
> 
> With regard to Wikipedia supplying enormous images, does anyone know a
> method for determining the size of a download before it starts? Once
> the download has begun the URLStatus gives the total size, but it
> would be really useful to get this before starting. I guess I can see
> whether I can get a directory listing but I doubt that would be
> permitted. The only other option I can think of is to start
> downloading invisibly, and stop after the first status report, suing
> that data to see whether the incoming image file is too large.
> 
> Cheers,
> Sarah
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
> 





More information about the use-livecode mailing list