Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2015-08-21 13:14:08 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2015-08-21 13:14:08 +0300
commit7c72a4bbd3a0ca421c7419abad2fb65aa713dd8b (patch)
tree5ad14038596eb2168b9ec37cde424dbd91def193 /libswscale/alphablend.c
parentb3d2035ec3b8b57533040822de1f8ea446c7d6cc (diff)
swscale/alphablend: Fix pointer type warnings
Found-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libswscale/alphablend.c')
-rw-r--r--libswscale/alphablend.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/libswscale/alphablend.c b/libswscale/alphablend.c
index 1aaef70bf7..0dd5052ccf 100644
--- a/libswscale/alphablend.c
+++ b/libswscale/alphablend.c
@@ -56,9 +56,9 @@ int ff_sws_alphablendaway(SwsContext *c, const uint8_t *src[],
unsigned u;
if (sixteen_bits) {
ptrdiff_t alpha_step = srcStride[plane_count] >> 1;
- const uint16_t *s = src[plane ] + srcStride[plane] * y;
- const uint16_t *a = src[plane_count] + (srcStride[plane_count] * y << y_subsample);
- uint16_t *d = dst[plane ] + dstStride[plane] * y;
+ const uint16_t *s = (const uint16_t *)(src[plane ] + srcStride[plane ] * y);
+ const uint16_t *a = (const uint16_t *)(src[plane_count] + (srcStride[plane_count] * y << y_subsample));
+ uint16_t *d = ( uint16_t *)(dst[plane ] + dstStride[plane ] * y);
if ((!isBE(c->srcFormat)) == !HAVE_BIGENDIAN) {
for (x = 0; x < w; x++) {
if (y_subsample) {
@@ -97,9 +97,9 @@ int ff_sws_alphablendaway(SwsContext *c, const uint8_t *src[],
}
} else {
if (sixteen_bits) {
- const uint16_t *s = src[plane ] + srcStride[plane] * y;
- const uint16_t *a = src[plane_count] + srcStride[plane_count] * y;
- uint16_t *d = dst[plane ] + dstStride[plane] * y;
+ const uint16_t *s = (const uint16_t *)(src[plane ] + srcStride[plane ] * y);
+ const uint16_t *a = (const uint16_t *)(src[plane_count] + srcStride[plane_count] * y);
+ uint16_t *d = ( uint16_t *)(dst[plane ] + dstStride[plane ] * y);
if ((!isBE(c->srcFormat)) == !HAVE_BIGENDIAN) {
for (x = 0; x < w; x++) {
unsigned u = s[x]*a[x] + target_table[((x^y)>>5)&1][plane]*(max-a[x]) + off;
@@ -129,9 +129,9 @@ int ff_sws_alphablendaway(SwsContext *c, const uint8_t *src[],
int w = c->srcW;
for (y = srcSliceY; y < srcSliceH; y++) {
if (sixteen_bits) {
- const uint16_t *s = src[0] + srcStride[0] * y + 2*!alpha_pos;
- const uint16_t *a = src[0] + srcStride[0] * y + alpha_pos;
- uint16_t *d = dst[0] + dstStride[0] * y;
+ const uint16_t *s = (const uint16_t *)(src[0] + srcStride[0] * y + 2*!alpha_pos);
+ const uint16_t *a = (const uint16_t *)(src[0] + srcStride[0] * y + alpha_pos);
+ uint16_t *d = (const uint16_t *)(dst[0] + dstStride[0] * y);
if ((!isBE(c->srcFormat)) == !HAVE_BIGENDIAN) {
for (x = 0; x < w; x++) {
for (plane = 0; plane < plane_count; plane++) {