Recherche avancée

Médias (2)

Mot : - Tags -/documentation

Autres articles (104)

  • Encoding and processing into web-friendly formats

    13 avril 2011, par

    MediaSPIP automatically converts uploaded files to internet-compatible formats.
    Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
    Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
    Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
    All uploaded files are stored online in their original format, so you can (...)

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce plugin vise à gérer des sites de mise en ligne de documents de tous types.
    Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;

  • Contribute to a better visual interface

    13 avril 2011

    MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
    Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community.

Sur d’autres sites (6585)

  • avcodec/avcodec : Free frame_thread_encoder on avcodec_open2() error

    18 avril 2021, par Andreas Rheinhardt
    avcodec/avcodec : Free frame_thread_encoder on avcodec_open2() error
    

    The frame_thread_encoder has so far not been freed in case an error
    happened in avcodec_open2() after ff_frame_thread_encoder_init().
    This commit changes this.

    Signed-off-by : Andreas Rheinhardt <andreas.rheinhardt@outlook.com>

    • [DH] libavcodec/avcodec.c
  • avformat/oggparsevorbis : Update end_trimming for the last packet

    7 juillet 2021, par Guangyu Sun
    avformat/oggparsevorbis : Update end_trimming for the last packet
    

    Without end_trimming, the last packet will contain unexpected samples used
    for padding.

    This commit partially fixes #6367 when the audio length is long enough.

    dd if=/dev/zero of=./silence.raw count=20 bs=500
    oggenc —raw silence.raw —output=silence.ogg
    oggdec —raw —output silence.oggdec.raw silence.ogg
    ffmpeg -codec:a libvorbis -i silence.ogg -f s16le -codec:a pcm_s16le silence.libvorbis.ffmpeg.raw
    ffmpeg -i silence.ogg -f s16le -codec:a pcm_s16le silence.native.ffmpeg.raw
    ls -l *.raw

    The original test case in #6367 is still not fixed due to a remaining issue.

    The remaining issue is that ogg_stream->private is not kept during
    ogg_save()/ogg_restore(). Field final_duration in the private data is
    important to calculate end_trimming.

    Some common operations such as avformat_open_input() and
    avformat_find_stream_info() before reading packet will trigger ogg_save()
    and ogg_restore().

    Luckily, final_duration will not get updated until the last ogg page. The
    save/restore mentioned above will not change final_duration most of the
    time. But if the audio length is short, those reads may be performed on
    the last ogg page, causing trouble keeping the correct value of
    final_duration. We probably need a more complicated patch to address this
    issue.

    Signed-off-by : Guangyu Sun <gsun@roblox.com>

    • [DH] libavformat/oggparsevorbis.c
  • FFMPEG take 3 minutes to generate thumbanils

    19 avril 2022, par The Dead Man

    I am generating the sprite image (combined thumbnails/screenshots) using FLUENT-FFMPEG and node js, the image looks like this.

    &#xA;

    enter image description here

    &#xA;

    Here is my node js script for generating sprite images/thumbnails.

    &#xA;

    const ffmpegPath = require("@ffmpeg-installer/ffmpeg").path;&#xA;const ffmpegCommand = require("fluent-ffmpeg");&#xA;ffmpegCommand.setFfmpegPath(ffmpegPath);&#xA;&#xA;let videoUrl =&#xA;  "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4";&#xA;const filename = `output_image`;&#xA;&#xA;ffmpegCommand(videoUrl)&#xA;  .seekInput("00:00:01.000")&#xA;  .outputOptions([&#xA;    "-q:v",&#xA;    "8",&#xA;    "-frames:v",&#xA;    "1",&#xA;    "-vsync",&#xA;    "0",&#xA;    "-qscale",&#xA;    "50",&#xA;    "-vf",&#xA;    "fps=1/10,scale=128:72,tile=11x11",&#xA;  ])&#xA;  .addOption("-preset", "superfast")&#xA;  .on("error", (err) => {&#xA;    console.log("error", err);&#xA;    reject(err);&#xA;  })&#xA;&#xA;  .save(`./tmp/${filename}.png`);&#xA;

    &#xA;

    Unfortunately, it takes almost 3 minutes to generate this image which is so bad.

    &#xA;

    UPDATE

    &#xA;

    @kesh answer is working only with internal videos.

    &#xA;

    if I add the video URL as follows.

    &#xA;

    let videoUrl ="./videos/t.mp4";

    &#xA;

    then it takes less than 3 seconds to generate thumbnails.

    &#xA;

    but if I use an external URL as follows.

    &#xA;

    let videoUrl ="http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4";

    &#xA;

    Weird, it takes too long to generate thumbnails more than 3 minutes depending on the video.

    &#xA;

    NOTE you can read full documentation here about FFmpeg and node js.

    &#xA;

    What do I need to change so that I can super fast generate my thumbnails ?

    &#xA;