Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1 | pmbaty | 1 | /* |
2 | * This file is part of the DXX-Rebirth project <https://www.dxx-rebirth.com/>. |
||
3 | * It is copyright by its individual contributors, as recorded in the |
||
4 | * project's Git history. See COPYING.txt at the top level for license |
||
5 | * terms and a link to the Git history. |
||
6 | */ |
||
7 | #ifndef _LIBMVE_H |
||
8 | #define _LIBMVE_H |
||
9 | |||
10 | #define MVE_ERR_EOF 1 |
||
11 | |||
12 | #ifdef __cplusplus |
||
13 | #include <memory> |
||
14 | |||
15 | enum class MVE_StepStatus |
||
16 | { |
||
17 | Continue = 0, |
||
18 | EndOfFile = 1, |
||
19 | }; |
||
20 | |||
21 | struct MVESTREAM; |
||
22 | |||
23 | struct MVE_videoSpec { |
||
24 | int screenWidth; |
||
25 | int screenHeight; |
||
26 | int width; |
||
27 | int height; |
||
28 | int truecolor; |
||
29 | }; |
||
30 | |||
31 | MVE_StepStatus MVE_rmStepMovie(MVESTREAM &mve); |
||
32 | void MVE_rmHoldMovie(); |
||
33 | void MVE_rmEndMovie(std::unique_ptr<MVESTREAM> mve); |
||
34 | |||
35 | void MVE_getVideoSpec(MVE_videoSpec *vSpec); |
||
36 | |||
37 | void MVE_sndInit(int x); |
||
38 | |||
39 | typedef unsigned int (*mve_cb_Read)(void *stream, |
||
40 | void *buffer, |
||
41 | unsigned int count); |
||
42 | |||
43 | typedef void *(*mve_cb_Alloc)(size_t size); |
||
44 | typedef void (*mve_cb_Free)(void *ptr); |
||
45 | |||
46 | typedef void (*mve_cb_ShowFrame)(unsigned char *buffer, int dstx, int dsty, int bufw, int bufh, int sw, int sh); |
||
47 | |||
48 | typedef void (*mve_cb_SetPalette)(const unsigned char *p, |
||
49 | unsigned int start, unsigned int count); |
||
50 | |||
51 | void MVE_ioCallbacks(mve_cb_Read io_read); |
||
52 | void MVE_memCallbacks(mve_cb_Alloc mem_alloc, mve_cb_Free mem_free); |
||
53 | void MVE_sfCallbacks(mve_cb_ShowFrame showframe); |
||
54 | void MVE_palCallbacks(mve_cb_SetPalette setpalette); |
||
55 | |||
56 | #endif |
||
57 | |||
58 | #endif /* _LIBMVE_H */ |