Recherche avancée

Médias (39)

Mot : - Tags -/audio

Autres articles (78)

  • La sauvegarde automatique de canaux SPIP

    1er avril 2010, par

    Dans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
    Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)

  • Script d’installation automatique de MediaSPIP

    25 avril 2011, par

    Afin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
    Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
    La documentation de l’utilisation du script d’installation (...)

  • Automated installation script of MediaSPIP

    25 avril 2011, par

    To overcome the difficulties mainly due to the installation of server side software dependencies, an "all-in-one" installation script written in bash was created to facilitate this step on a server with a compatible Linux distribution.
    You must have access to your server via SSH and a root account to use it, which will install the dependencies. Contact your provider if you do not have that.
    The documentation of the use of this installation script is available here.
    The code of this (...)

Sur d’autres sites (6422)

  • ffmpeg stream decoding - artefacts when not using ffplay

    18 décembre 2018, par Lucker10

    I stream a video capture via RTP using libx264. For now, I just stream to localhost.
    For watching the stream, I use the ffmpeg library. When I set the GOP size greater than 1 (only I frames), I get artefacts on the receiver side received image. The strange thing is, when I use ffplay, the image is perfect like original. What am I doing wrong ?

    Settings for encoding

    output_codec_ctx->bit_rate = 5000000;
    output_codec_ctx->width = 1920;
    output_codec_ctx->height = 1080;
    output_codec_ctx->time_base.den = 30; // frames per second
    output_codec_ctx->time_base.num = 1;
    output_codec_ctx->gop_size = 10; // gop size
    output_codec_ctx->max_b_frames = 0; // B frames
    output_codec_ctx->pix_fmt = AV_PIX_FMT_YUV420P; // output pixel format
    output_codec_ctx->codec_type = AVMEDIA_TYPE_VIDEO;

    av_opt_set(output_codec_ctx->priv_data, "preset", "ultrafast", 0);
    av_opt_set(output_codec_ctx->priv_data, "tune", "zerolatency", 0);

    Code for decoding

    AVFormatContext *pFormatCtx;
    AVCodecContext *input_codec_ctx;
    AVCode *pCodec;
    avdevice_register_all(); // for device
    avformat_network_init();
    pFormatCtx = avformat_alloc_context();
    input_codec_ctx = avcodec_alloc_context3(nullptr);
    AVDictionary *options = nullptr;
    av_dict_set(&options, "protocol_whitelist", "file,udp,rtp", 0);
    av_dict_set(&options, "fflags", "nobuffer",0);

    avformat_open_input(&pFormatCtx, "rtp://127.0.0.1:49990", nullptr, &options);

    avformat_find_stream_info(pFormatCtx, nullptr);
    for (uint i = 0; i < pFormatCtx->nb_streams; i++)
    {
      if (pFormatCtx->streams[i]->codecpar->codec_type == AVMEDIA_TYPE_VIDEO)
      {
        videoStream = static_cast<int>(i);
        break;
      }

    }

    av_read_play(pFormatCtx);    //play stream
    pCodec = avcodec_find_decoder(pFormatCtx->streams[videoStream]->codecpar->codec_id);
    AVCodecParameters *codec_param = pFormatCtx->streams[videoStream]->codecpar;
    avcodec_parameters_to_context(input_codec_ctx, codec_param);
    avcodec_open2(input_codec_ctx, pCodec, nullptr);

    AVPacket packet;
    AVPacket *pkt  = &amp;packet;
    AVFrame *frame;
    frame = av_frame_alloc();

    av_init_packet(pkt);
    pkt->data = nullptr;    // packet data will be allocated by the encoder
    pkt->size = 0;

    while(true){
       av_read_frame(pFormatCtx,pkt);
       avcodec_send_packet(input_codec_ctx,pkt);
       avcodec_receive_frame(input_codec_ctx,frame);
    }
    </int>

    Initialization and stuff omitted. Console output for custom decoding :

    NULL @ 0x1fb7b80] Opening 'stream.sdp' for reading
    [sdp @ 0x1fb7b80] Format sdp probed with size=2048 and score=50
    [sdp @ 0x1fb7b80] video codec set to: h264
    [sdp @ 0x1fb7b80] RTP Packetization Mode: 1
    [udp @ 0x1f34140] end receive buffer size reported is 131072
    [udp @ 0x1fb8e40] end receive buffer size reported is 131072
    [sdp @ 0x1fb7b80] setting jitter buffer size to 500

    Success !
    [sdp @ 0x1fb7b80] Before avformat_find_stream_info() pos: 181 bytes read:181 seeks:0 nb_streams:1
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [AVBSFContext @ 0x1fa5880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] Format yuv420p chosen by get_format().
    [h264 @ 0x1fa51c0] Reinit context to 1920x1088, pix_fmt: yuv420p
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 57 packets
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] Invalid level prefix
    [h264 @ 0x1fa51c0] error while decoding MB 2 36
    [h264 @ 0x1fa51c0] concealing 3887 DC, 3887 AC, 3887 MV errors in I frame
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 155 packets
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] corrupted macroblock 32 41 (total_coeff=-1)
    [h264 @ 0x1fa51c0] error while decoding MB 32 41
    [h264 @ 0x1fa51c0] concealing 3257 DC, 3257 AC, 3257 MV errors in I frame
    [h264 @ 0x1fa51c0] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1fa51c0] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 52 packets
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 51 packets
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 10 packets
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 50 packets
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 52 packets
    [sdp @ 0x1fb7b80] All info found
    [sdp @ 0x1fb7b80] After avformat_find_stream_info() pos: 181 bytes read:181 seeks:0 frames:28
    found video stream

    The number of elements in stream is  1

    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] Format yuv420p chosen by get_format().
    [h264 @ 0x1ee3880] Reinit context to 1920x1088, pix_fmt: yuv420p
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 256 packets
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] Invalid level prefix
    [h264 @ 0x1ee3880] error while decoding MB 119 41
    [h264 @ 0x1ee3880] concealing 3170 DC, 3170 AC, 3170 MV errors in I frame
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 5 packets
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 4 packets
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] out of range intra chroma pred mode
    [h264 @ 0x1ee3880] error while decoding MB 100 56
    [h264 @ 0x1ee3880] corrupted macroblock 84 65 (total_coeff=-1)
    [h264 @ 0x1ee3880] error while decoding MB 84 65
    [h264 @ 0x1ee3880] concealing 754 DC, 754 AC, 754 MV errors in I frame
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 160 packets
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] corrupted macroblock 17 36 (total_coeff=-1)
    [h264 @ 0x1ee3880] error while decoding MB 17 36
    [h264 @ 0x1ee3880] concealing 3872 DC, 3872 AC, 3872 MV errors in I frame
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [sdp @ 0x1fb7b80] max delay reached. need to consume packet
    [sdp @ 0x1fb7b80] RTP: missed 53 packets
    [h264 @ 0x1ee3880] nal_unit_type: 7(SPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 8(PPS), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] nal_unit_type: 5(IDR), nal_ref_idc: 3
    [h264 @ 0x1ee3880] corrupted macroblock 62 39 (total_coeff=-1)
    [h264 @ 0x1ee3880] error while decoding MB 62 39
    [h264 @ 0x1ee3880] concealing 3467 DC, 3467 AC, 3467 MV errors in I frame
  • Gstreamer pipeline to scale down video before streaming

    20 novembre 2014, par r3dsm0k3

    Here is what Im trying to achieve.

    Im streaming from a Logitech C920 camera on beaglebone black with gstreamer. I have to save a copy of the video saved locally while it is streaming. I have achieved that with tee.
    Logitech camera gives h264 encoded video at a certain bitrate, mostly very high.

    Im streaming from a moving car on 3G, and the network is not good enough to send the stream to nginx-rtmp server Im using to re-distribute thus gives strong artifacts in the result.

    Im able to alter the bitrate of captured video using uvch264.
    But then, the locally saved video also would have lower bitrate.

    Is there anyway of capturing a higher bitrate 1080p video from the camera and sending a lower resolution, lower bitrate video the streaming server ?

    Following is the pipeline I have currently.

    gst-launch-1.0 -v -e uvch264src initial-bitrate=400000 average-bitrate=400000 iframe-period=3000  device=/dev/video0 name=src auto-start=true  src.vidsrc ! queue ! video/x-h264,width=1920,height=1080,framerate=30/1 ! h264parse ! flvmux streamable=true  name=flvmuxer ! queue ! tee name=t ! queue ! filesink location=/mnt/test.flv t. ! queue ! rtmpsink location=$SERVER/hls/$CAM1

    I could also try sending the higher bitrate video to a udpsink instead of rtmpsink and with another gstreamer process parallely and takes the data using a udpsink and probably post process/ re-encode and send to rtmp server.

    Im also limited by the processing speed BeagleBone has to do for encoding the videos. Currently Im trying for 1 camera and in the finished project I would like to have 2 cameras connected. Upload speed Im getting for the network is under 1Mbps.

    How do I solve this with less load on the BeagleBone ? Im very open to a new architecture as well.

  • How to convert an IP Camera video stream into a video file ?

    14 novembre 2014, par AgentFire

    I have a URL (<ip>/ipcam/mpeg4.cgi</ip>) which points to my IP camera which is connected via Ethernet.
    Accessing the URL resuls in a infinite stream of video (possibly with audio) data.

    I would like to store this data into a video file and play it later with a video player (HTML5’s video tag is preferred as the player).

    However, a straightforward approach, which is simple saving the stream data into .mp4 file, didn’t work.

    I have looked into the file and here is what I saw (click to enlarge) :

    It turned out, there are some HTML headers, which I further on manually excluded using the binary editing tool, and yet no player could play the rest of the file.

    The HTML headers are :

    --myboundary
    Content-Type: image/mpeg4
    Content-Length: 76241
    X-Status: 0
    X-Tag: 1693923
    X-Flags: 0
    X-Alarm: 0
    X-Frametype: I
    X-Framerate: 30
    X-Resolution: 1920*1080
    X-Audio: 1
    X-Time: 2000-02-03 02:46:31
    alarm: 0000

    My question is pretty clear now, and I would like any help or suggestion. I suspect, I have to manually create some MP4 headers myself based on those values above, however, I fail to understand format descriptions such as these.

    I have the following video stream settings on my IP camera (click to enlarge) :

    I could also use the ffmpeg tool, but no matter how I try and mix the arguments to the program, it keeps telling me this error :