summaryrefslogtreecommitdiff
path: root/libavcodec/proresenc.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/proresenc.c')
-rw-r--r--libavcodec/proresenc.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/libavcodec/proresenc.c b/libavcodec/proresenc.c
index c4716d6c91..5a8cea8e50 100644
--- a/libavcodec/proresenc.c
+++ b/libavcodec/proresenc.c
@@ -22,6 +22,7 @@
#include "libavutil/opt.h"
#include "avcodec.h"
+#include "dsputil.h"
#include "put_bits.h"
#include "bytestream.h"
#include "internal.h"
@@ -167,7 +168,7 @@ struct TrellisNode {
#define MAX_STORED_Q 16
typedef struct ProresThreadData {
- DECLARE_ALIGNED(16, DCTELEM, blocks)[MAX_PLANES][64 * 4 * MAX_MBS_PER_SLICE];
+ DECLARE_ALIGNED(16, int16_t, blocks)[MAX_PLANES][64 * 4 * MAX_MBS_PER_SLICE];
DECLARE_ALIGNED(16, uint16_t, emu_buf)[16 * 16];
int16_t custom_q[64];
struct TrellisNode *nodes;
@@ -175,7 +176,7 @@ typedef struct ProresThreadData {
typedef struct ProresContext {
AVClass *class;
- DECLARE_ALIGNED(16, DCTELEM, blocks)[MAX_PLANES][64 * 4 * MAX_MBS_PER_SLICE];
+ DECLARE_ALIGNED(16, int16_t, blocks)[MAX_PLANES][64 * 4 * MAX_MBS_PER_SLICE];
DECLARE_ALIGNED(16, uint16_t, emu_buf)[16*16];
int16_t quants[MAX_STORED_Q][64];
int16_t custom_q[64];
@@ -210,7 +211,7 @@ typedef struct ProresContext {
static void get_slice_data(ProresContext *ctx, const uint16_t *src,
int linesize, int x, int y, int w, int h,
- DCTELEM *blocks, uint16_t *emu_buf,
+ int16_t *blocks, uint16_t *emu_buf,
int mbs_per_slice, int blocks_per_mb, int is_chroma)
{
const uint16_t *esrc;
@@ -314,7 +315,7 @@ static inline void encode_vlc_codeword(PutBitContext *pb, unsigned codebook, int
#define GET_SIGN(x) ((x) >> 31)
#define MAKE_CODE(x) (((x) << 1) ^ GET_SIGN(x))
-static void encode_dcs(PutBitContext *pb, DCTELEM *blocks,
+static void encode_dcs(PutBitContext *pb, int16_t *blocks,
int blocks_per_slice, int scale)
{
int i;
@@ -340,7 +341,7 @@ static void encode_dcs(PutBitContext *pb, DCTELEM *blocks,
}
}
-static void encode_acs(PutBitContext *pb, DCTELEM *blocks,
+static void encode_acs(PutBitContext *pb, int16_t *blocks,
int blocks_per_slice,
int plane_size_factor,
const uint8_t *scan, const int16_t *qmat)
@@ -376,7 +377,7 @@ static void encode_acs(PutBitContext *pb, DCTELEM *blocks,
static int encode_slice_plane(ProresContext *ctx, PutBitContext *pb,
const uint16_t *src, int linesize,
- int mbs_per_slice, DCTELEM *blocks,
+ int mbs_per_slice, int16_t *blocks,
int blocks_per_mb, int plane_size_factor,
const int16_t *qmat)
{
@@ -478,7 +479,7 @@ static inline int estimate_vlc(unsigned codebook, int val)
}
}
-static int estimate_dcs(int *error, DCTELEM *blocks, int blocks_per_slice,
+static int estimate_dcs(int *error, int16_t *blocks, int blocks_per_slice,
int scale)
{
int i;
@@ -509,7 +510,7 @@ static int estimate_dcs(int *error, DCTELEM *blocks, int blocks_per_slice,
return bits;
}
-static int estimate_acs(int *error, DCTELEM *blocks, int blocks_per_slice,
+static int estimate_acs(int *error, int16_t *blocks, int blocks_per_slice,
int plane_size_factor,
const uint8_t *scan, const int16_t *qmat)
{