ScummVM API documentation
animation.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 */
21
22#ifndef TOLTECS_ANIMATION_H
23#define TOLTECS_ANIMATION_H
24
25#include "toltecs/toltecs.h"
26#include "toltecs/resource.h"
27
28namespace Toltecs {
29
31public:
34
35 void start(uint resIndex);
36 void nextFrame();
37 int16 getStatus();
38 uint16 getFrameNumber() const { return _frameNumber; }
39
40 void saveState(Common::WriteStream *out);
41 void loadState(Common::ReadStream *in);
42
43//protected:
44public:
45 ToltecsEngine *_vm;
46
47 // 262144
48 byte *_animBuffer;
49
50 uint16 _resIndex;
51
52 uint16 _width, _height;
53 uint16 _frameNumber, _frameCount;
54 uint32 _keepFrameCounter;
55
56 uint32 _curFrameSize;
57 uint32 _nextFrameSize, _nextFrameOffset;
58
59 uint32 _firstNextFrameOffset, _firstCurFrameSize, _firstNextFrameSize;
60
61 void unpackFrame();
62
63};
64
65} // End of namespace Toltecs
66
67#endif /* TOLTECS_ANIMATION_H */
Definition: stream.h:385
Definition: stream.h:77
Definition: animation.h:30
Definition: toltecs.h:104