Compression question / problem
alex at tweedly.net
Wed Jan 12 13:49:10 EST 2005
Richard Miller wrote:
> Looking for the simplest and quickest solution to a compression
> problem. The goal is to take 50 jpeg images (highly compressed)
> starting on a Mac, move them to our directory on a hosted web server,
> then have them downloaded and displayed on a Windows XP machine.
> Transmission time (over the Internet) is a very big factor here.
> Here's what we've done so far:
> 1. Started with 50 jpeg images.
> 2. Put them into 50 custom properties of a holding stack.
> 3. Compressed the stack using the RR compress command.
> 4. Decompressed that stack using the decompress command.
> 5. Tried to open that stack, but it is always reported as corrupted.
> 6. The size of the decompressed stack is ALMOST the same as the
> original stack, but a few bytes short.
> Also tried this:
> 1. Took one of these jpeg images.
> 2. Compressed it with RR compress command.
> 3. Decompressed it.
> 4. Tried to open it. It is always corrupt.
> 5. The size of the decompressed file is the same as the original file
> size, but in looking at the data in TextEdit, it is readily seen a few
> characters have shifted places in the first few lines.
> Suggestions? What's going on here? Thanks.
The overall description mentioned various different machines - but the
step-by-step didn't. Is this testing all on one machine ?
I tried this script
local t, t1
put URL ("binfile:d:/Our Documents/Alex/RunRev/Photo/IMGP0633.JPG") into t
put the number of chars in t after msg
put compress( t ) into t1
put " " & the number of chars in t1 after msg
put decompress(t1) into t
put " " & the number of chars in t & cr after msg
put t into URL ("binfile:d:/Our
and verified that it the output JPG works fine. Might be worth you
trying it (with suitable file name, of course :-) and then narrowing in
on any differences between it and your own test script.
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.6.10 - Release Date: 10/01/2005
More information about the Use-livecode