mxwcore-wotlk/deps/libmpq/doc/man3/libmpq.3

208 lines
6.7 KiB
Groff

.\" 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.