annotate unrarlib.h @ 19382:7c6c205b88b6

trying to fix the reverting paragraph if you dissagree, dont hesitate to revert this commit or flame, but at least we should not claim that svn cannot revert commits except by recommiting the old version
author michael
date Sun, 13 Aug 2006 22:14:32 +0000
parents 0783dd397f74
children 6c48183dcf8b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7446
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
1 /* ***************************************************************************
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
2 **
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
3 ** This file is part of the UniquE RAR File Library.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
4 **
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
5 ** Copyright (C) 2000-2002 by Christian Scheurer (www.ChristianScheurer.ch)
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
6 ** UNIX port copyright (c) 2000-2002 by Johannes Winkelmann (jw@tks6.net)
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
7 **
18783
0783dd397f74 CVS --> Subversion in copyright notices
diego
parents: 15165
diff changeset
8 ** Modified for use with MPlayer, detailed changelog at
0783dd397f74 CVS --> Subversion in copyright notices
diego
parents: 15165
diff changeset
9 ** http://svn.mplayerhq.hu/mplayer/trunk/
15165
775330fe3889 Mark unrarlib imported files as changed to comply with GPL ¡ø2a.
diego
parents: 11000
diff changeset
10 ** $Id$
775330fe3889 Mark unrarlib imported files as changed to comply with GPL ¡ø2a.
diego
parents: 11000
diff changeset
11 **
7446
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
12 ** The contents of this file are subject to the UniquE RAR File Library
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
13 ** License (the "unrarlib-license.txt"). You may not use this file except
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
14 ** in compliance with the License. You may obtain a copy of the License
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
15 ** at http://www.unrarlib.org/license.html.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
16 ** Software distributed under the License is distributed on an "AS IS"
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
17 ** basis, WITHOUT WARRANTY OF ANY KIND, either express or implied warranty.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
18 **
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
19 ** Alternatively, the contents of this file may be used under the terms
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
20 ** of the GNU General Public License Version 2 or later (the "GPL"), in
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
21 ** which case the provisions of the GPL are applicable instead of those
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
22 ** above. If you wish to allow use of your version of this file only
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
23 ** under the terms of the GPL and not to allow others to use your version
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
24 ** of this file under the terms of the UniquE RAR File Library License,
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
25 ** indicate your decision by deleting the provisions above and replace
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
26 ** them with the notice and other provisions required by the GPL. If you
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
27 ** do not delete the provisions above, a recipient may use your version
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
28 ** of this file under the terms of the GPL or the UniquE RAR File Library
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
29 ** License.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
30 **
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
31 ************************************************************************** */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
32
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
33 /* include file for the "UniquE RAR File Library" */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
34 /* (C) 2000-2002 by Christian Scheurer aka. UniquE */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
35 /* multi-OS version (Win32, Linux and SUN) */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
36
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
37 #ifndef __URARLIB_H
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
38 #define __URARLIB_H
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
39
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
40 #ifdef __cplusplus
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
41 extern "C"
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
42 {
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
43 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
44
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
45
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
46 /* ************************************************************************ */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
47 /* ************************************************************************ */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
48 /* ** ** */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
49 /* ** CONFIGURATION of the UniquE RAR FileLib ** */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
50 /* ** ==> you may change the setting for the lib HERE! ** */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
51 /* ** ** */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
52 /* ************************************************************************ */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
53 /* ************************************************************************ */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
54
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
55
8053
e550de4bd477 disabled DEBUG_LOG, noticed by Bernd Ernesti <mplayer@lists.veego.de>
alex
parents: 7446
diff changeset
56 /*#define _DEBUG_LOG*/ /* generate debug messages */
7446
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
57
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
58 #define _DO_CRC32_CHECK /* perform cyclical redundancy */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
59 /* check (CRC32) - disable this */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
60 /* for a little speed-up */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
61 /*#define _USE_ASM*/ /*
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
62 * enable assembly extensions
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
63 * x86 cpus.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
64 */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
65
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
66 /*#define _USE_MEMORY_TO_MEMORY_DECOMPRESSION*/ /* read file from memory or a */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
67 /* resource instead of reading */
11000
6e35326c742f many small typo and grammar fixes
gabucino
parents: 8053
diff changeset
68 /* from a file. NOTE: you won't */
7446
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
69 /* be able to decompress from */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
70 /* file if you enable this */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
71 /* option! */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
72
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
73
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
74 #ifdef WIN32 /* autodetect Win32 and Linux */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
75 #define _WIN_32 /* Win32 with VisualC */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
76 #define _DEBUG_LOG_FILE "C:\\temp\\debug_unrar.txt" /* log file path */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
77 #else
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
78 #define _UNIX /* Linux or Unix with GCC */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
79 #define _DEBUG_LOG_FILE "/tmp/debug_unrar.txt" /* log file path */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
80 /*#define NON_INTEL_BYTE_ORDER*/ /* GCC on motorola systems */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
81
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
82 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
83
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
84 /* ------------------------------------------------------------------------ */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
85
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
86
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
87
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
88 /* -- global type definitions --------------------------------------------- */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
89
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
90 #ifdef NON_INTEL_BYTE_ORDER
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
91 #ifdef _USE_ASM
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
92 #warning Disabling assembly because NON_INTEL_BYTE_ORDER is set
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
93 #undef _USE_ASM
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
94 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
95 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
96
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
97 #ifdef _WIN_32
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
98 typedef unsigned char UBYTE; /* WIN32 definitions */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
99 typedef unsigned short UWORD;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
100 typedef unsigned long UDWORD;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
101 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
102
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
103 #ifdef _UNIX /* LINUX/UNIX definitions */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
104 typedef unsigned char UBYTE;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
105 typedef unsigned short UWORD;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
106 typedef unsigned long UDWORD;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
107 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
108
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
109
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
110 /* This structure is used for listing archive content */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
111 struct RAR20_archive_entry /* These infos about files are */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
112 { /* stored in RAR v2.0 archives */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
113 char *Name;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
114 UWORD NameSize;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
115 UDWORD PackSize;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
116 UDWORD UnpSize;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
117 UBYTE HostOS; /* MSDOS=0,OS2=1,WIN32=2,UNIX=3 */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
118 UDWORD FileCRC;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
119 UDWORD FileTime;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
120 UBYTE UnpVer;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
121 UBYTE Method;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
122 UDWORD FileAttr;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
123 };
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
124
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
125 typedef struct archivelist /* used to list archives */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
126 {
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
127 struct RAR20_archive_entry item;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
128 struct archivelist *next;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
129 } ArchiveList_struct;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
130
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
131
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
132 #ifdef _USE_MEMORY_TO_MEMORY_DECOMPRESSION
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
133 typedef struct memory_file /* used to decompress files in */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
134 { /* memory */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
135 void *data; /* pointer to the file data */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
136 unsigned long size; /* total size of the file data */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
137 unsigned long offset; /* offset within "memory-file" */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
138 } MemoryFile;
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
139 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
140
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
141 /* -- global functions ---------------------------------------------------- */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
142
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
143 /* urarlib_get:
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
144 * decompresses and decrypt data from a RAR file to a buffer in system memory.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
145 *
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
146 * input: *output pointer to an empty char*. This pointer will show
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
147 * to the extracted data
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
148 * *size shows where to write the size of the decompressed
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
149 * file
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
150 * (**NOTE: URARLib _does_ memory allocation etc.!**)
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
151 * *filename pointer to string containing the file to decompress
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
152 * *rarfile pointer to a string with the full name and path of
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
153 * the RAR file or pointer to a RAR file in memory if
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
154 * memory-to-memory decompression is active.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
155 * *libpassword pointer to a string with the password used to
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
156 * en-/decrypt the RAR
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
157 * output: int returns TRUE on success or FALSE on error
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
158 * (FALSE=0, TRUE=1)
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
159 */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
160
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
161 extern int urarlib_get(void *output,
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
162 unsigned long *size,
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
163 char *filename,
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
164 void *rarfile,
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
165 char *libpassword);
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
166
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
167
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
168
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
169 /* urarlib_list:
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
170 * list the content of a RAR archive.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
171 *
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
172 * input: *rarfile pointer to a string with the full name and path of
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
173 * the RAR file or pointer to a RAR file in memory if
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
174 * memory-to-memory decompression is active.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
175 * *list pointer to an ArchiveList_struct that can be
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
176 * filled with details about the archive
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
177 * to the extracted data
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
178 * output: int number of files/directories within archive
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
179 */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
180
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
181 extern int urarlib_list(void *rarfile, ArchiveList_struct *list);
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
182
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
183
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
184 /* urarlib_freelist:
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
185 * (after the suggestion and code of Duy Nguyen, Sean O'Blarney
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
186 * and Johannes Winkelmann who independently wrote a patch)
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
187 * free the memory of a ArchiveList_struct created by urarlib_list.
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
188 *
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
189 * input: *list pointer to an ArchiveList_struct
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
190 * output: -
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
191 */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
192
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
193 extern void urarlib_freelist(ArchiveList_struct *list);
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
194
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
195 /* ------------------------------------------------------------------------ */
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
196
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
197
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
198
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
199 #ifdef __cplusplus
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
200 };
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
201 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
202
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
203 #endif
ad00ad5f25a9 Automatic unrar of vobsub. Does not work with rar v3
kmkaplan
parents:
diff changeset
204