Recherche avancée

Médias (91)

Autres articles (50)

  • Participer à sa documentation

    10 avril 2011

    La documentation est un des travaux les plus importants et les plus contraignants lors de la réalisation d’un outil technique.
    Tout apport extérieur à ce sujet est primordial : la critique de l’existant ; la participation à la rédaction d’articles orientés : utilisateur (administrateur de MediaSPIP ou simplement producteur de contenu) ; développeur ; la création de screencasts d’explication ; la traduction de la documentation dans une nouvelle langue ;
    Pour ce faire, vous pouvez vous inscrire sur (...)

  • MediaSPIP v0.2

    21 juin 2013, par

    MediaSPIP 0.2 est la première version de MediaSPIP stable.
    Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

  • Mise à disposition des fichiers

    14 avril 2011, par

    Par défaut, lors de son initialisation, MediaSPIP ne permet pas aux visiteurs de télécharger les fichiers qu’ils soient originaux ou le résultat de leur transformation ou encodage. Il permet uniquement de les visualiser.
    Cependant, il est possible et facile d’autoriser les visiteurs à avoir accès à ces documents et ce sous différentes formes.
    Tout cela se passe dans la page de configuration du squelette. Il vous faut aller dans l’espace d’administration du canal, et choisir dans la navigation (...)

