2 * blenlib/BKE_packedFile.h (mar-2001 nzc)
6 * ***** BEGIN GPL LICENSE BLOCK *****
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * as published by the Free Software Foundation; either version 2
11 * of the License, or (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software Foundation,
20 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
23 * All rights reserved.
25 * The Original Code is: all of this file.
27 * Contributor(s): none yet.
29 * ***** END GPL LICENSE BLOCK *****
31 #ifndef BKE_PACKEDFILE_H
32 #define BKE_PACKEDFILE_H
45 struct PackedFile *newPackedFile(struct ReportList *reports, char *filename);
46 struct PackedFile *newPackedFileMemory(void *mem, int memlen);
48 void packAll(struct Main *bmain, struct ReportList *reports);
51 char *unpackFile(struct ReportList *reports, char *abs_name, char *local_name, struct PackedFile *pf, int how);
52 int unpackVFont(struct ReportList *reports, struct VFont *vfont, int how);
53 int unpackSound(struct ReportList *reports, struct bSound *sound, int how);
54 int unpackImage(struct ReportList *reports, struct Image *ima, int how);
55 void unpackAll(struct Main *bmain, struct ReportList *reports, int how);
57 int writePackedFile(struct ReportList *reports, char *filename, struct PackedFile *pf, int guimode);
60 void freePackedFile(struct PackedFile *pf);
63 int countPackedFiles(struct Main *bmain);
64 int checkPackedFile(char *filename, struct PackedFile *pf);
67 int seekPackedFile(struct PackedFile *pf, int offset, int whence);
68 void rewindPackedFile(struct PackedFile *pf);
69 int readPackedFile(struct PackedFile *pf, void *data, int size);