compression

Is there an open-source implementation of the Dictionary Huffman compression algorithm?

I'm working on a library to work with Mobipocket-format ebook files, and I have LZ77-style PalmDoc decompression and compression working. However, PalmDoc compression is only one of the two currently-used types of text compression being used on ebooks in the wild, the other being Dictionary Huffman aka huffcdic. I've found a couple of i...

c++ compress byte array

Greetings all, I load set of images and generate volume data.I save this volume data in a unsigned char *volume array. Now I want to save this array in a file and retrieve.But before saving I want to compress the byte array since the volume data is huge. Any tips on this? Thanks in advance. ...

Faster, more efficient JPEG conversion and compression on the iPhone

I'm grabbing frame images from the iPhone's camera at a rate of 25fps using a resolution of 192 x 144 and a 420v, BGRA format. I'm converting the CVImageBufferRefs into UIImages and then calling UIImageJPEGRepresenation(image, compressionQuality) to get a compressed JPEG version of the image. Using the Time Profiler in Instruments, I c...

How to compress, encrypt, and then read/search large XML file stored on iphone disk?

I have a large 'book' that I need to compress, encrypt and also make searchable on the iphone. The app has some requirements that won't allow a simple PDF or EPUB. I have the book in plain text on my computer, and I am parsing/converting it to XML. I want to compress the file to reduce app purchase download time, and encrypt the app j...

Why is Apache not redirecting a folder it should be and not compressing?

Ok, so this problem recently arose and I don't know why it is happening; it's actually two problems in one... 0. My .htaccess file, for reference. Options -Indexes +FollowSymLinks RewriteEngine On RewriteBase / ErrorDocument 400 /index.php?400 ErrorDocument 401 /index.php?401 ErrorDocument 403 /index.php?403 ErrorDocument 404 /index.p...

Optimized order of HTML attributes for compression

I read somewhere that organizing HTML attributes in a certain order can improve the rate of compression for the HTML document. (I think I read this from Google or Yahoo recommendation for faster sites). If I recall correctly, the recommendation was to put the most common attributes first (e.g. id, etc.) then put the rest in alphabetical ...

How can I tell if Heroku is sending gzipped responses?

I'm making an iPhone application that requests JSON from Heroku. Am I getting a gzipped response? And, does the iPhone automatically unzip gzipped responses, or do you have to program that in? I'm using NSURLConnection asynchronously (with the delegate protocol) as described in the Xcode docs. When I do: curl -I http://acani.heroku.c...

How to quickly check if a zip file is corrupted?

Hello, Does anyone have any ideas for how to pragmatically quickly check if a zip file is corrupted based on file size? Ideally the best way to check if a zip is corrupted is to do a CRC check but this can take a long time especially if there is a lot of large zip files. I would be happy just to be able to do a quick file size or header...

Offline CSS compressor

I am looking for a css compressor that can run on our build server that can be executed on a number of css files. Does anyone know of any good ones that work offline? ...

Gzip JS and CSS in Django

Hi. I tried profiling my web application and one of the bottlenecks reported was the lack of gzip compression. I proceeded to install the gzip middleware in Django and got a bit of a boost but a new report shows that it is only gzipping the HTML files i.e. any content processed by Django. Is there a way I could kludge/hack/force/make the...

PHP compress files into zip

Hello there okay so this is the deal i have a folder where my mp3 files are stored for single download, and now i want a feature where you can download all the mp3s at once in a zipped folder. Is it possible to zip all the files from that folder using php ( or anything really but if not PHP then please explain thoroughly) or would i have...

Can GZip compression (via .net) increase file size?

I keep track of the original size of the files that I'm compressing using .Net's GZipStream class, and it seems like the file that I thought I was compressing has increased in size. Is that possible? This is how I'm doing the compression: Byte[] bytes = GetFileBytes(file); using (FileStream fileStream = new FileStream("Zipped.gz", Fil...

Scaling an Image Based on Detail

I'm curious about whether there are approaches or algorithms one might use to downscale an image based on the amount of detail or entropy in the image such that the new size is determined to be a resolution at which most of the detail of the original image would be preserved. For example, if one takes an out-of-focus or shaky image with...

Sequence Compression ?

Hi everyone , lately i've faced a problem which gets me so confused , the problem is : i want to compress a sequence so no information is lost , for example : a,a,a,b --> a,b a,b,a,a,c --> a,b,a,a,c (it can't be compressed to a,b,a,c because in this way we lose a,a) Is there any algorithm to do such a thing ? what is name of this pr...

Is there a text compression library for .NET?

I a looking for a library that can compress text. Not short string but rather pages. Is there any known library or opensource code? ...

Difference between stateless and stateful compression?

In the chapter Filters (scroll down ~50%) in an article about the Remote Call Framework are mentioned 2 ways of compression: ZLib stateless compression ZLib stateful compression What is the difference between those? Is it ZLib-related or are these common compression methods? While searching I could only find stateful and stateless w...

Best way to suppress OpenGL ES (iPhone) texture / OpenAL sounds memory footprint?

What should i do? I have some 512x512 png. I compressed them to PVR (which results terrible quality), and I'm preparing to compress the PNGs with pngcrush tool. The PVRs have about 2x-x larger filesize than the PNGs, maybe I can experiment with JPG files. Are the images stored in a compressed state in memory? Or compression counts only ...

what video/image encoding format is recommended when trying to encode and transmit raw video in real time ?

Hi, I'm trying to encode and transfer raw video frames over LAN (100 Mbps) connection (frames captured by a web cam). What video/image encoding format is recommended for fast compression (with not much regard for the compression ratio) ? Thanks, ...

Compression with best ratio in Python?

Which compression method in Python has the best compression ratio? Is the commonly used zlib.compress() the best or are there some better options? I need to get the best compression ratio possible. I am compresing strings and sending them over UDP. A typical string I compress has about 1,700,000 bytes. ...

Creating a .tgz with windows ?

Hi, Sorry, just a quick question before I submit an assignment online. I just followed this guide - http://www.ehow.com/how_6104990_create-_tgz-file-windows.html to make a .tgz file from one of my folder. I then renamed the file created from .tar.gz to a .tgz. I was just wondering would this have the exact same result as the instruct...