aboutsummaryrefslogtreecommitdiff
path: root/externals/libmpq/doc/man3/libmpq.3
blob: 768dab0a712b4f95f5c886109992a36888486a8e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
.\" Copyright (c) 2003-2008 Maik Broemme <mbroemme@plusserver.de>
.\"
.\" This is free documentation; you can redistribute it and/or
.\" modify it under the terms of the GNU General Public License as
.\" published by the Free Software Foundation; either version 2 of
.\" the License, or (at your option) any later version.
.\"
.\" The GNU General Public License's references to "object code"
.\" and "executables" are to be interpreted as the output of any
.\" document formatting or typesetting system, including
.\" intermediate and printed output.
.\"
.\" This manual is distributed in the hope that it will be useful,
.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
.\" GNU General Public License for more details.
.\"
.\" You should have received a copy of the GNU General Public
.\" License along with this manual; if not, write to the Free
.\" Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111,
.\" USA.
.TH libmpq 3 2008-04-29 "The MoPaQ archive library"
.SH NAME
libmpq \- cross-platform C library for manipulating mpq archives.
.SH SYNOPSIS
.nf
.B
#include <mpq.h>
.sp
.BI "const char *libmpq__version();"
.sp
.BI "const char *libmpq__strerror(int32_t returncode);"
.sp
.BI "int32_t libmpq__archive_open("
.BI "        mpq_archive_s **" "mpq_archive",
.BI "        const char     *" "mpq_filename",
.BI "        off_t           " "archive_offset"
.BI ");"
.sp
.BI "int32_t libmpq__archive_close("
.BI "        mpq_archive_s  *" "mpq_archive"
.BI ");"
.sp
.BI "int32_t libmpq__archive_packed_size("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        off_t          *" "packed_size"
.BI ");"
.sp
.BI "int32_t libmpq__archive_unpacked_size("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        off_t          *" "unpacked_size"
.BI ");"
.sp
.BI "int32_t libmpq__archive_offset("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        off_t          *" "offset"
.BI ");"
.sp
.BI "int32_t libmpq__archive_version("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t       *" "version"
.BI ");"
.sp
.BI "int32_t libmpq__archive_files("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t       *" "files"
.BI ");"
.sp
.BI "int32_t libmpq__file_packed_size("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "packed_size"
.BI ");"
.sp
.BI "int32_t libmpq__file_unpacked_size("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "unpacked_size"
.BI ");"
.sp
.BI "int32_t libmpq__file_offset("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "offset"
.BI ");"
.sp
.BI "int32_t libmpq__file_blocks("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "blocks"
.BI ");"
.sp
.BI "int32_t libmpq__file_encrypted("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "encrypted"
.BI ");"
.sp
.BI "int32_t libmpq__file_compressed("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "compressed"
.BI ");"
.sp
.BI "int32_t libmpq__file_imploded("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        off_t          *" "imploded"
.BI ");"
.sp
.BI "int32_t libmpq__file_number("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        const char     *" "filename",
.BI "        uint32_t       *" "number"
.BI ");"
.sp
.BI "int32_t libmpq__file_read("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        uint8_t        *" "out_buf",
.BI "        off_t           " "out_size",
.BI "        off_t          *" "transferred"
.BI ");"
.sp
.BI "int32_t libmpq__block_open_offset("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number"
.BI ");"
.sp
.BI "int32_t libmpq__block_close_offset("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number"
.BI ");"
.sp
.BI "int32_t libmpq__block_packed_size("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        uint32_t        " "block_number",
.BI "        off_t          *" "packed_size"
.BI ");"
.sp
.BI "int32_t libmpq__block_unpacked_size("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        uint32_t        " "block_number",
.BI "        off_t          *" "unpacked_size"
.BI ");"
.sp
.BI "int32_t libmpq__block_offset("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        uint32_t        " "block_number",
.BI "        off_t          *" "offset"
.BI ");"
.sp
.BI "int32_t libmpq__block_seed("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        uint32_t        " "block_number",
.BI "        uint32_t       *" "seed"
.BI ");"
.sp
.BI "int32_t libmpq__block_read("
.BI "        mpq_archive_s  *" "mpq_archive",
.BI "        uint32_t        " "file_number",
.BI "        uint32_t        " "block_number",
.BI "        uint8_t        *" "out_buf",
.BI "        off_t           " "out_size",
.BI "        off_t          *" "transferred"
.BI ");"
.fi
.SH DESCRIPTION
.PP
The \fIlibmpq\fP library supports decrypting, decompressing, exploding and various manipulations of the MoPaQ archive files. It uses \fIzlib(3)\fP and \fIbzip2(1)\fP compression library. At this moment \fIlibmpq\fP is not able to create MoPaQ archives, this limitation will be removed in a future version.
.SH SEE ALSO
.BR libmpq__version (3),
.BR libmpq__strerror (3),
.BR libmpq__archive_open (3),
.BR libmpq__archive_close (3),
.BR libmpq__archive_packed_size (3),
.BR libmpq__archive_unpacked_size (3),
.BR libmpq__archive_offset (3),
.BR libmpq__archive_version (3),
.BR libmpq__archive_files (3),
.BR libmpq__file_packed_size (3),
.BR libmpq__file_unpacked_size (3),
.BR libmpq__file_offset (3),
.BR libmpq__file_blocks (3),
.BR libmpq__file_encrypted (3),
.BR libmpq__file_compressed (3),
.BR libmpq__file_imploded (3),
.BR libmpq__file_number (3),
.BR libmpq__file_read (3),
.BR libmpq__block_open_offset (3),
.BR libmpq__block_close_offset (3),
.BR libmpq__block_packed_size (3),
.BR libmpq__block_unpacked_size (3),
.BR libmpq__block_offset (3),
.BR libmpq__block_seed (3),
.BR libmpq__block_read (3)
.SH AUTHOR
Check documentation.
.TP
libmpq is (c) 2003-2008
.B Maik Broemme <mbroemme@plusserver.de>
.PP
The above e-mail address can be used to send bug reports, feedbacks or library enhancements.