Recherche avancée

Médias (0)

Mot : - Tags -/upload

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (54)

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
    Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
    Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
    Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)

  • Les formats acceptés

    28 janvier 2010, par

    Les commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
    ffmpeg -codecs ffmpeg -formats
    Les format videos acceptés en entrée
    Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
    Les formats vidéos de sortie possibles
    Dans un premier temps on (...)

  • Gestion de la ferme

    2 mars 2010, par

    La ferme est gérée dans son ensemble par des "super admins".
    Certains réglages peuvent être fais afin de réguler les besoins des différents canaux.
    Dans un premier temps il utilise le plugin "Gestion de mutualisation"

Sur d’autres sites (6316)

  • How to create FFMPEG command that position a movie in a frame

    31 janvier 2019, par S.T

    I want to create FFMPEG command that takes 2 movies and position it inside a frame at a specified x and y next to each other and then create one movie from it.

    This is a command i did which create a movie that puts 2 movies next to each other with a space of 10 pixels between them.

    complexCommand = new String[]
    "-i", tempPath1, "-i", tempPath2, "-strict","experimental",
    "-filter_complex",
    "[0:v:0]pad=iw*2:ih+20:color=white[bg] ;"+
    "[bg][1:v:0]overlay=w+10:h+10",
    "-s", "320x240","-r", "30", "-b", "15496k", "-vcodec", "mpeg4",
    "-ab", "48000", "-ac", "2", "-ar", "22050",

    The problem is that i want more abilities like control the position of each movies (multiple movies), an explanation or an example how to use the padding and the position of the movies.

    Thanks a lot.

  • How to check if a .mp4 file is not corrupt and not missing movie frames or audio segments programmatically

    2 novembre 2019, par forgodsakehold

    With youtube-dl I was able to download quite a couple of .mp4 files. However, I have just discovered, after manually playing some of them, that they are missing movie frames in some parts while still playing audio (so a blank screen is shown), or missing audio while still playing movie frames.

    Hence,
    (1) Why doesn’t youtube-dl detect or warn against such a scenario ? It looks like the movie segments and audio track were merged and .mp4 produced without any warning. Is there a way to configure youtube-dl to detect such cases and redownload the movie ?
    (2) Otherwise, are there other ways to detect such cases programmatically ? (considering that one might have thousands of such .mp4 files and may not be able to manually go thru all of them ?) A solution with FFmpeg or php will be appreciated.

  • Create movie programatically with ffmpeg

    16 janvier 2019, par Martin Delille

    I would like to create a movie programatically with ffmpeg.

    Here is my code :

    QString fileName = "test.mov";
    static char errorString[AV_ERROR_MAX_STRING_SIZE];

    printf("Video encoding\n");

    AVOutputFormat *outputFormat = av_guess_format(nullptr, fileName.toStdString().c_str(), nullptr);

    if (outputFormat == nullptr) {
       qDebug() << "Could not find suitable format for" << fileName;
       return false;
    }

    enum AVCodecID codec_id = AV_CODEC_ID_MJPEG;

    qDebug() << "Format Name:" << outputFormat->name;
    qDebug() << "Format Video Codec:" << outputFormat->video_codec;
    outputFormat->video_codec = codec_id;

    /// allocate the output media context, formatContext
    AVFormatContext *formatContext = avformat_alloc_context();
    formatContext->oformat = outputFormat;

    // find the mpeg1 video encoder
    AVCodec *codec = avcodec_find_encoder(codec_id);

    if (!codec) {
       qDebug() << "codec not found";
       return false;
    }

    qDebug() << "Codec name:" << codec->name;

    AVStream *videoStream = avformat_new_stream(formatContext, codec);
    // put sample parameters
    videoStream->codecpar->bit_rate = 400000;
    videoStream->codecpar->width = width;
    videoStream->codecpar->height = height;
    videoStream->codecpar->codec_type = AVMEDIA_TYPE_VIDEO;
    videoStream->codecpar->format = AV_PIX_FMT_YUVJ422P;
    videoStream->time_base.num = 1;
    videoStream->time_base.den = 25;

    AVCodecContext *codecContext = avcodec_alloc_context3(nullptr);
    codecContext->codec_id = codec_id;
    codecContext->codec_type = AVMEDIA_TYPE_VIDEO;
    codecContext->width = width;
    codecContext->height = height;
    codecContext->time_base.num = 1;
    codecContext->time_base.den = 25;
    codecContext->pix_fmt = AV_PIX_FMT_YUVJ422P;

    if (int error = avcodec_parameters_to_context(codecContext, videoStream->codecpar)) {
       qDebug() << "Error parameting the context:" << av_make_error_string(errorString, AV_ERROR_MAX_STRING_SIZE, error);
       return false;
    }

    // open it
    if (int error = avcodec_open2(codecContext, codec, nullptr)) {
       qDebug() << "Could not open codec:" << av_make_error_string(errorString, AV_ERROR_MAX_STRING_SIZE, error);
       return false;
    }

    // alloc image and output buffer
    AVFrame *frame = av_frame_alloc();
    frame->format = codecContext->pix_fmt;
    frame->width = codecContext->width;
    frame->height = codecContext->height;

    if (int error = av_image_alloc(frame->data, frame->linesize, frame->width, frame->height, static_cast<enum avpixelformat="avpixelformat">(frame->format), 0)) {
       qDebug() &lt;&lt; "Error allocating image data:" &lt;&lt; av_make_error_string(errorString, AV_ERROR_MAX_STRING_SIZE, error);
       return false;
    }

    // Open the output file, if needed
    if (!(outputFormat->flags &amp; AVFMT_NOFILE)) {
       if (avio_open(&amp;formatContext->pb, fileName.toStdString().c_str(), AVIO_FLAG_WRITE) &lt; 0) {
           qDebug() &lt;&lt; "Could not open" &lt;&lt; fileName;
           return false;
       }
    }

    // some formats want stream headers to be separate
    if (formatContext->oformat->flags &amp; AVFMT_GLOBALHEADER) {
       codecContext->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
    }

    if (int error = avformat_write_header(formatContext, nullptr)) {
       qDebug() &lt;&lt; "error writing header:" &lt;&lt; av_make_error_string(errorString, AV_ERROR_MAX_STRING_SIZE, error);
       return false;
    }
    </enum>

    Unfortunately, when I execute it I have the following output :

    Format Name: mov
    Format Video Codec: 27
    Codec name: mjpeg
    [mov @ 0x1048c7000] Could not find tag for codec none in stream #0, codec not currently supported in container
    error writing header: Invalid argument

    What am I doing wrong ?