You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-11-23 21:54:53 +02:00
fftools/ffmpeg_enc: remove unnecessary pointer references from enc_open()
This commit is contained in:
@@ -343,7 +343,7 @@ int enc_open(void *opaque, const AVFrame *frame)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((ret = avcodec_open2(ost->enc_ctx, enc, NULL)) < 0) {
|
if ((ret = avcodec_open2(enc_ctx, enc, NULL)) < 0) {
|
||||||
if (ret != AVERROR_EXPERIMENTAL)
|
if (ret != AVERROR_EXPERIMENTAL)
|
||||||
av_log(e, AV_LOG_ERROR, "Error while opening encoder - maybe "
|
av_log(e, AV_LOG_ERROR, "Error while opening encoder - maybe "
|
||||||
"incorrect parameters such as bit_rate, rate, width or height.\n");
|
"incorrect parameters such as bit_rate, rate, width or height.\n");
|
||||||
@@ -352,11 +352,11 @@ int enc_open(void *opaque, const AVFrame *frame)
|
|||||||
|
|
||||||
e->opened = 1;
|
e->opened = 1;
|
||||||
|
|
||||||
if (ost->enc_ctx->frame_size)
|
if (enc_ctx->frame_size)
|
||||||
frame_samples = ost->enc_ctx->frame_size;
|
frame_samples = enc_ctx->frame_size;
|
||||||
|
|
||||||
if (ost->enc_ctx->bit_rate && ost->enc_ctx->bit_rate < 1000 &&
|
if (enc_ctx->bit_rate && enc_ctx->bit_rate < 1000 &&
|
||||||
ost->enc_ctx->codec_id != AV_CODEC_ID_CODEC2 /* don't complain about 700 bit/s modes */)
|
enc_ctx->codec_id != AV_CODEC_ID_CODEC2 /* don't complain about 700 bit/s modes */)
|
||||||
av_log(e, AV_LOG_WARNING, "The bitrate parameter is set too low."
|
av_log(e, AV_LOG_WARNING, "The bitrate parameter is set too low."
|
||||||
" It takes bits/s as argument, not kbits/s\n");
|
" It takes bits/s as argument, not kbits/s\n");
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user