diff --git a/src/modules/gfx.cpp b/src/modules/gfx.cpp index ddba253ef..8c1d1a2bb 100644 --- a/src/modules/gfx.cpp +++ b/src/modules/gfx.cpp @@ -239,52 +239,6 @@ void simple_dotted_mode(BITMAP* bmp, int fg, int bg) drawing_mode(DRAW_MODE_COPY_PATTERN, pattern, 0, 0); } -/**********************************************************************/ -/* Set/Restore sub-clip regions */ - -struct CLIP_DATA -{ - BITMAP* bmp; - int cl, ct, cr, cb; -}; - -void* subclip(BITMAP* bmp, int x1, int y1, int x2, int y2) -{ - int cl, ct, cr, cb; - CLIP_DATA* data; - - cl = bmp->cl; - ct = bmp->ct; - cr = bmp->cr; - cb = bmp->cb; - - if ((x2 < cl) || (x1 >= cr) || (y2 < ct) || (y1 >= cb)) - return NULL; - - x1 = MID(cl, x1, cr-1); - y1 = MID(ct, y1, cb-1); - x2 = MID(x1, x2, cr-1); - y2 = MID(y1, y2, cb-1); - - set_clip(bmp, x1, y1, x2, y2); - - data = new CLIP_DATA; - data->bmp = bmp; - data->cl = cl; - data->ct = ct; - data->cr = cr; - data->cb = cb; - - return data; -} - -void backclip(void* _data) -{ - CLIP_DATA* data = reinterpret_cast(_data); - set_clip(data->bmp, data->cl, data->ct, data->cr, data->cb); - delete data; -} - /**********************************************************************/ /* Rectangle Tracker (Save/Restore rectangles from/to the screen) */ diff --git a/src/modules/gfx.h b/src/modules/gfx.h index ae70c0d83..13b84f8cc 100644 --- a/src/modules/gfx.h +++ b/src/modules/gfx.h @@ -104,9 +104,6 @@ BITMAP* get_gfx(int id); void dotted_mode(int offset); void simple_dotted_mode(BITMAP* bmp, int fg, int bg); -void *subclip(BITMAP* bmp, int x1, int y1, int x2, int y2); -void backclip(void *data); - RectTracker *rect_tracker_new(BITMAP* bmp, int x1, int y1, int x2, int y2); void rect_tracker_free(RectTracker *tracker);