mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-11-26 19:01:44 +02:00
h261enc: use av_assert
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
07732b4f09
commit
b4d44367bc
@ -25,6 +25,7 @@
|
||||
* H.261 encoder.
|
||||
*/
|
||||
|
||||
#include "libavutil/avassert.h"
|
||||
#include "dsputil.h"
|
||||
#include "avcodec.h"
|
||||
#include "mpegvideo.h"
|
||||
@ -194,7 +195,7 @@ void ff_h261_encode_mb(MpegEncContext * s,
|
||||
h->mtype+=3;
|
||||
if(cbp || s->dquant)
|
||||
h->mtype++;
|
||||
assert(h->mtype > 1);
|
||||
av_assert1(h->mtype > 1);
|
||||
}
|
||||
|
||||
if(s->dquant)
|
||||
@ -221,7 +222,7 @@ void ff_h261_encode_mb(MpegEncContext * s,
|
||||
h->previous_mba = h->current_mba;
|
||||
|
||||
if(HAS_CBP(h->mtype)){
|
||||
assert(cbp>0);
|
||||
av_assert1(cbp>0);
|
||||
put_bits(&s->pb,ff_h261_cbp_tab[cbp-1][1],ff_h261_cbp_tab[cbp-1][0]);
|
||||
}
|
||||
for(i=0; i<6; i++) {
|
||||
@ -307,8 +308,8 @@ static void h261_encode_block(H261Context * h, DCTELEM * block, int n){
|
||||
put_bits(&s->pb, rl->table_vlc[code][1], rl->table_vlc[code][0]);
|
||||
if (code == rl->n) {
|
||||
put_bits(&s->pb, 6, run);
|
||||
assert(slevel != 0);
|
||||
assert(level <= 127);
|
||||
av_assert1(slevel != 0);
|
||||
av_assert1(level <= 127);
|
||||
put_sbits(&s->pb, 8, slevel);
|
||||
} else {
|
||||
put_bits(&s->pb, 1, sign);
|
||||
|
Loading…
Reference in New Issue
Block a user