Advanced search

Medias (91)

Other articles (27)

  • Other interesting software

    13 April 2011, by

    We don’t claim to be the only ones doing what we do ... and especially not to assert claims to be the best either ... What we do, we just try to do it well and getting better ...
    The following list represents softwares that tend to be more or less as MediaSPIP or that MediaSPIP tries more or less to do the same, whatever ...
    We don’t know them, we didn’t try them, but you can take a peek.
    Videopress
    Website: http://videopress.com/
    License: GNU/GPL v2
    Source code: (...)

  • Submit bugs and patches

    13 April 2011

    Unfortunately a software is never perfect.
    If you think you have found a bug, report it using our ticket system. Please to help us to fix it by providing the following information: the browser you are using, including the exact version as precise an explanation as possible of the problem if possible, the steps taken resulting in the problem a link to the site / page in question
    If you think you have solved the bug, fill in a ticket and attach to it a corrective patch.
    You may also (...)

  • List of compatible distributions

    26 April 2011, by

    The table below is the list of Linux distributions compatible with the automated installation script of MediaSPIP. Distribution nameVersion nameVersion number Debian Squeeze 6.x.x Debian Weezy 7.x.x Debian Jessie 8.x.x Ubuntu The Precise Pangolin 12.04 LTS Ubuntu The Trusty Tahr 14.04
    If you want to help us improve this list, you can provide us access to a machine whose distribution is not mentioned above or send the necessary fixes to add (...)

On other websites (6423)

  • build: Store library version numbers in .version files

    17 December 2016, by Diego Biurrun
    build: Store library version numbers in .version files
    

    This moves work from the configure to the Make stage where it can
    be parallelized and ensures that shared libraries are built with
    the right version number in the filename.

    • [DBH] Makefile
    • [DBH] avbuild/common.mak
    • [DBH] avbuild/library.mak
    • [DBH] avbuild/libversion.sh
    • [DBH] configure
  • vdpau: store picture data in picture’s rather than codec’s context

    25 July 2013, by Rémi Denis-Courmont
    vdpau: store picture data in picture’s rather than codec’s context
    

    Signed-off-by: Anton Khirnov <anton@khirnov.net>

    • [DBH] libavcodec/Makefile
    • [DBH] libavcodec/vdpau.c
    • [DBH] libavcodec/vdpau_h264.c
    • [DBH] libavcodec/vdpau_internal.h
    • [DBH] libavcodec/vdpau_mpeg12.c
    • [DBH] libavcodec/vdpau_mpeg4.c
    • [DBH] libavcodec/vdpau_vc1.c
  • store pcm data into file, but can not play that file

    25 May 2016, by Peng Qu

    I am writing a simple program, which reads mp3 file and store its pcm data into another file. I could get that file now, but when I play that on windows, I failed. So is there any wrong in my code, or windows couldn’t play raw audio data?

    #include
    #include
    #include <libavutil></libavutil>avutil.h>
    #include <libavformat></libavformat>avformat.h>
    #include <libavcodec></libavcodec>avcodec.h>

    int main()
    {
    int err;
    FILE *fout = fopen("test.wav", "wb");
    av_register_all();

    // step 1, open file and find audio stream
    AVFormatContext *fmtx = NULL;
    err = avformat_open_input(&amp;fmtx, "melodylove.mp3", NULL, NULL);
    assert(!err);

    err = avformat_find_stream_info(fmtx, NULL);
    assert(!err);

    int audio_stream_idx = -1;
    AVStream *st;
    AVCodecContext *decx;
    AVCodec *dec;

    for (int i = 0; i &lt; fmtx->nb_streams; ++i) {
       audio_stream_idx = i;
       if (fmtx->streams[i]->codec->codec_type == AVMEDIA_TYPE_AUDIO) {
           st = fmtx->streams[i];
           decx = st->codec;
           dec = avcodec_find_decoder(decx->codec_id);
           decx->request_channel_layout = AV_CH_LAYOUT_STEREO_DOWNMIX;
           decx->request_sample_fmt = AV_SAMPLE_FMT_FLT;
           avcodec_open2(decx, dec, NULL);
           break;
       }
    }
    assert(audio_stream_idx != -1);

    int channels = decx->channels;
    int sample_rate = decx->sample_rate;
    int planar = av_sample_fmt_is_planar(decx->sample_fmt);
    int num_planes =  planar? decx->channels : 1;
    const char *sample_name = av_get_sample_fmt_name(decx->sample_fmt);
    printf("sample name: %s, channels: %d, sample rate: %d\n",
           sample_name, channels, sample_rate);
    printf("is planar: %d, planes: %d\n", planar, num_planes);

    /*
    * above I print some infomation about mp3 file, they are:
    * sample name: s16p, channels: 2, sample rate: 48000
    * is planar: 1, planes: 2
    */
    getchar();

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

    while (1) {
       err = av_read_frame(fmtx, &amp;pkt);
       if (err &lt; 0) {
           printf("read frame fail\n");
           fclose(fout);
           exit(-1);
       }
       if (pkt.stream_index != audio_stream_idx) {
           printf("we don't need this stream\n");
           continue;
       }
       printf("data size: %d\n", pkt.size);

       int got_frame = 0;
       int bytes = avcodec_decode_audio4(decx, frame, &amp;got_frame, &amp;pkt);
       if (bytes &lt; 0) {
           printf("decode audio fail\n");
           continue;
       }
       printf("frame size: %d, samples: %d\n", bytes, frame->nb_samples);

       if (got_frame) {
           int input_samples = frame->nb_samples * decx->channels;
           int sz = input_samples / num_planes;
           short buffer1[input_samples];

           for (int j = 0; j &lt; frame->nb_samples; ++j) {
               for (int i = 0; i &lt; num_planes; ++i) {
                   short *d = (short *)frame->data[i];
                   buffer1[j*2+i] = d[j];
               }
           }

           fwrite(buffer1, input_samples, 2, fout);
       } else {
           printf("why not get frame???");
       }
    }
    }