compression

GZip or Deflate for HTTP compression

一世执手 提交于 2019-12-10 06:37:26
问题 Which compression method is better? I've heard lots of back and forth about GZip being more widely used, but Deflate being faster (in some instances). Is there an accepted standard on which one to use and why? 回答1: UPDATE According to the latest updates to the linked question, one should use GZip. See http://www.vervestudios.co/projects/compression-tests/results Old Answer Deflate is better. 回答2: Answers: http://www.stardeveloper.com/articles/display.html?article=2008111201&page=1 http://blog

Adding a directory to an existing .zip file

谁说我不能喝 提交于 2019-12-10 05:33:42
问题 First of all I would like to say that i've tried looking for the solution to this and I haven't found one where I don't have to unzip, add my folder and then zip again. I am not using any third party libraries. I would like to do this using system.io.compression if it's possible at all ... If not I would use dotnetzip as my last resort. tl;dr. I want to be able to add directories with files in them to an already created zip file. Is this possible using the system.io.compression library ? EDIT

JavaScript inflate implementation (possibly FF 3.6 only)

天大地大妈咪最大 提交于 2019-12-10 04:32:08
问题 I'm writing some scripts that are using the HTML 5 file API in FireFox 3.6. I got some deflated (compressed) files, and I need to inflate (uncompress) them. I found a few scripts while googling, but none of them have tests. So I'm a bit reluctant to use them. My question is: Browsers can inflate. Can I somehow piggyback on the inflation by forging A XHR request? Or piggyback in any other way? Keep in mind, the script is currently FireFox 3.6 exclusive. It can't be an extension, though, I want

Maximum compression of a MSI install using WIX

[亡魂溺海] 提交于 2019-12-10 04:10:10
问题 I used to build installs for an app with NSIS and the final self extractor was 1.2 MB. Now I need to use WIX due to operational needs and the same install comes out at 4.2 MB. I set the compressed flags as the docs and specs indicated on the package node. Using 7z to zip the MSI results in a 2.4 MB zip file. Question: How can I do a maximum compress on the MSI or create a small MSI (e.g. remove unneeded resources etc) ? Note - size is uber important and I have to use MSI/WIX now - this is a

decompress a ZIP file on windows 8 C#

走远了吗. 提交于 2019-12-10 01:48:05
问题 I am building a metro style app for windows 8 and I have a zip file that I am downloading from a web service, and I want to extract it. I have seen the sample for compression and decompression, but that takes a single file an compresses/decompresses it. I have a whole directory structure that I need to extract. Here is what I have so far: var appData = ApplicationData.Current; var file = await appData.LocalFolder.GetItemAsync("thezip.zip") as StorageFile; var decompressedFile = await

Looking for more details about “Group varint encoding/decoding” presented in Jeff's slides

烂漫一生 提交于 2019-12-09 18:38:31
问题 I noticed that in Jeff's slides "Challenges in Building Large-Scale Information Retrieval Systems", which can also be downloaded here: http://research.google.com/people/jeff/WSDM09-keynote.pdf, a method of integers compression called "group varint encoding" was mentioned. It was said much faster than 7 bits per byte integer encoding (2X more). I am very interested in this and looking for an implementation of this, or any more details that could help me implement this by myself. I am not a pro

Compression component

折月煮酒 提交于 2019-12-09 18:22:32
问题 I am looking for a compression component that supports Delphi2010 and allow me to do the basic operations of: create .zip archives extract from .zip archives delete .zip archives I also need the component to be free for commercial usage and possibly does not use/rely on a DLL (I don't mind if it does). So far I have looked into ZipForge, FlexCompress, KaZip and UnRAR, but I found out that I needed to purchase a license to commercially use ZipForge and FlexCompress. When it came to KaZip,

Webpack V4: Remove console.logs with Webpack & Uglify

烈酒焚心 提交于 2019-12-09 17:44:43
问题 This answer worked like a charm previously: https://stackoverflow.com/a/41041580/3894981 However, since Webpack v4 it doesn't work anymore. Since then it throws: Error: webpack.optimize.UglifyJsPlugin has been removed, please use config.optimization.minimize instead. What is necessary here in order to make it work in Webpack v4? I've tried using the following without luck: const uglifyJsPlugin = require('uglifyjs-webpack-plugin'); if (process.argv.indexOf('-p') !== -1) { // compress and

C# better compression for remote desktop broadcast application

只愿长相守 提交于 2019-12-09 13:53:04
问题 I am in the process of creating a TCP remote desktop broadcasting application. (Something like Team Viewer or VNC) the server application will 1. run on a PC listening for multiple clients on one Thread 2. and on another thread it will record the desktop every second 3. and it will broadcast the desktop for each connected client. i need to make this application possible to run on a connections with a 12KBps upload and 50KBps download DSL connection (client's and server). so.. i have to reduce

Bit compression in Javascript

戏子无情 提交于 2019-12-09 13:09:12
问题 Is there a way to compress a JavaScript array of 250+ 1s and 0s into something a little more manageable (say a shorter string) and then manageably decompress the same? Sort of like the way Google did its image encodings... Thanks! 回答1: I can give you almost 1:5 compression by encoding as base 32. I chose to include a simple length value to make it allow variable-length. Please see this fiddle demonstrating the technique with two functions that allow you to round-trip the value. (Or you can