aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/proresenc_anatoliy.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-07-08 03:12:10 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-07-08 03:19:06 +0200
commit14e2406de7d211d50fcce0059c90103bdaa947aa (patch)
tree10e20cd60b4f4bc91d14957b9565871cdd0381c3 /libavcodec/proresenc_anatoliy.c
parent5c7bf354dc0c8bea6e7af21c0bc2edad92974274 (diff)
parenta9aee08d900f686e966c64afec5d88a7d9d130a3 (diff)
downloadffmpeg-14e2406de7d211d50fcce0059c90103bdaa947aa.tar.gz
Merge commit 'a9aee08d900f686e966c64afec5d88a7d9d130a3'
* commit 'a9aee08d900f686e966c64afec5d88a7d9d130a3': dsputil: Split off FDCT bits into their own context Conflicts: configure libavcodec/Makefile libavcodec/asvenc.c libavcodec/dnxhdenc.c libavcodec/dsputil.c libavcodec/mpegvideo.h libavcodec/mpegvideo_enc.c libavcodec/x86/Makefile libavcodec/x86/dsputilenc_mmx.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/proresenc_anatoliy.c')
-rw-r--r--libavcodec/proresenc_anatoliy.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/libavcodec/proresenc_anatoliy.c b/libavcodec/proresenc_anatoliy.c
index 23323bb7fa..434021d6a6 100644
--- a/libavcodec/proresenc_anatoliy.c
+++ b/libavcodec/proresenc_anatoliy.c
@@ -32,6 +32,7 @@
#include "put_bits.h"
#include "bytestream.h"
#include "dsputil.h"
+#include "fdctdsp.h"
#define DEFAULT_SLICE_MB_WIDTH 8
@@ -145,7 +146,7 @@ static const uint8_t QMAT_CHROMA[4][64] = {
typedef struct {
- DSPContext dsp;
+ FDCTDSPContext fdsp;
uint8_t* fill_y;
uint8_t* fill_u;
uint8_t* fill_v;
@@ -274,10 +275,10 @@ static void get(uint8_t *pixels, int stride, int16_t* block)
}
}
-static void fdct_get(DSPContext *dsp, uint8_t *pixels, int stride, int16_t* block)
+static void fdct_get(FDCTDSPContext *fdsp, uint8_t *pixels, int stride, int16_t* block)
{
get(pixels, stride, block);
- dsp->fdct(block);
+ fdsp->fdct(block);
}
static int encode_slice_plane(AVCodecContext *avctx, int mb_count,
@@ -285,18 +286,18 @@ static int encode_slice_plane(AVCodecContext *avctx, int mb_count,
int *qmat, int chroma)
{
ProresContext* ctx = avctx->priv_data;
- DSPContext *dsp = &ctx->dsp;
+ FDCTDSPContext *fdsp = &ctx->fdsp;
DECLARE_ALIGNED(16, int16_t, blocks)[DEFAULT_SLICE_MB_WIDTH << 8], *block;
int i, blocks_per_slice;
PutBitContext pb;
block = blocks;
for (i = 0; i < mb_count; i++) {
- fdct_get(dsp, src, src_stride, block + (0 << 6));
- fdct_get(dsp, src + 8 * src_stride, src_stride, block + ((2 - chroma) << 6));
+ fdct_get(fdsp, src, src_stride, block + (0 << 6));
+ fdct_get(fdsp, src + 8 * src_stride, src_stride, block + ((2 - chroma) << 6));
if (!chroma) {
- fdct_get(dsp, src + 16, src_stride, block + (1 << 6));
- fdct_get(dsp, src + 16 + 8 * src_stride, src_stride, block + (3 << 6));
+ fdct_get(fdsp, src + 16, src_stride, block + (1 << 6));
+ fdct_get(fdsp, src + 16 + 8 * src_stride, src_stride, block + (3 << 6));
}
block += (256 >> chroma);
@@ -576,7 +577,7 @@ static av_cold int prores_encode_init(AVCodecContext *avctx)
return -1;
}
- ff_dsputil_init(&ctx->dsp, avctx);
+ ff_fdctdsp_init(&ctx->fdsp, avctx);
avctx->codec_tag = AV_RL32((const uint8_t*)profiles[avctx->profile].name);