[Libav-user] avformat_open_input hangs during opening url rtp://224.0.1.129:1234

Dmitry Adjiev adjiev.dmitry at gmail.com
Sat Aug 16 19:53:19 CEST 2014


Hello.

Here my code:

void RtpStream::run()
{
    QMutexLocker guard(&mutex_);

    if (!ip_.isEmpty()) {
        AVInputFormat* fmt = av_find_input_format(ip_.scheme().toLatin1());

        if (!fmt) {
            qDebug() << "RtpStream: can't finfd format";
            return;
        }

        AVFormatContext *ctx = avformat_alloc_context();

        if (!ctx)
            qDebug() << "RtpStream: can't alloc context";

        int ret = avformat_open_input(&ctx,
ip_.toString().toLatin1().constData(), fmt, NULL);
        qDebug() << "RtpStream: ret " << ret;


        av_free(fmt);
        avformat_free_context(ctx);
    }

    else
        qDebug() << "RtpStream: ip number is empty!";
}

avformat_open_input hangs.
What I do wrong?

-- 
Regards,
Dmitry
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://ffmpeg.org/pipermail/libav-user/attachments/20140816/7bb6c71a/attachment.html>


More information about the Libav-user mailing list