Sur d’autres sites (5683)

  • Progress with rtc.io

    12 août 2014, par silvia

    At the end of July, I gave a presentation about WebRTC and rtc.io at the WDCNZ Web Dev Conference in beautiful Wellington, NZ.

    webrtc_talk

    Putting that talk together reminded me about how far we have come in the last year both with the progress of WebRTC, its standards and browser implementations, as well as with our own small team at NICTA and our rtc.io WebRTC toolbox.

    WDCNZ presentation page5

    One of the most exciting opportunities is still under-exploited : the data channel. When I talked about the above slide and pointed out Bananabread, PeerCDN, Copay, PubNub and also later WebTorrent, that’s where I really started to get Web Developers excited about WebRTC. They can totally see the shift in paradigm to peer-to-peer applications away from the Server-based architecture of the current Web.

    Many were also excited to learn more about rtc.io, our own npm nodules based approach to a JavaScript API for WebRTC.

    rtcio_modules

    We believe that the World of JavaScript has reached a critical stage where we can no longer code by copy-and-paste of JavaScript snippets from all over the Web universe. We need a more structured module reuse approach to JavaScript. Node with JavaScript on the back end really only motivated this development. However, we’ve needed it for a long time on the front end, too. One big library (jquery anyone ?) that does everything that anyone could ever need on the front-end isn’t going to work any longer with the amount of functionality that we now expect Web applications to support. Just look at the insane growth of npm compared to other module collections :

    Packages per day across popular platforms (Shamelessly copied from : http://blog.nodejitsu.com/npm-innovation-through-modularity/)

    For those that – like myself – found it difficult to understand how to tap into the sheer power of npm modules as a font end developer, simply use browserify. npm modules are prepared following the CommonJS module definition spec. Browserify works natively with that and “compiles” all the dependencies of a npm modules into a single bundle.js file that you can use on the front end through a script tag as you would in plain HTML. You can learn more about browserify and module definitions and how to use browserify.

    For those of you not quite ready to dive in with browserify we have prepared prepared the rtc module, which exposes the most commonly used packages of rtc.io through an “RTC” object from a browserified JavaScript file. You can also directly download the JavaScript file from GitHub.

    Using rtc.io rtc JS library
    Using rtc.io rtc JS library

    So, I hope you enjoy rtc.io and I hope you enjoy my slides and large collection of interesting links inside the deck, and of course : enjoy WebRTC ! Thanks to Damon, JEeff, Cathy, Pete and Nathan – you’re an awesome team !

    On a side note, I was really excited to meet the author of browserify, James Halliday (@substack) at WDCNZ, whose talk on “building your own tools” seemed to take me back to the times where everything was done on the command-line. I think James is using Node and the Web in a way that would appeal to a Linux Kernel developer. Fascinating !!

  • Introducing Updates to the Funnels Feature

    29 mai 2024, par Erin

    We’ve made improvements to the Funnels feature to be more user-friendly and offer you greater flexibility. 

    &lt;script type=&quot;text/javascript&quot;&gt;<br />
           if ('function' === typeof window.playMatomoVideo){<br />
           window.playMatomoVideo(&quot;FunnelsProductUpdate2024&quot;, &quot;#FunnelsProductUpdate2024&quot;)<br />
           } else {<br />
           document.addEventListener(&quot;DOMContentLoaded&quot;, function() { window.playMatomoVideo(&quot;FunnelsProductUpdate2024&quot;, &quot;#FunnelsProductUpdate2024&quot;); });<br />
           }<br />
      &lt;/script&gt;

    Here’s what’s changing :

    Setting up and managing funnels is now easier than ever 

    Previously, creating funnels was tedious and required going through the Goals feature. But we’ve changed that with the introduction of a separate page to configure funnels. 

    Dedicated Manage Funnels page in Matomo

    Create funnels with greater flexibility—no longer tied to goals 

    Funnels is now a standalone feature, providing you with more flexibility. Before, you could only create a funnel if it was tied to a goal, in other words, the final step in the funnel had to be a goal. What’s more, you also couldn’t use goals for steps in the funnel.  

    Previous configuration requirements of Funnels in Matomo
    Previous configuration requirements of Funnels

    Now, funnels are independent of goals, and goals can serve as steps within the funnel. This means you have the freedom to configure any combination of steps in a funnel : 

    • All steps can be goals 
    • No steps need to be goals 
    • Or some steps can be goals, some steps can be events 
    Goals no longer required in Matomo Funnels

    No matter what your customer journey looks like, funnels now offer the versatility to meet your business’s specific needs. 

    Find friction points faster with intuitive visuals 

    One of the most significant improvements is the visual upgrade of the Funnels feature. The new Funnels graph is now visually in line with industry standards and intuitive. 

    New Funnel Analytics chart in Matomo

    The new visual provides a clearer view of your drop-off and conversion rates so you can instantly find points of friction in your funnel to improve the user experience and overall conversion rate.  

    This visualisation also provides a detailed overview of the number of visitors who enter, exit, skip, or proceed at each step of your funnel by using different coloured bars for visual clarity on each step’s performance. 

    With this update, we’ve also replaced ‘backfilled visits’ with ‘skipped steps’ to avoid misinterpretation of the data. 

    New data table for more granular insights 

    Accompanying this visual improvement is a new data table, allowing for more granular insights, segment comparison, and easy data export.

    We’ve also increased Funnel analysis limits. You can now compare funnel data for 2 date periods and 6 segments (up to 12 compared datasets in total). 

    Sign up for our newsletter to receive all the latest Matomo updates. 

  • Failed to play m3u8 stream continously with ffmpeg APIs

    7 novembre 2024, par wangt13

    I am working on an embedded Linux system (5.10.24), where I want to play m3u8 audio stream with FFMPEG APIs.

    &#xA;

    Here is my code.

    &#xA;

    #include &#xA;#include &#xA;#include <alsa></alsa>asoundlib.h>&#xA;&#xA;#include <libswresample></libswresample>swresample.h>&#xA;#include <libavcodec></libavcodec>avcodec.h>&#xA;#include <libavformat></libavformat>avformat.h>&#xA;#include <libswscale></libswscale>swscale.h>&#xA;&#xA;int init_pcm_play(snd_pcm_t **playback_handle,snd_pcm_uframes_t chunk_size,unsigned int rate,int bits_per_sample,int channels)&#xA;{&#xA;    snd_pcm_hw_params_t *hw_params;&#xA;    snd_pcm_format_t format;&#xA;&#xA;    //1. openPCM,&#xA;    if (0 > snd_pcm_open(playback_handle, "default", SND_PCM_STREAM_PLAYBACK, 0))&#xA;    {&#xA;        printf("snd_pcm_open err\n");&#xA;        return -1;&#xA;    }&#xA;    //2. snd_pcm_hw_params_t&#xA;    if(0 > snd_pcm_hw_params_malloc (&amp;hw_params))&#xA;    {&#xA;        printf("snd_pcm_hw_params_malloc err\n");&#xA;        return -1;&#xA;    }&#xA;    //3. hw_params&#xA;    if(0 > snd_pcm_hw_params_any (*playback_handle, hw_params))&#xA;    {&#xA;        printf("snd_pcm_hw_params_any err\n");&#xA;        return -1;&#xA;    }&#xA;    //4.&#xA;    if (0 > snd_pcm_hw_params_set_access (*playback_handle, hw_params, SND_PCM_ACCESS_RW_INTERLEAVED))&#xA;    {&#xA;        printf("snd_pcm_hw_params_any err\n");&#xA;        return -1;&#xA;    }&#xA;&#xA;    //5. SND_PCM_FORMAT_U8,8&#xA;    if(8 == bits_per_sample) {&#xA;        format = SND_PCM_FORMAT_U8;&#xA;    }&#xA;    if(16 == bits_per_sample) {&#xA;        format = SND_PCM_FORMAT_S16_LE;&#xA;    }&#xA;    if (0 > snd_pcm_hw_params_set_format (*playback_handle, hw_params, format))&#xA;    {&#xA;        printf("snd_pcm_hw_params_set_format err\n");&#xA;        return -1;&#xA;    }&#xA;&#xA;    //6.&#xA;    if (0 > snd_pcm_hw_params_set_rate_near (*playback_handle, hw_params, &amp;rate, 0))&#xA;    {&#xA;        printf("snd_pcm_hw_params_set_rate_near err\n");&#xA;        return -1;&#xA;    }&#xA;    //7.&#xA;    if (0 > snd_pcm_hw_params_set_channels(*playback_handle, hw_params, 2))&#xA;    {&#xA;        printf("snd_pcm_hw_params_set_channels err\n");&#xA;        return -1;&#xA;    }&#xA;&#xA;    //8. set hw_params&#xA;    if (0 > snd_pcm_hw_params (*playback_handle, hw_params))&#xA;    {&#xA;        printf("snd_pcm_hw_params err\n");&#xA;        return -1;&#xA;    }&#xA;&#xA;    snd_pcm_hw_params_get_period_size(hw_params, &amp;chunk_size, 0);&#xA;&#xA;    snd_pcm_hw_params_free (hw_params);&#xA;&#xA;    return 0;&#xA;}&#xA;&#xA;int main(int argc, char *argv[])&#xA;{&#xA;    AVFormatContext *pFormatCtx = NULL; //for opening multi-media file&#xA;    int audioStream = -1;&#xA;    AVCodecContext *pCodecCtx = NULL;&#xA;    AVCodec *pCodec = NULL; // the codecer&#xA;    AVFrame *pFrame = NULL;&#xA;    AVPacket *packet;&#xA;    uint8_t *out_buffer;&#xA;    struct SwrContext *au_convert_ctx;&#xA;    snd_pcm_t *playback_handle;&#xA;    int bits_per_sample = 0;&#xA;&#xA;    if (avformat_open_input(&amp;pFormatCtx, argv[1], NULL, NULL) != 0) {&#xA;        printf("Failed to open video file!");&#xA;        return -1; // Couldn&#x27;t open file&#xA;    }&#xA;&#xA;    if(avformat_find_stream_info(pFormatCtx,NULL)&lt;0)&#xA;    {&#xA;        printf("Failed to find stream info.\n");&#xA;        return -1;&#xA;    }&#xA;&#xA;    audioStream = av_find_best_stream(pFormatCtx, AVMEDIA_TYPE_AUDIO, -1, -1, NULL, 0);&#xA;    if (audioStream == -1) {&#xA;        printf("Din&#x27;t find a video stream!");&#xA;        return -1;// Didn&#x27;t find a video stream&#xA;    }&#xA;&#xA;    av_dump_format(pFormatCtx, audioStream, NULL, false);&#xA;&#xA;    // Find the decoder for the video stream&#xA;    pCodec = avcodec_find_decoder(pFormatCtx->streams[audioStream]->codecpar->codec_id);&#xA;    if (pCodec == NULL) {&#xA;        printf("Unsupported codec!\n");&#xA;        return -1; // Codec not found&#xA;    }&#xA;&#xA;    // Copy context&#xA;    pCodecCtx = avcodec_alloc_context3(pCodec);&#xA;    AVCodecParameters *pCodecParam = pFormatCtx->streams[audioStream]->codecpar;&#xA;&#xA;     if (avcodec_parameters_to_context(pCodecCtx, pCodecParam) &lt; 0) {&#xA;        printf("Failed to set codec params\n");&#xA;        return -1;&#xA;    }&#xA;    // Open codec&#xA;    if (avcodec_open2(pCodecCtx, pCodec, NULL) &lt; 0) {&#xA;        printf("Failed to open decoder!\n");&#xA;        return -1; // Could not open codec&#xA;    }&#xA;    packet = av_packet_alloc();&#xA;    pFrame = av_frame_alloc();&#xA;&#xA;    uint64_t iInputLayout                    = av_get_default_channel_layout(pCodecCtx->channels);&#xA;    enum AVSampleFormat eInputSampleFormat   = pCodecCtx->sample_fmt;&#xA;    int         iInputSampleRate             = pCodecCtx->sample_rate;&#xA;&#xA;&#xA;    uint64_t iOutputLayout                   = av_get_default_channel_layout(pCodecCtx->channels);&#xA;    int      iOutputChans                    = pCodecCtx->channels;&#xA;    enum AVSampleFormat eOutputSampleFormat  = AV_SAMPLE_FMT_S16;&#xA;    int         iOutputSampleRate            = pCodecCtx->sample_rate;&#xA;&#xA;    au_convert_ctx = swr_alloc_set_opts(NULL,iOutputLayout, eOutputSampleFormat, iOutputSampleRate,&#xA;        iInputLayout,eInputSampleFormat, iInputSampleRate, 0, NULL);&#xA;    swr_init(au_convert_ctx);&#xA;    int iConvertLineSize = 0;&#xA;    int iConvertBuffSize  = av_samples_get_buffer_size(&amp;iConvertLineSize, iOutputChans, pCodecCtx->frame_size, eOutputSampleFormat, 0);&#xA;    printf("ochans: %d, ifrmsmp: %d, osfmt: %d, cbufsz: %d\n", iOutputChans, pCodecCtx->frame_size, eOutputSampleFormat, iConvertBuffSize);&#xA;    out_buffer = (uint8_t *) av_malloc(iConvertBuffSize);&#xA;&#xA;    if(eOutputSampleFormat == AV_SAMPLE_FMT_S16 )&#xA;    {&#xA;        bits_per_sample = 16;&#xA;    }&#xA;    /*** alsa handle ***/&#xA;    init_pcm_play(&amp;playback_handle,256, iOutputSampleRate,bits_per_sample,2);&#xA;&#xA;    if (0 > snd_pcm_prepare (playback_handle))&#xA;    {&#xA;        printf("snd_pcm_prepare err\n");&#xA;        return -1;&#xA;    }&#xA;&#xA;    while (av_read_frame(pFormatCtx, packet) >= 0) {&#xA;        if (packet->stream_index == audioStream) {&#xA;            avcodec_send_packet(pCodecCtx, packet);&#xA;            while (avcodec_receive_frame(pCodecCtx, pFrame) == 0) {&#xA;                int outframes = swr_convert(au_convert_ctx, &amp;out_buffer, pCodecCtx->frame_size, (const uint8_t **) pFrame->data, pFrame->nb_samples); // 转换音频&#xA;                snd_pcm_writei(playback_handle, out_buffer, outframes);&#xA;                av_frame_unref(pFrame);&#xA;            }&#xA;        }&#xA;        av_packet_unref(packet);&#xA;    }&#xA;    swr_free(&amp;au_convert_ctx);&#xA;    snd_pcm_close(playback_handle);&#xA;    av_freep(&amp;out_buffer);&#xA;&#xA;    return 0;&#xA;}&#xA;

    &#xA;

    When I ran it, i got following output.

    &#xA;

    ./ffmpeg_test http://live.ximalaya.com/radio-first-page-app/live/2730/64.m3&#xA;u8&#xA;[hls @ 0x21a8020] Skip (&#x27;#EXT-X-VERSION:3&#x27;)&#xA;[hls @ 0x21a8020] Opening &#x27;http://broadcast.tx.xmcdn.com/live/2730_64_241104_000015_2186.aac&#x27; for reading&#xA;[hls @ 0x21a8020] Opening &#x27;http://broadcast.tx.xmcdn.com/live/2730_64_241104_000015_2187.aac&#x27; for reading&#xA;Input #0, hls, from &#x27;(null)&#x27;:&#xA;  Duration: N/A, bitrate: N/A&#xA;  Program 0&#xA;    Metadata:&#xA;      variant_bitrate : 0&#xA;  Stream #0:0: Audio: aac (HE-AAC), 44100 Hz, stereo, fltp&#xA;    Metadata:&#xA;      variant_bitrate : 0&#xA;[http @ 0x21b7ba0] Opening &#x27;http://broadcast.tx.xmcdn.com/live/2730_64_241104_000015_2188.aac&#x27; for reading&#xA;[hls @ 0x21a8020] Skip (&#x27;#EXT-X-VERSION:3&#x27;)&#xA;[http @ 0x21d4c20] Opening &#x27;http://broadcast.tx.xmcdn.com/live/2730_64_241104_000015_2189.aac&#x27; for reading&#xA;

    &#xA;

    At the beginning, it can play the audio, until a second Opening http://... occurred.

    &#xA;

    How to make it work to play m3u8 audio stream continously ?

    &#xA;