Recherche avancée

Médias (91)

Autres articles (33)

  • MediaSPIP v0.2

    21 juin 2013, par

    MediaSPIP 0.2 is the first MediaSPIP stable release.
    Its official release date is June 21, 2013 and is announced here.
    The zip file provided here only contains the sources of MediaSPIP in its standalone version.
    To get a working installation, you must manually install all-software dependencies on the server.
    If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...)

  • HTML5 audio and video support

    13 avril 2011, par

    MediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
    The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
    For older browsers the Flowplayer flash fallback is used.
    MediaSPIP allows for media playback on major mobile platforms with the above (...)

  • De l’upload à la vidéo finale [version standalone]

    31 janvier 2010, par

    Le chemin d’un document audio ou vidéo dans SPIPMotion est divisé en trois étapes distinctes.
    Upload et récupération d’informations de la vidéo source
    Dans un premier temps, il est nécessaire de créer un article SPIP et de lui joindre le document vidéo "source".
    Au moment où ce document est joint à l’article, deux actions supplémentaires au comportement normal sont exécutées : La récupération des informations techniques des flux audio et video du fichier ; La génération d’une vignette : extraction d’une (...)

Sur d’autres sites (4776)

  • FFmpeg Has A Native VP8 Decoder

    24 juin 2010, par Multimedia Mike — VP8

    Thanks to David Conrad and Ronald Bultje who committed their native VP8 video decoder to the FFmpeg codebase yesterday. At this point, it can decode 14/17 of the VP8 test vectors that Google released during the initial open sourcing event. Work is ongoing on those 3 non-passing samples (missing bilinear filter). Meanwhile, FFmpeg’s optimization-obsessive personalities are hard at work optimizing the native decoder. The current decoder is already profiled to be faster than Google/On2’s official libvpx.

    Testing
    So it falls to FATE to test this on the ridiculous diversity of platforms that FFmpeg supports. I staged individual test specs for each of the 17 test vectors : vp8-test-vector-001 ... vp8-test-vector-017. After the samples have propagated through to the various FATE installations, I’ll activate the 14 test specs that are currently passing.

    Initial Testing Methodology
    Inspired by Ronald Bultje’s idea, I built the latest FFmpeg-SVN with libvpx enabled. Then I selected between the reference and native decoders as such :

    $ for i in 001 002 003 004 005 006 007 008 009 \
     010 011 012 013 014 015 016 017
    do
      echo vp80-00-comprehensive-$i.ivf
      ffmpeg -vcodec libvpx -i \
        /path/to/vp8-test-vectors-r1/vp80-00-comprehensive-$i.ivf \
        -f framemd5 - 2> /dev/null
    done > refs.txt
    

    $ for i in 001 002 003 004 005 006 007 008 009 \
    010 011 012 013 014 015 016 017
    do
    echo vp80-00-comprehensive-$i.ivf
    ffmpeg -vcodec vp8 -i \
    /path/to/vp8-test-vectors-r1/vp80-00-comprehensive-$i.ivf \
    -f framemd5 - 2> /dev/null
    done > native.txt

    $ diff -u refs.txt native.txt

    That reveals precisely which files differ.

  • FFmpeg realtime volume changing with C API

    9 janvier 2019, par Tank2006

    My environment is FFmpeg 4.1(Prebuild package from an official site) on Windows 10/Visual Studio 2017.

    I want to change an audio volume as realtime according to a volume button operation from media player apps.

    Think simply, it will update if AVFilter parameters changes, but it seems doesn’t work.

    const char src[] = "C:\\sample.mp3";

    AVFilterGraph *graph = NULL;
    AVFilterContext *ctx_src, *ctx_sink;
    AVFilter *ctx_vol;

    int main()
    {
       int res;
       AVPacket *packet = av_packet_alloc();
       AVFrame *frame = av_frame_alloc();
       AVFrame *fframe = av_frame_alloc();

       AVCodec *codec = avcodec_find_decoder(AV_CODEC_ID_MP3);
       AVCodecParser *parser = av_parser_init(codec->id);

       AVCodecContext *cc = avcodec_alloc_context3(codec);
       avcodec_open2(cc, codec, NULL);


       FILE *fp; uint8_t buffer[1024]; int filterinit = 0;
       fopen_s(&fp, src, "rb");
       while (feof(fp) == 0) {
           int read = fread(buffer, 1, 1024, fp);

           res = av_parser_parse2(parser, cc, &packet->data, &packet->size,
               buffer, read, AV_NOPTS_VALUE, AV_NOPTS_VALUE, 0);
           if (packet->size) {
               res = avcodec_send_packet(cc, packet);

               while (res >= 0) {
                   res = avcodec_receive_frame(cc, frame);

                   if (res == AVERROR(EAGAIN) || res == AVERROR_EOF) {
                       break;
                   } else if (res < 0) {
                       fprintf(stderr, "Error during decoding\n");
                       exit(1);
                   }

                   if (filterinit == 0) {
                       // Create a volume filter, links and graph from AVCodecContext's parameter
                       if(init_filters(cc)) filterinit = 1;
                   }

                   if (filterinit == 1) {
                       res = av_buffersrc_add_frame(ctx_src, frame);
                       if(av_buffersink_get_frame(ctx_sink, frame) >= 0) {

                           // Change the volume realtime
                           av_opt_set(ctx_vol, "volume", AV_STRINGIFY(1.2), AV_OPT_SEARCH_CHILDREN);


                           int datasize = av_get_bytes_per_sample(cc->sample_fmt);
                           for (int i = 0; i < frame->nb_samples; i++) {
                               for (int ch = 0; ch < cc->channels; ch++) {
                                   //fwrite(frame->data[ch] + data_size * i, 1, data_size, outfile);
                               }
                           }
                       }
                   }
               }
           }
       }

       fclose(fp);

       avcodec_free_context(&cc);
       av_parser_close(parser);
       av_frame_free(&frame);
       av_frame_free(&fframe);
       av_packet_free(&packet);

       avfilter_graph_free(&graph);

       return 0;
    }

    Can I change the filter value in realtime with FFmpeg’s C API or I need to create a new filter link each time when it requires to update ?

  • x264 configure linking and building problems

    16 janvier 2014, par Pie

    I am trying to build x264 from source on Ubuntu 32bit in order to convert a sequence of jpg or png images into mp4 video : x264 site, sample images

    The downloaded binaries is able to convert the sequence into an mkv video (or few other formats) when I run this command :

    ./x264dist ~/Dev/x264emp/img/FLYOVER%4d.JPG -o abc.mkv

    x264dist is the renamed name of the binary I download from the site.

    However, when I grab the source and compile with simple configure :

    $ ./configure --enable-shared --enable-static --enable-pic

    platform:      X86
    system:        LINUX
    cli:           yes
    libx264:       internal
    shared:        yes
    static:        yes
    asm:           yes
    interlaced:    yes
    avs:           avxsynth
    lavf:          no
    ffms:          no
    mp4:           no
    gpl:           yes
    thread:        posix
    opencl:        yes
    filters:       crop select_every
    debug:         no
    gprof:         no
    strip:         no
    PIC:           yes
    bit depth:     8
    chroma format: all

    then $ make. Then I use the binaries to run the exactly same command as above but there is this error :

    ./x264 ~/Dev/x264emp/img/FLYOVER%4d.JPG -o abc.mkv
    raw [error]: raw input requires a resolution.
    x264 [error]: could not open input file `/home/tmd/Dev/x264emp/img/FLYOVER%4d.JPG' via any method!

    It seems like it can’t read any input at all. But at least I am still able to run --help on that binaries.

    Then I realized that the downloaded binaries is 3.5Mb while my custom compilation results in 1.5Mb binaries.

    So I just want to know what are the build configurations used by the official build, and/or is there any dependency I am missing that leads to this problem.

    The reason I am trying to build myself because I want to port the x264 lib into Javascript using Emscripten. There has been a solution using FFmpeg but it seems like I don’t need the whole video processing library but only a simple H264 codec. So I need to solve the configure/compile/linking problem to port it rightly.

    Possibly similar How to configure X264 build before running make on OS X