예제 #1
0
        static bool Decompress(ShockwaveFlash flash)
        {
            if (flash.CompressWith != CompressionStandard.None)
            {
                int compressedSizeMB = ((flash.ToArray().Length / 1024) / 1024);
                int uncompressedSizeMB = (((int)flash.FileLength / 1024) / 1024);

                ClearWriteLine("Decompressing... | ({0}MB) -> ({1}MB)",
                    compressedSizeMB, uncompressedSizeMB);

                flash.Decompress();
            }
            return !flash.IsCompressed;
        }
예제 #2
0
        static byte[] Compress(ShockwaveFlash flash)
        {
            WriteLine("Compressing... | ({0}MB) | This may take a while, no more than a minute, hopefully.",
                (((int)flash.FileLength / 1024) / 1024));

            return flash.Compress();
        }