mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +02:00
rawdec: use av_assert()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
948e97a2cc
commit
9d87c8e6f8
@ -27,6 +27,7 @@
|
|||||||
#include "libavutil/opt.h"
|
#include "libavutil/opt.h"
|
||||||
#include "libavutil/parseutils.h"
|
#include "libavutil/parseutils.h"
|
||||||
#include "libavutil/pixdesc.h"
|
#include "libavutil/pixdesc.h"
|
||||||
|
#include "libavutil/avassert.h"
|
||||||
|
|
||||||
/* raw input */
|
/* raw input */
|
||||||
int ff_raw_read_header(AVFormatContext *s)
|
int ff_raw_read_header(AVFormatContext *s)
|
||||||
@ -67,7 +68,7 @@ int ff_raw_read_header(AVFormatContext *s)
|
|||||||
st->codec->channels = s1->channels;
|
st->codec->channels = s1->channels;
|
||||||
|
|
||||||
st->codec->bits_per_coded_sample = av_get_bits_per_sample(st->codec->codec_id);
|
st->codec->bits_per_coded_sample = av_get_bits_per_sample(st->codec->codec_id);
|
||||||
assert(st->codec->bits_per_coded_sample > 0);
|
av_assert0(st->codec->bits_per_coded_sample > 0);
|
||||||
st->codec->block_align = st->codec->bits_per_coded_sample*st->codec->channels/8;
|
st->codec->block_align = st->codec->bits_per_coded_sample*st->codec->channels/8;
|
||||||
avpriv_set_pts_info(st, 64, 1, st->codec->sample_rate);
|
avpriv_set_pts_info(st, 64, 1, st->codec->sample_rate);
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user