Current News
Archived News
Search News
Discussion Forum


Old Forum
Install Programs More Downloads...
Troubleshooting
Source Code
Format Specs.
Misc. Information
Non-SF Stuff
Links




ShadowFlare [Tue, 5 Jan 2010 13:00:57 +0000 (06:00 -0700)]
SComp.cpp
SComp.h

index f02fea6..19b47a9 100644 (file)
--- a/SComp.cpp
+++ b/SComp.cpp
@@ -92,6 +92,25 @@ typedef struct {
 unsigned int FillInput(char *lpvBuffer, unsigned int *lpdwSize, void *param);
 void FillOutput(char *lpvBuffer, unsigned int *lpdwSize, void *param);
 
+const unsigned int UNSUPPORTED_COMPRESSION   = (0xFF ^ (0x40 | 0x80 | 0x01
+#ifdef USE_ZLIB
+       | 0x02
+#endif
+       | 0x08
+#ifdef USE_BZIP2
+       | 0x10
+#endif
+       ));
+const unsigned int UNSUPPORTED_DECOMPRESSION = (0xFF ^ (0x40 | 0x80 | 0x01
+#ifdef USE_ZLIB
+       | 0x02
+#endif
+       | 0x08
+#ifdef USE_BZIP2
+       | 0x10
+#endif
+       ));
+
 CompressFunc CompressionFunctions[] =
 {
        {0x40, CompressWaveMono},
diff --git a/SComp.h b/SComp.h
index 37a8e93..dd5d53f 100644 (file)
--- a/SComp.h
+++ b/SComp.h
@@ -14,6 +14,9 @@
 extern "C" {
 #endif
 
+extern const unsigned int UNSUPPORTED_COMPRESSION;
+extern const unsigned int UNSUPPORTED_DECOMPRESSION;
+
 BOOL WINAPI SCompCompress(LPVOID lpvDestinationMem, LPDWORD lpdwCompressedSize, LPVOID lpvSourceMem, DWORD dwDecompressedSize, DWORD dwCompressionType, DWORD dwCompressionSubType, DWORD dwCompressLevel);
 BOOL WINAPI SCompDecompress(LPVOID lpvDestinationMem, LPDWORD lpdwDecompressedSize, LPVOID lpvSourceMem, DWORD dwCompressedSize);