summaryrefslogtreecommitdiff
path: root/libavfilter
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-03-05 15:52:00 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-03-05 16:00:44 +0100
commit7ccc5848248ba0d4adfa381cf93b0d7b752d9d32 (patch)
tree5a935612c5fa155a1f2539c055b8086cd3ef6945 /libavfilter
parent6d7e57e88b7505029f3a96b5d159fc34fce02858 (diff)
avfilter/vf_paletteuse: Use int where AVERROR can be returned
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavfilter')
-rw-r--r--libavfilter/vf_paletteuse.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libavfilter/vf_paletteuse.c b/libavfilter/vf_paletteuse.c
index cba0eb34c2..75e3118b26 100644
--- a/libavfilter/vf_paletteuse.c
+++ b/libavfilter/vf_paletteuse.c
@@ -316,7 +316,7 @@ end:
* Note: r, g, and b are the component of c but are passed as well to avoid
* recomputing them (they are generally computed by the caller for other uses).
*/
-static av_always_inline uint8_t color_get(struct cache_node *cache, uint32_t color,
+static av_always_inline int color_get(struct cache_node *cache, uint32_t color,
uint8_t r, uint8_t g, uint8_t b,
const struct color_node *map,
const uint32_t *palette,
@@ -346,7 +346,7 @@ static av_always_inline uint8_t color_get(struct cache_node *cache, uint32_t col
return e->pal_entry;
}
-static av_always_inline uint8_t get_dst_color_err(struct cache_node *cache,
+static av_always_inline int get_dst_color_err(struct cache_node *cache,
uint32_t c, const struct color_node *map,
const uint32_t *palette,
int *er, int *eg, int *eb,
@@ -355,7 +355,7 @@ static av_always_inline uint8_t get_dst_color_err(struct cache_node *cache,
const uint8_t r = c >> 16 & 0xff;
const uint8_t g = c >> 8 & 0xff;
const uint8_t b = c & 0xff;
- const uint8_t dstx = color_get(cache, c, r, g, b, map, palette, search_method);
+ const int dstx = color_get(cache, c, r, g, b, map, palette, search_method);
const uint32_t dstc = palette[dstx];
*er = r - (dstc >> 16 & 0xff);
*eg = g - (dstc >> 8 & 0xff);