ScummVM API documentation
tag_file.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  * Copyright 2020 Google
21  *
22  */
23 
24 #ifndef HADESCH_TAG_FILE_H
25 #define HADESCH_TAG_FILE_H
26 
27 #include "common/array.h"
28 
29 namespace Common {
30  class File;
31  class SeekableReadStream;
32 }
33 
34 namespace Hadesch {
35 
36 class TagFile {
37 public:
38 
39  bool openStoreCel(const Common::SharedPtr<Common::SeekableReadStream> &parentstream);
40  bool openStoreHot(const Common::SharedPtr<Common::SeekableReadStream> &parentstream);
41  bool openStoreHotSub(const Common::SharedPtr<Common::SeekableReadStream> &parentstream);
42 
43  Common::SeekableReadStream *getFileStream(uint32 name, int idx = 0);
44 
45 private:
46  bool openStoreReal(const Common::SharedPtr<Common::SeekableReadStream> &parentstream, uint32 offset,
47  int32 len, bool isLittleEndian, bool sizeIncludesHeader);
48 
49  struct Description {
50  uint32 name;
51  uint32 offset;
52  uint32 size;
53  };
55  Common::Array<Description> _descriptions;
56 };
57 
58 } // End of namespace Hadesch
59 
60 #endif
Definition: ambient.h:30
Definition: stream.h:745
Definition: algorithm.h:29
Definition: tag_file.h:36