aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/gfx/resource
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sci/gfx/resource')
-rw-r--r--engines/sci/gfx/resource/sci_cursor_0.cpp3
-rw-r--r--engines/sci/gfx/resource/sci_font.cpp3
-rw-r--r--engines/sci/gfx/resource/sci_pal_1.cpp4
-rw-r--r--engines/sci/gfx/resource/sci_pic_0.cpp12
-rw-r--r--engines/sci/gfx/resource/sci_picfill.cpp4
-rw-r--r--engines/sci/gfx/resource/sci_picfill_aux.cpp4
-rw-r--r--engines/sci/gfx/resource/sci_resmgr.cpp4
-rw-r--r--engines/sci/gfx/resource/sci_view_0.cpp4
-rw-r--r--engines/sci/gfx/resource/sci_view_1.cpp4
9 files changed, 41 insertions, 1 deletions
diff --git a/engines/sci/gfx/resource/sci_cursor_0.cpp b/engines/sci/gfx/resource/sci_cursor_0.cpp
index e95b9cff68..aa60fb4b7d 100644
--- a/engines/sci/gfx/resource/sci_cursor_0.cpp
+++ b/engines/sci/gfx/resource/sci_cursor_0.cpp
@@ -27,6 +27,7 @@
#include "sci/include/gfx_resource.h"
#include "sci/include/gfx_tools.h"
+namespace Sci {
#define CURSOR_RESOURCE_SIZE 68
#define CURSOR_SIZE 16
@@ -93,3 +94,5 @@ gfx_pixmap_t *gfxr_draw_cursor0(int id, byte *resource, int size) {
gfx_pixmap_t *gfxr_draw_cursor01(int id, byte *resource, int size) {
return _gfxr_draw_cursor(id, resource, size, 1);
}
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_font.cpp b/engines/sci/gfx/resource/sci_font.cpp
index 6a9c40f332..8b1eb4b8b2 100644
--- a/engines/sci/gfx/resource/sci_font.cpp
+++ b/engines/sci/gfx/resource/sci_font.cpp
@@ -28,6 +28,7 @@
#include "sci/include/gfx_resource.h"
#include "sci/include/gfx_tools.h"
+namespace Sci {
extern int font_counter;
@@ -137,3 +138,5 @@ gfx_bitmap_font_t *gfxr_read_font(int id, byte *resource, int size) {
return font;
}
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_pal_1.cpp b/engines/sci/gfx/resource/sci_pal_1.cpp
index b344ee355f..6ba33b5ae7 100644
--- a/engines/sci/gfx/resource/sci_pal_1.cpp
+++ b/engines/sci/gfx/resource/sci_pal_1.cpp
@@ -29,6 +29,8 @@
#include "sci/include/gfx_system.h"
#include "sci/include/gfx_resource.h"
+namespace Sci {
+
#define MAX_COLORS 256
#define PALETTE_START 260
#define COLOR_OK 0x01
@@ -157,3 +159,5 @@ gfx_pixmap_color_t *gfxr_read_pal1_amiga(int *colors_nr, FILE *f) {
return retval;
}
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_pic_0.cpp b/engines/sci/gfx/resource/sci_pic_0.cpp
index cfe60a585b..665ebf7314 100644
--- a/engines/sci/gfx/resource/sci_pic_0.cpp
+++ b/engines/sci/gfx/resource/sci_pic_0.cpp
@@ -28,6 +28,8 @@
#include "sci/include/gfx_resource.h"
#include "sci/include/gfx_tools.h"
+namespace Sci {
+
#undef GFXR_DEBUG_PIC0 /* Enable to debug pic0 messages */
#undef FILL_RECURSIVE_DEBUG /* Enable for verbose fill debugging */
@@ -1204,6 +1206,8 @@ _gfxr_find_fill_point(gfxr_pic_t *pic, int min_x, int min_y, int max_x, int max_
#undef TEST_POINT
+} // End of namespace Sci
+
/* Now include the actual filling code (with scaling support) */
#define FILL_FUNCTION _gfxr_fill_any
#define FILL_FUNCTION_RECURSIVE _gfxr_fill_any_recursive
@@ -1218,8 +1222,12 @@ _gfxr_find_fill_point(gfxr_pic_t *pic, int min_x, int min_y, int max_x, int max_
#undef FILL_FUNCTION_RECURSIVE
#undef FILL_FUNCTION
-#endif /* defined(WITH_PIC_SCALING) */
+namespace Sci {
+#endif /* defined(WITH_PIC_SCALING) */
+
+} // End of namespace Sci
+
/* Include again, but this time without support for scaling */
#define FILL_FUNCTION _gfxr_fill_1
#define FILL_FUNCTION_RECURSIVE _gfxr_fill_1_recursive
@@ -1232,6 +1240,7 @@ _gfxr_find_fill_point(gfxr_pic_t *pic, int min_x, int min_y, int max_x, int max_
#undef FILL_FUNCTION_RECURSIVE
#undef FILL_FUNCTION
+namespace Sci {
#define GET_ABS_COORDS(x, y) \
temp = *(resource + pos++); \
@@ -1999,3 +2008,4 @@ gfxr_dither_pic0(gfxr_pic_t *pic, int dmode, int pattern) {
}
}
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_picfill.cpp b/engines/sci/gfx/resource/sci_picfill.cpp
index 325ec1c646..669c30ee8e 100644
--- a/engines/sci/gfx/resource/sci_picfill.cpp
+++ b/engines/sci/gfx/resource/sci_picfill.cpp
@@ -25,6 +25,8 @@
#include "sci/include/gfx_resource.h"
+namespace Sci {
+
/* Generic pic filling code, to be included by sci_pic_0.c
*
*
@@ -416,3 +418,5 @@ static void FILL_FUNCTION(gfxr_pic_t *pic, int x_320, int y_200, int color, int
# undef proj_xl_bound
# undef proj_xr_bound
#endif
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_picfill_aux.cpp b/engines/sci/gfx/resource/sci_picfill_aux.cpp
index 1760d233c8..f7deff27fa 100644
--- a/engines/sci/gfx/resource/sci_picfill_aux.cpp
+++ b/engines/sci/gfx/resource/sci_picfill_aux.cpp
@@ -35,6 +35,8 @@
*
*/
+namespace Sci {
+
#define CLIPMASK_HARD_BOUND 0x80 /* ensures that we don't re-fill filled stuff */
static void AUXBUF_FILL_HELPER(gfxr_pic_t *pic, int old_xl, int old_xr, int y, int dy,
@@ -209,3 +211,5 @@ static void AUXBUF_FILL(gfxr_pic_t *pic, int x, int y, int clipmask, int control
#undef CLIPMASK_HARD_BOUND
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_resmgr.cpp b/engines/sci/gfx/resource/sci_resmgr.cpp
index f66ecec332..a82ff3c979 100644
--- a/engines/sci/gfx/resource/sci_resmgr.cpp
+++ b/engines/sci/gfx/resource/sci_resmgr.cpp
@@ -33,6 +33,8 @@
#include "common/util.h"
+namespace Sci {
+
int gfxr_interpreter_options_hash(gfx_resource_type_t type, int version, gfx_options_t *options, void *internal, int palette) {
switch (type) {
case GFX_RESOURCE_TYPE_VIEW:
@@ -292,3 +294,5 @@ gfx_pixmap_color_t *gfxr_interpreter_get_palette(gfx_resstate_t *state, int vers
int gfxr_interpreter_needs_multicolored_pointers(int version, void *internal) {
return (version > SCI_VERSION_1);
}
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_view_0.cpp b/engines/sci/gfx/resource/sci_view_0.cpp
index 82b3e5d9d2..437733328e 100644
--- a/engines/sci/gfx/resource/sci_view_0.cpp
+++ b/engines/sci/gfx/resource/sci_view_0.cpp
@@ -28,6 +28,8 @@
#include "sci/include/gfx_resource.h"
#include "sci/include/gfx_tools.h"
+namespace Sci {
+
gfx_pixmap_t *gfxr_draw_cel0(int id, int loop, int cel, byte *resource, int size, gfxr_view_t *view, int mirrored) {
int xl = get_int_16(resource);
int yl = get_int_16(resource + 2);
@@ -226,3 +228,5 @@ gfxr_view_t *gfxr_draw_view0(int id, byte *resource, int size, int palette) {
return view;
}
+
+} // End of namespace Sci
diff --git a/engines/sci/gfx/resource/sci_view_1.cpp b/engines/sci/gfx/resource/sci_view_1.cpp
index ce038c11da..a268cba1dd 100644
--- a/engines/sci/gfx/resource/sci_view_1.cpp
+++ b/engines/sci/gfx/resource/sci_view_1.cpp
@@ -30,6 +30,8 @@
#include "sci/include/gfx_resource.h"
#include "sci/include/gfx_tools.h"
+namespace Sci {
+
#define V1_LOOPS_NR_OFFSET 0
#define V1_MIRROR_MASK 2
#define V1_PALETTE_OFFSET 6
@@ -516,3 +518,5 @@ gfxr_view_t *gfxr_draw_view11(int id, byte *resource, int size) {
return view;
}
+
+} // End of namespace Sci