summaryrefslogtreecommitdiff
path: root/libavcodec/x86/dsputil_mmx.c
diff options
context:
space:
mode:
authorRonald S. Bultje <rsbultje@gmail.com>2013-09-20 08:01:19 -0400
committerRonald S. Bultje <rsbultje@gmail.com>2013-09-28 20:28:08 -0400
commitface578d56c2d1375e40d5e2a28acc122132bc55 (patch)
tree8a4fe63c8066b59ea41dd09285b4a82587a65030 /libavcodec/x86/dsputil_mmx.c
parentf574b4da567cc1c175ab5463fb5b3901cbaa5595 (diff)
Rewrite emu_edge functions to have separate src/dst_stride arguments.
This allows supporting files for which the image stride is smaller than the max. block size + number of subpel mc taps, e.g. a 64x64 VP9 file or a 16x16 VP8 file with -fflags +emu_edge.
Diffstat (limited to 'libavcodec/x86/dsputil_mmx.c')
-rw-r--r--libavcodec/x86/dsputil_mmx.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/libavcodec/x86/dsputil_mmx.c b/libavcodec/x86/dsputil_mmx.c
index 421a6c2090..9cbf58a09c 100644
--- a/libavcodec/x86/dsputil_mmx.c
+++ b/libavcodec/x86/dsputil_mmx.c
@@ -405,8 +405,9 @@ void ff_draw_edges_mmx(uint8_t *buf, int wrap, int width, int height,
}
}
-typedef void emulated_edge_mc_func(uint8_t *dst, const uint8_t *src,
- ptrdiff_t linesize, int block_w, int block_h,
+typedef void emulated_edge_mc_func(uint8_t *dst, ptrdiff_t dst_stride,
+ const uint8_t *src, ptrdiff_t src_linesize,
+ int block_w, int block_h,
int src_x, int src_y, int w, int h);
static av_always_inline void gmc(uint8_t *dst, uint8_t *src,
@@ -454,7 +455,7 @@ static av_always_inline void gmc(uint8_t *dst, uint8_t *src,
src += ix + iy * stride;
if (need_emu) {
- emu_edge_fn(edge_buf, src, stride, w + 1, h + 1, ix, iy, width, height);
+ emu_edge_fn(edge_buf, stride, src, stride, w + 1, h + 1, ix, iy, width, height);
src = edge_buf;
}