| 1 | /* |
| 2 | * OpenTyrian: A modern cross-platform port of Tyrian |
| 3 | * Copyright (C) 2007-2009 The OpenTyrian Development Team |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or |
| 6 | * modify it under the terms of the GNU General Public License |
| 7 | * as published by the Free Software Foundation; either version 2 |
| 8 | * of the License, or (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program; if not, write to the Free Software |
| 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
| 18 | */ |
| 19 | #ifndef PALETTE_H |
| 20 | #define PALETTE_Hcxx . . $ `src/palette.h:20:9`! |
| 21 | |
| 22 | #include "opentyr.h"cxx . . $ `<file>/src/opentyr.h`/ |
| 23 | |
| 24 | #include "SDL.h" |
| 25 | |
| 26 | typedef SDL_Colorcxx . . $ SDL_Color# Palettecxx . . $ Palette#[256]; |
| 27 | |
| 28 | extern Palettecxx . . $ Palette# palettescxx . . $ palettes.[]; |
| 29 | extern int palette_countcxx . . $ palette_count.; |
| 30 | |
| 31 | extern Uint32cxx . . $ Uint32# rgb_palettecxx . . $ rgb_palette.[256], yuv_palettecxx . . $ yuv_palette.[256]; |
| 32 | |
| 33 | extern Palettecxx . . $ Palette# colorscxx . . $ colors.; // TODO: get rid of this |
| 34 | |
| 35 | void JE_loadPalscxx . . $ JE_loadPals(49f6e7a06ebc5aa8).(void); |
| 36 | |
| 37 | void set_palettecxx . . $ set_palette(e7c4d2139a064c7f).(Palettecxx . . $ Palette# colors, unsigned int first_color, unsigned int last_color); |
| 38 | void set_colorscxx . . $ set_colors(1ccd9883187beb24).(SDL_Colorcxx . . $ SDL_Color# color, unsigned int first_color, unsigned int last_color); |
| 39 | |
| 40 | void init_step_fade_palettecxx . . $ init_step_fade_palette(78767d3cf152c690).(int diff[256][3], Palettecxx . . $ Palette# colors, unsigned int first_color, unsigned int last_color); |
| 41 | void init_step_fade_solidcxx . . $ init_step_fade_solid(2c3657619c5a01cf).(int diff[256][3], SDL_Colorcxx . . $ SDL_Color# color, unsigned int first_color, unsigned int last_color); |
| 42 | void step_fade_palettecxx . . $ step_fade_palette(ccf0b4adc1b21d7).(int diff[256][3], int steps, unsigned int first_color, unsigned int last_color); |
| 43 | |
| 44 | void fade_palettecxx . . $ fade_palette(59ab901998e00635).(Palettecxx . . $ Palette# colors, int steps, unsigned int first_color, unsigned int last_color); |
| 45 | void fade_solidcxx . . $ fade_solid(e5acc1e0a74570f4).(SDL_Colorcxx . . $ SDL_Color# color, int steps, unsigned int first_color, unsigned int last_color); |
| 46 | |
| 47 | void fade_blackcxx . . $ fade_black(d4f767463ce0a6b3).(int steps); |
| 48 | void fade_whitecxx . . $ fade_white(d4f767463ce0a6b3).(int steps); |
| 49 | |
| 50 | #endif /* PALETTE_H */ |