From 4a4ccfc65fb0da7431751c2ab2828f81b8c0701a Mon Sep 17 00:00:00 2001 From: David Capello Date: Mon, 17 Aug 2009 21:44:55 +0000 Subject: [PATCH] Removed local unused function 'layer_get_pos'. --- src/modules/sprites.cpp | 50 ----------------------------------------- 1 file changed, 50 deletions(-) diff --git a/src/modules/sprites.cpp b/src/modules/sprites.cpp index 6541002ab..4e42d07a1 100644 --- a/src/modules/sprites.cpp +++ b/src/modules/sprites.cpp @@ -34,9 +34,6 @@ #include "util/misc.h" static ImageRef *images_ref_get_from_layer(Sprite* sprite, Layer *layer, int target, bool write); -static void layer_get_pos(Sprite* sprite, Layer *layer, int target, bool write, int **x, int **y, int *count); - -////////////////////////////////////////////////////////////////////// ImageRef *images_ref_get_from_sprite(Sprite* sprite, int target, bool write) { @@ -131,50 +128,3 @@ static ImageRef *images_ref_get_from_layer(Sprite* sprite, Layer *layer, int tar return first_image; } - -static void layer_get_pos(Sprite* sprite, Layer *layer, int target, bool write, int **x, int **y, int *count) -{ - int frame = sprite->frame; - - if (!layer_is_readable(layer)) - return; - - if (write && !layer_is_writable(layer)) - return; - - switch (layer->type) { - - case GFXOBJ_LAYER_IMAGE: { - Image *image; - int u, v; - - if (target & TARGET_ALL_FRAMES) { - for (frame=0; frameframes; frame++) { - image = GetLayerImage(layer, &u, &v, frame); - if (image) { - (*x)[*count] = u; - (*y)[*count] = v; - (*count)++; - } - } - } - else { - image = GetLayerImage(layer, &u, &v, frame); - if (image) { - (*x)[*count] = u; - (*y)[*count] = v; - (*count)++; - } - } - break; - } - - case GFXOBJ_LAYER_SET: { - JLink link; - JI_LIST_FOR_EACH(layer->layers, link) - layer_get_pos(sprite, reinterpret_cast(link->data), target, write, x, y, count); - break; - } - - } -}