ScummVM API documentation
actor_renderer.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 HOLLYWOOD_MONSTERS_GAMEPLAY_ACTOR_RENDERER_H
23#define HOLLYWOOD_MONSTERS_GAMEPLAY_ACTOR_RENDERER_H
24
25#include "common/array.h"
26#include "common/types.h"
27
28namespace Graphics {
29struct Surface;
30}
31
32namespace Hollywood {
33
34// Full-body actor cels use this bank; speech overlays are separate resources
35// that callers composite over the body.
37 uint32 runStreamOffset;
38 uint32 opaqueRunCount;
39 uint32 paletteRunCount;
40 int16 anchorX;
41 int16 anchorY;
42 uint16 width;
43 uint16 height;
44};
45
47 Common::Array<byte> runStreams;
49};
50
52 bool enabled;
53 int actorWorldY;
54 const Graphics::Surface *savedFramebuffer;
55 const Common::Array<byte> *colorToDepthClassMap;
56 const Common::Array<uint16> *depthYThresholds;
57};
58
59int drawActorRunStream(const Common::Array<byte> &runStreams, uint cursor, uint runBase, uint runCount,
60 int spriteX, int spriteY, int minimumYExclusive, Graphics::Surface &destination,
61 const ActorDepthTest *depthTest, uint *nextCursor = nullptr);
62uint skipActorRunStream(const Common::Array<byte> &runStreams, uint cursor, uint runBase, uint runCount);
63int drawActorPaletteRemapRunStream(const Common::Array<byte> &runStreams, uint cursor, uint runBase, uint runCount,
64 int spriteX, int spriteY, int minimumYExclusive, Graphics::Surface &destination,
65 const Common::Array<byte> &paletteRemapTable, const ActorDepthTest *depthTest);
66void drawActorSpriteFrame(const ActorSpriteBank &bank, byte facing, byte cel, int worldX, int worldY,
67 int minimumYExclusive, Graphics::Surface &destination, const Common::Array<byte> &paletteRemapTable,
68 const ActorDepthTest *depthTest = nullptr);
69void buildPresentationPaletteRemapTable(const Common::Array<byte> &palette, Common::Array<byte> &paletteRemapTable);
70
71} // End of namespace Hollywood
72
73#endif // HOLLYWOOD_MONSTERS_GAMEPLAY_ACTOR_RENDERER_H
Definition: formatinfo.h:28
Definition: surface.h:67
Definition: actor_renderer.h:51
Definition: actor_renderer.h:46
Definition: actor_renderer.h:36