reduce ffmpeg warnings, thx DboxOldie

Origin commit data
------------------
Commit: b160f48143
Author: Frankenstone <dampf_acc@online.de>
Date: 2019-03-01 (Fri, 01 Mar 2019)
This commit is contained in:
Frankenstone
2019-03-01 18:34:51 +01:00
committed by vanhofen
parent f696dcaec3
commit ff91a9a06b
3 changed files with 49 additions and 2 deletions

View File

@@ -836,8 +836,13 @@ bool CStreamStream::Open()
AVIOInterruptCB int_cb = { Interrupt, this };
ifcx->interrupt_callback = int_cb;
#if (LIBAVFORMAT_VERSION_MAJOR < 58)
snprintf(ifcx->filename, sizeof(ifcx->filename), "%s", channel->getUrl().c_str());
av_dump_format(ifcx, 0, ifcx->filename, 0);
#else
snprintf(ifcx->url, channel->getUrl().size() + 1, "%s", channel->getUrl().c_str());
av_dump_format(ifcx, 0, ifcx->url, 0);
#endif
buf = (unsigned char *) av_malloc(IN_SIZE);
if (buf == NULL) {
@@ -873,7 +878,11 @@ bool CStreamStream::Open()
ost->id = stid++;
}
av_log_set_level(AV_LOG_VERBOSE);
#if (LIBAVFORMAT_VERSION_MAJOR < 58)
av_dump_format(ofcx, 0, ofcx->filename, 1);
#else
av_dump_format(ofcx, 0, ofcx->url, 1);
#endif
av_log_set_level(AV_LOG_WARNING);
#if (LIBAVCODEC_VERSION_INT < AV_VERSION_INT( 57,52,100 ))
bsfc = av_bitstream_filter_init("h264_mp4toannexb");