Mercurial > libavcodec.hg
comparison avcodec.h @ 324:9c6f056f0e41 libavcodec
fixed mpeg4 time stuff on encoding
mpeg4 b-frame enoding support
removed old, out-commented ratecontrol
reuse motion compensation code between encoding & decoding
prefix newly added global functions with ff_ to reduce namespace polution
b-frame ME (unfinished, but working)
added some comments to mpegvideo.h
do MC on encoding only once if possible
bugs? ;)
author | michaelni |
---|---|
date | Wed, 17 Apr 2002 04:32:12 +0000 |
parents | ce35fd27bbb0 |
children | 025825084364 |
comparison
equal
deleted
inserted
replaced
323:68cc7650c645 | 324:9c6f056f0e41 |
---|---|
75 extern int motion_estimation_method; | 75 extern int motion_estimation_method; |
76 | 76 |
77 /* ME algos sorted by quality */ | 77 /* ME algos sorted by quality */ |
78 static const int Motion_Est_QTab[] = { 1, 4, 3, 6, 5, 2 }; | 78 static const int Motion_Est_QTab[] = { 1, 4, 3, 6, 5, 2 }; |
79 | 79 |
80 #define FF_MAX_B_FRAMES 4 | |
81 | |
80 /* encoding support */ | 82 /* encoding support */ |
81 /* note not everything is supported yet */ | 83 /* note not everything is supported yet */ |
82 | 84 |
83 #define CODEC_FLAG_HQ 0x0001 /* high quality (non real time) encoding */ | 85 #define CODEC_FLAG_HQ 0x0001 /* high quality (non real time) encoding */ |
84 #define CODEC_FLAG_QSCALE 0x0002 /* use fixed qscale */ | 86 #define CODEC_FLAG_QSCALE 0x0002 /* use fixed qscale */ |
85 #define CODEC_FLAG_4MV 0x0004 /* 4 MV per MB allowed */ | 87 #define CODEC_FLAG_4MV 0x0004 /* 4 MV per MB allowed */ |
86 #define CODEC_FLAG_B 0x0008 /* use B frames */ | |
87 #define CODEC_FLAG_QPEL 0x0010 /* use qpel MC */ | 88 #define CODEC_FLAG_QPEL 0x0010 /* use qpel MC */ |
88 #define CODEC_FLAG_GMC 0x0020 /* use GMC */ | 89 #define CODEC_FLAG_GMC 0x0020 /* use GMC */ |
89 #define CODEC_FLAG_TYPE 0x0040 /* fixed I/P frame type, from avctx->key_frame */ | 90 #define CODEC_FLAG_TYPE 0x0040 /* fixed I/P frame type, from avctx->key_frame */ |
91 /* parent program gurantees that the input for b-frame containing streams is not written to | |
92 for at least s->max_b_frames+1 frames, if this is not set than the input will be copied */ | |
93 #define CODEC_FLAG_INPUT_PRESERVED 0x0100 | |
90 | 94 |
91 /* codec capabilities */ | 95 /* codec capabilities */ |
92 | 96 |
93 /* decoder can use draw_horiz_band callback */ | 97 /* decoder can use draw_horiz_band callback */ |
94 #define CODEC_CAP_DRAW_HORIZ_BAND 0x0001 | 98 #define CODEC_CAP_DRAW_HORIZ_BAND 0x0001 |
139 float qcompress; /* amount of qscale change between easy & hard scenes (0.0-1.0)*/ | 143 float qcompress; /* amount of qscale change between easy & hard scenes (0.0-1.0)*/ |
140 float qblur; /* amount of qscale smoothing over time (0.0-1.0) */ | 144 float qblur; /* amount of qscale smoothing over time (0.0-1.0) */ |
141 int qmin; /* min qscale */ | 145 int qmin; /* min qscale */ |
142 int qmax; /* max qscale */ | 146 int qmax; /* max qscale */ |
143 int max_qdiff; /* max qscale difference between frames */ | 147 int max_qdiff; /* max qscale difference between frames */ |
144 | 148 int max_b_frames; /* maximum b frames, the output will be delayed by max_b_frames+1 relative to the input */ |
149 | |
145 struct AVCodec *codec; | 150 struct AVCodec *codec; |
146 void *priv_data; | 151 void *priv_data; |
147 | 152 |
148 /* The following data is for RTP friendly coding */ | 153 /* The following data is for RTP friendly coding */ |
149 /* By now only H.263/H.263+ coder honours this */ | 154 /* By now only H.263/H.263+ coder honours this */ |