From: Eric Anholt Date: Mon, 19 Apr 2021 21:57:20 +0000 (-0700) Subject: mesa: Remove dead _mesa_pack_ubyte_rgba_rect(). X-Git-Tag: upstream/21.2.3~4448 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1a36b11a66ac32854adc1a47dd1b587d74ab01e7;p=platform%2Fupstream%2Fmesa.git mesa: Remove dead _mesa_pack_ubyte_rgba_rect(). Unused since 8ec6534b2665 ("mesa: Use _mesa_format_convert to implement texstore_rgba.") in 2014 Reviewed-by: Ian Romanick Reviewed-by: Adam Jackson Part-of: --- diff --git a/src/mesa/main/format_pack.h b/src/mesa/main/format_pack.h index 7fd186b..fce4045 100644 --- a/src/mesa/main/format_pack.h +++ b/src/mesa/main/format_pack.h @@ -52,11 +52,6 @@ _mesa_pack_uint_rgba_row(mesa_format format, uint32_t n, util_format_pack_rgba(format, dst, src, n); } -extern void -_mesa_pack_ubyte_rgba_rect(mesa_format format, uint32_t width, uint32_t height, - const uint8_t *src, int32_t srcRowStride, - void *dst, int32_t dstRowStride); - static inline void _mesa_pack_float_z_row(mesa_format format, uint32_t n, const float *src, void *dst) diff --git a/src/mesa/main/format_pack.py b/src/mesa/main/format_pack.py index 1a8d2f4..c8df4b3 100644 --- a/src/mesa/main/format_pack.py +++ b/src/mesa/main/format_pack.py @@ -189,37 +189,6 @@ _mesa_pack_ubyte_rgba_row(mesa_format format, uint32_t n, } } - -/** - * Pack a 2D image of ubyte RGBA pixels in the given format. - * \param srcRowStride source image row stride in bytes - * \param dstRowStride destination image row stride in bytes - */ -void -_mesa_pack_ubyte_rgba_rect(mesa_format format, uint32_t width, uint32_t height, - const uint8_t *src, int32_t srcRowStride, - void *dst, int32_t dstRowStride) -{ - uint8_t *dstUB = dst; - uint32_t i; - - if (srcRowStride == width * 4 * sizeof(uint8_t) && - dstRowStride == _mesa_format_row_stride(format, width)) { - /* do whole image at once */ - _mesa_pack_ubyte_rgba_row(format, width * height, - (const uint8_t (*)[4]) src, dst); - } - else { - /* row by row */ - for (i = 0; i < height; i++) { - _mesa_pack_ubyte_rgba_row(format, width, - (const uint8_t (*)[4]) src, dstUB); - src += srcRowStride; - dstUB += dstRowStride; - } - } -} - """ template = Template(string, future_imports=['division'])