move ff_h263_round_chroma() to mpegvideo.h as static inline
Originally committed as revision 9600 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
aa89fa07b0
commit
00f0564f44
@ -70,11 +70,6 @@ void (*draw_edges)(uint8_t *buf, int wrap, int width, int height, int w)= draw_e
|
|||||||
//#define DEBUG
|
//#define DEBUG
|
||||||
|
|
||||||
|
|
||||||
static const uint8_t h263_chroma_roundtab[16] = {
|
|
||||||
// 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
|
|
||||||
0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2,
|
|
||||||
};
|
|
||||||
|
|
||||||
static const uint8_t ff_default_chroma_qscale_table[32]={
|
static const uint8_t ff_default_chroma_qscale_table[32]={
|
||||||
// 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
// 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
||||||
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31
|
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31
|
||||||
@ -1592,15 +1587,6 @@ static av_always_inline void mpeg_motion_lowres(MpegEncContext *s,
|
|||||||
//FIXME h261 lowres loop filter
|
//FIXME h261 lowres loop filter
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int ff_h263_round_chroma(int x){
|
|
||||||
if (x >= 0)
|
|
||||||
return (h263_chroma_roundtab[x & 0xf] + ((x >> 3) & ~1));
|
|
||||||
else {
|
|
||||||
x = -x;
|
|
||||||
return -(h263_chroma_roundtab[x & 0xf] + ((x >> 3) & ~1));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void chroma_4mv_motion_lowres(MpegEncContext *s,
|
static inline void chroma_4mv_motion_lowres(MpegEncContext *s,
|
||||||
uint8_t *dest_cb, uint8_t *dest_cr,
|
uint8_t *dest_cb, uint8_t *dest_cr,
|
||||||
uint8_t **ref_picture,
|
uint8_t **ref_picture,
|
||||||
|
@ -762,6 +762,19 @@ static inline int get_bits_diff(MpegEncContext *s){
|
|||||||
return bits - last;
|
return bits - last;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline int ff_h263_round_chroma(int x){
|
||||||
|
static const uint8_t h263_chroma_roundtab[16] = {
|
||||||
|
// 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
|
||||||
|
0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2,
|
||||||
|
};
|
||||||
|
if (x >= 0)
|
||||||
|
return (h263_chroma_roundtab[x & 0xf] + ((x >> 3) & ~1));
|
||||||
|
else {
|
||||||
|
x = -x;
|
||||||
|
return -(h263_chroma_roundtab[x & 0xf] + ((x >> 3) & ~1));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* motion_est.c */
|
/* motion_est.c */
|
||||||
void ff_estimate_p_frame_motion(MpegEncContext * s,
|
void ff_estimate_p_frame_motion(MpegEncContext * s,
|
||||||
int mb_x, int mb_y);
|
int mb_x, int mb_y);
|
||||||
@ -871,7 +884,6 @@ int ff_h263_resync(MpegEncContext *s);
|
|||||||
int ff_h263_get_gob_height(MpegEncContext *s);
|
int ff_h263_get_gob_height(MpegEncContext *s);
|
||||||
void ff_mpeg4_init_direct_mv(MpegEncContext *s);
|
void ff_mpeg4_init_direct_mv(MpegEncContext *s);
|
||||||
int ff_mpeg4_set_direct_mv(MpegEncContext *s, int mx, int my);
|
int ff_mpeg4_set_direct_mv(MpegEncContext *s, int mx, int my);
|
||||||
inline int ff_h263_round_chroma(int x);
|
|
||||||
void ff_h263_encode_motion(MpegEncContext * s, int val, int f_code);
|
void ff_h263_encode_motion(MpegEncContext * s, int val, int f_code);
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user