Recherche avancée

Médias (0)

Mot : - Tags -/protocoles

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

Autres articles (4)

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

  • 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" ;

  • Le plugin : Podcasts.

    14 juillet 2010, par

    Le problème du podcasting est à nouveau un problème révélateur de la normalisation des transports de données sur Internet.
    Deux formats intéressants existent : Celui développé par Apple, très axé sur l’utilisation d’iTunes dont la SPEC est ici ; Le format "Media RSS Module" qui est plus "libre" notamment soutenu par Yahoo et le logiciel Miro ;
    Types de fichiers supportés dans les flux
    Le format d’Apple n’autorise que les formats suivants dans ses flux : .mp3 audio/mpeg .m4a audio/x-m4a .mp4 (...)

Sur d’autres sites (1677)

  • flv created using ffmpeg library plays too fast

    25 avril 2015, par Muhammad Ali

    I am muxing an h264 annex-b stream and an ADTS AAC stream coming from IP Camera into an FLV. I have gone through all the necessary things (that I knew of) e-g stripping ADTS header from AAC and converting H264 annex-b to AVC.

    I am able to create the flv file which plays but it plays fast. The params of my output format video codec are :-

    Time base = 1/60000   <-- I don't know why
    Bitrate = 591949 (591Kbps)
    GOP Size = 12
    FPS = 30 Fps (that's the rate encoder sends me data at)

    Params for output format audio codec are :-

    Timebase = 1/44100
    Bitrate = 45382 (45Kbps)
    Sample rate = 48000

    I am using NO_PTS for both audio and video.
    The resultant video has double the bit rate (2x(audio bitrate + vid bitrate)) and half the duration.
    If i play the resultant video in ffplay the video playsback fast so it ends quickly but audio plays on its original time. So even after the video has ended quickly the audio still plays till its full duration.

    If I set pts and dts equal to an increasing index (separate indices for audio and video) the video plays Super fast, bit rate shoots to an insane value and video duration gets very short but audio plays fine and on time.

    EDIT :

    Duration: 00:00:09.96, start: 0.000000, bitrate: 1230 kb/s
    Stream #0:0: Video: h264 (Main), yuvj420p(pc, bt709), 1280x720 [SAR 1:1 DAR 16:9], 591 kb/s, 30.33 fps, 59.94 tbr, 1k tbn, 59.94 tbc
    Stream #0:1: Audio: aac, 48000 Hz, mono, fltp, 45 kb/s

    Why is tbr 59.94 ? how was that calculated ? maybe that is the problem ?

    Code for muxing :

    if(packet.header.dataType == TRANSFER_PACKET_TYPE_H264)
             {

               if((packet.data[0] == 0x00) && (packet.data[1] == 0x00) && (packet.data[2]==0x00) && (packet.data[3]==0x01))
               {

                 unsigned char tempCurrFrameLength[4];
                 unsigned int nal_unit_length;
                 unsigned char nal_unit_type;
                 unsigned int cursor = 0;
                 int size = packet.header.dataLen;

                  do {

                       av_init_packet(&pkt);
                       int currFrameLength = 0;
                       if((packet.header.frameType == TRANSFER_FRAME_IDR_VIDEO) || (packet.header.frameType == TRANSFER_FRAME_I_VIDEO))
                       {
                         //pkt.flags        |= AV_PKT_FLAG_KEY;
                       }
                       pkt.stream_index  = packet.header.streamId;//0;//ost->st->index;     //stream index 0 for vid : 1 for aud
                       outStreamIndex = outputVideoStreamIndex;
                       /*vDuration += (packet.header.dataPTS - lastvPts);
                       lastvPts = packet.header.dataPTS;
                       pkt.pts = pkt.dts= packet.header.dataPTS;*/
                       pkt.pts = pkt.dts = AV_NOPTS_VALUE;

                       if(framebuff != NULL)
                       {
                         //printf("Framebuff has mem alloc : freeing 1\n\n");
                         free(framebuff);
                         framebuff = NULL;
                         //printf("free successfully \n\n");
                       }


                       nal_unit_length = GetOneNalUnit(&nal_unit_type, packet.data + cursor/*pData+cursor*/, size-cursor);
                       if(nal_unit_length > 0 && nal_unit_type > 0)
                       {

                       }
                       else
                       {
                         printf("Fatal error : nal unit lenth wrong \n\n");
                         exit(0);
                       }
                       write_header_done = 1;
                       //#define _USE_SPS_PPS    //comment this line to write everything on to the stream. SPS+PPSframeframe
                       #ifdef _USE_SPS_PPS
                       if (nal_unit_type == 0x07 /*NAL_SPS*/)
                       { // write sps


                         printf("Got SPS \n");
                         if (_sps == NULL)
                         {
                           _sps_size = nal_unit_length -4;
                           _sps = new U8[_sps_size];
                           memcpy(_sps, packet.data+cursor+4, _sps_size); //exclude start code 0x00000001
                         }

                       }
                       else if (nal_unit_type == 0x08/*NAL_PPS*/)
                       { // write pps

                         printf("Got PPS \n");
                         if (_pps == NULL)
                         {
                           _pps_size = nal_unit_length -4;
                           _pps = new U8[_pps_size];
                           memcpy(_pps, packet.data+cursor+4, _pps_size); //exclude start code 0x00000001

                           //out_stream->codec->extradata
                           //ofmt_ctx->streams[outputVideoStreamIndex]->codec->extradata
                           free(ofmt_ctx->streams[outputVideoStreamIndex]->codec->extradata);
                           ofmt_ctx->streams[outputVideoStreamIndex]->codec->extradata = (uint8_t*)av_mallocz(_sps_size + _pps_size);

                           memcpy(ofmt_ctx->streams[outputVideoStreamIndex]->codec->extradata,_sps,_sps_size);
                           memcpy(ofmt_ctx->streams[outputVideoStreamIndex]->codec->extradata + _sps_size,_pps,_pps_size);
                           ret = avformat_write_header(ofmt_ctx, NULL);
                           if (ret < 0) {
                                 //fprintf(stderr, "Error occurred when opening output file\n");
                                 printf("Error occured when opening output \n");
                                 exit(0);
                            }
                            write_header_done = 1;
                           printf("Done writing header \n");

                         }

                       }
                       //else
                       #endif  /*end _USE_SPS_PPS */
                       { //IDR Frame

                           videoPts++;
                           if( (nal_unit_type == 0x06) || (nal_unit_type == 0x09) || (nal_unit_type == 0x07) || (nal_unit_type == 0x08))
                           {
                             av_free_packet(&pkt);
                             cursor += nal_unit_length;
                             continue;
                           }

                         if( (nal_unit_type == 0x05) || (nal_unit_type == 0x05))
                         {
                           //videoPts++;
                         }
                         if ((nal_unit_type != 0x07) && (nal_unit_type != 0x08))
                         {

                           vDuration += (packet.header.dataPTS - lastvPts);
                           lastvPts = packet.header.dataPTS;
                           //pkt.pts = pkt.dts= packet.header.dataPTS;
                           pkt.pts = pkt.dts= AV_NOPTS_VALUE;//videoPts;
                         }
                         else
                         {
                           //probably sps pps ... no need to transmit. free the packet
                           //av_free_packet(&pkt);
                           pkt.pts = pkt.dts = AV_NOPTS_VALUE;
                         }


                         currFrameLength  = nal_unit_length - 4;//packet.header.dataLen -4;
                         tempCurrFrameLength[3] = currFrameLength;
                         tempCurrFrameLength[2] = currFrameLength>>8;
                         tempCurrFrameLength[1] = currFrameLength>>16;
                         tempCurrFrameLength[0] = currFrameLength>>24;



                         if(nal_unit_type == 0x05)
                         {  
                           pkt.flags        |= AV_PKT_FLAG_KEY;
                         }


                         framebuff = (unsigned char *)malloc(sizeof(unsigned char)* /*packet.header.dataLen*/nal_unit_length );
                         if(framebuff == NULL)
                         {
                           printf("Failed to allocate memory for frame \n\n ");
                           exit(0);
                         }


                         memcpy(framebuff, tempCurrFrameLength,0x04);
                         //memcpy(&framebuff[4], &packet.data[4] , currFrameLength);
                         //put_buffer(pData + cursor + 4, nal_unit_length - 4);// save ES data
                         memcpy(framebuff+4,packet.data + cursor + 4, currFrameLength );
                         pkt.data = framebuff;
                         pkt.size = nal_unit_length;//packet.header.dataLen ;

                         //printf("\nPrinting Frame| Size: %d | NALU Lenght: %d | NALU: %02x \n",pkt.size,nal_unit_length ,nal_unit_type);

                         /* GET READY TO TRANSMIT THE packet */
                         //pkt.duration = vDuration;
                         in_stream  = ifmt_ctx->streams[pkt.stream_index];
                         out_stream = ofmt_ctx->streams[outStreamIndex];
                         cn = out_stream->codec;
                         //av_packet_rescale_ts(&pkt, cn->time_base, out_stream->time_base);
                         //pkt.pts = av_rescale_q_rnd(pkt.pts, in_stream->time_base, out_stream->time_base, AV_ROUND_NEAR_INF|AV_ROUND_PASS_MINMAX);
                         //pkt.dts = av_rescale_q_rnd(pkt.dts, in_stream->time_base, out_stream->time_base, AV_ROUND_NEAR_INF|AV_ROUND_PASS_MINMAX);
                         //pkt.duration = av_rescale_q(pkt.duration, in_stream->time_base, out_stream->time_base);
                         pkt.pos = -1;
                         pkt.stream_index = outStreamIndex;

                          if (!write_header_done)
                          {
                           }
                           else
                           {
                         //doxygen suggests i use av_write_frame if i am taking care of interleaving
                         ret = av_interleaved_write_frame(ofmt_ctx, &pkt);
                         //ret = av_write_frame(ofmt_ctx, &pkt);
                         if (ret < 0)
                          {
                              fprintf(stderr, "Error muxing Video packet\n");
                              continue;
                          }
                          }

                         /*for(int ii = 0; ii < pkt.size ; ii++)
                           printf("%02x ",framebuff[ii]);*/

                          av_free_packet(&pkt);
                          if(framebuff != NULL)
                           {
                             //printf("Framebuff has mem alloc : freeing 2\n\n");
                             free(framebuff);
                             framebuff = NULL;
                             //printf("Freeing successfully \n\n");
                           }

                         /* TRANSMIT DONE */

                       }
                     cursor += nal_unit_length;
                     }while(cursor < size);


               }
               else
               {
                 printf("This is not annex B bitstream \n\n");
                 for(int ii = 0; ii < packet.header.dataLen ; ii++)
                   printf("%02x ",packet.data[ii]);
                 printf("\n\n");
                 exit(0);
               }

               //video frame has been parsed completely.
               continue;

             }
           else if(packet.header.dataType == TRANSFER_PACKET_TYPE_AAC)
             {

               av_init_packet(&pkt);


               pkt.flags = 1;          
               pkt.pts = audioPts*1024;
               pkt.dts = audioPts*1024;
               //pkt.duration = 1024;    

               pkt.stream_index  = packet.header.streamId + 1;//1;//ost->st->index;     //stream index 0 for vid : 1 for aud
               outStreamIndex = outputAudioStreamIndex;
               //aDuration += (packet.header.dataPTS - lastaPts);
               //lastaPts = packet.header.dataPTS;

               //NOTE: audio sync requires this value
               pkt.pts = pkt.dts= AV_NOPTS_VALUE ;
               //pkt.pts = pkt.dts=audioPts++;
               pkt.data = (uint8_t *)packet.data;//raw_data;
               pkt.size          = packet.header.dataLen;
             }


           //packet.header.streamId
           //now assigning pkt.data in repsective if statements above
           //pkt.data          = (uint8_t *)packet.data;//raw_data;
           //pkt.size          = packet.header.dataLen;


           //pkt.duration = 24000;      //24000 assumed basd on observation

           //duration calculation
           /*if(packet.header.dataType == TRANSFER_PACKET_TYPE_H264)
             {
               pkt.duration = vDuration;

             }
           else*/ if(packet.header.dataType == TRANSFER_PACKET_TYPE_AAC)
             {
               //pkt.duration = aDuration;
             }

           in_stream  = ifmt_ctx->streams[pkt.stream_index];
           out_stream = ofmt_ctx->streams[outStreamIndex];

           cn = out_stream->codec;

           if(packet.header.dataType == TRANSFER_PACKET_TYPE_AAC)
            ret= av_bitstream_filter_filter(aacbsfc, in_stream->codec, NULL, &pkt.data, &pkt.size, packet.data/*pkt.data*/, packet.header.dataLen, pkt.flags & AV_PKT_FLAG_KEY);

             if(ret < 0)
             {
               printf("Failed to execute aac bitstream filter \n\n");
               exit(0);
             }

           //if(packet.header.dataType == TRANSFER_PACKET_TYPE_H264)
           // av_bitstream_filter_filter(h264bsfc, in_stream->codec, NULL, &pkt.data, &pkt.size, packet.data/*pkt.data*/, pkt.size, 0);

             pkt.flags = 1;              


              //NOTE : Commented the lines below synced audio and video streams

             //av_packet_rescale_ts(&pkt, cn->time_base, out_stream->time_base);

             //pkt.pts = av_rescale_q_rnd(pkt.pts, in_stream->time_base, out_stream->time_base, AV_ROUND_NEAR_INF|AV_ROUND_PASS_MINMAX);

             //pkt.dts = av_rescale_q_rnd(pkt.dts, in_stream->time_base, out_stream->time_base, AV_ROUND_NEAR_INF|AV_ROUND_PASS_MINMAX);


             //pkt.duration = av_rescale_q(pkt.duration, in_stream->time_base, out_stream->time_base);



           //enabled on Tuesday
           pkt.pos = -1;

           pkt.stream_index = outStreamIndex;

           //doxygen suggests i use av_write_frame if i am taking care of interleaving
           ret = av_interleaved_write_frame(ofmt_ctx, &pkt);
           //ret = av_write_frame(ofmt_ctx, &pkt);
           if (ret < 0)
            {
                fprintf(stderr, "Error muxing packet\n");
                continue;
            }

          av_free_packet(&pkt);
          if(framebuff != NULL)
           {
             //printf("Framebuff has mem alloc : freeing 2\n\n");
             free(framebuff);
             framebuff = NULL;
             //printf("Freeing successfully \n\n");
           }
         }
  • How to make Matomo GDPR compliant in 12 steps

    3 avril 2018, par InnoCraft

    Important note : this blog post has been written by digital analysts, not lawyers. The purpose of this article is to briefly show you where Matomo is entering into play within the GDPR process. This work comes from our interpretation of the UK privacy commission : ICO. It cannot be considered as professional legal advice. So as GDPR, this information is subject to change. We strongly advise you to have a look at the different privacy authorities in order to have up to date information.

    The General Data Protection Regulation (EU) 2016/679, also referred to RGPD in French, Datenschutz-Grundverordnung, DS-GVO in German, is a regulation on data protection and privacy for all individuals within the European Union. It concerns organizations worldwide dealing with EU citizens and will come into force on the 25th May 2018.

    The GDPR applies to ‘personal data’ meaning any information relating to an identifiable person who can be directly or indirectly identified in particular by reference to an identifier. It includes cookies, IP addresses, User ID, location, and any other data you may have collected.

    We will list below the 12 steps recommended by the UK privacy commissioner in order to be GDPR compliant and what you need to do for each step.

    The 12 steps of GDPR compliance according to ICO and how it fit with Matomo

    As mentioned in one of our previous blog post about GDPR, if you are not collecting any personal data with Matomo, then you are not concerned about what is written below.

    If you are processing personal data in any way, here are the 12 steps to follow along with some recommendations on how to be GDPR compliant with Matomo :

    1 – Awareness

    Make sure that people within your organization know that you are using Matomo in order to analyze traffic on the website/app. If needed, send them the link to the “What is Matomo ?” page.

    2 – Information you hold

    List all the personal data you are processing with Matomo within your record of processing activities. We are personally using the template provided by ICO which is composed of a set of 30 questions you need to answer regarding your use of Matomo. We have published an article which walks you through the list of questions specifically in the use case of Matomo Analytics. Please be aware that personal data may be also tracked in non-obvious ways for example as part of page URLs or page titles.

    3 – Communicating privacy information

    a – Add a privacy notice

    Add a privacy notice wherever you are using Matomo in order to collect personal data. Please refer to the ICO documentation in order to learn how to write a privacy notice. You can learn more in our article about creating your privacy notice for Matomo Analytics. Make sure that a privacy policy link is always available on your website or app.

    b – Add Matomo to your privacy policy page

    Add Matomo to the list of technologies you are using on your privacy policy page and add all the necessary information to it as requested in the following checklist. To learn more check out our article about Privacy policy.

    4 – Individuals’ rights

    Make sure that your Matomo installation respects all the individuals’ rights. To make it short, you will need to know the features in Matomo that you need to use to respect user rights (right of access, right of rectification, right of erasure…). These features are available starting in Matomo 3.5.0 released on May 8th : GDPR tools for Matomo (User guide).

    5 – Subject access requests

    Make sure that you are able to answer an access request from a data subject for Matomo. For example, when a person would like to access her or his personal data that you have collected about her or him, then you will need to be you able to provide her or him with this information. We recommend you design a process for this like “Who is dealing with it ?” and check that it is working. If you can answer to the nightmare letter, then you are ready. The needed features for this in Matomo will be available soon.

    6 – Lawful basis for processing personal data

    There are different lawful basis you can use under GDPR. It can be either “Legitimate interest” or “Explicit consent”. Do not forget to mention it within your privacy policy page. Read more in our article about lawful basis.

    7 – Consent

    Users should be able to remove their consent at any time. By chance, Matomo is providing a feature in order to do just that : add the opt-out feature to your privacy policy page.
    We are also offering a tool that allows you optionally to require consent before any data is tracked. This will be useful if a person should be only tracked after she or he has given explicit consent to be tracked.

    8 – Children

    If your website or app is targeted for children and you are using Matomo, extra measures will need to be taken. For example you will need to write your privacy policy even more clear and moreover getting parents consent if the child is below 13. As it is a very specific case, we strongly recommend you to follow this link for further information.

    9 – Data breaches

    As you may be collecting personal data with Matomo, you should also check your “data breach procedure” to define if a leak may have consequences on the privacy of the data subject. Please consult ICO’s website for further information.

    10 – Data Protection by Design and Data Protection Impact Assessments

    Ask yourself if you really need to process personal data within Matomo. If the data you are processing within Matomo is sensitive, we strongly recommend you to make a Data Protection Impact Assessment. A software is available from the The open source PIA software helps to carry out data protection impact assessment, by French Privacy Commissioner : CNIL.

    11 – Data Protection Officers

    If you are reading this article and you are the Data Protection Officer (DPO), you will not be concerned by this step. If that’s not the case, your duty is to provide to the DPO (if your business has a DPO) our blog post in order for her or him to ask you questions regarding your use of Matomo. Note that your DPO can also be interested in the different data that Matomo can process : “What data does Matomo track ?” (FAQ).

    12 – International

    Matomo data is hosted wherever you want. So according to the location of the data, you will need to show specific safeguard except for EU. For example regarding the USA, you will have to check if your web hosting platform is registered to the Privacy Shield : privacyshield.gov/list
    Note : our Matomo cloud infrastructure is based in France.

    That’s the end of this blog post. As GDPR is a huge topic, we will release many more blog posts in the upcoming weeks. If there are any Matomo GDPR topic related posts you would like us to write, please feel free to contact us.

    The post How to make Matomo GDPR compliant in 12 steps appeared first on Analytics Platform - Matomo.

  • A *hot* Piwik Community Meetup 2015 !

    10 août 2015 — Community

    Last weekend I arrived in Germany to attend the Piwik Community Meetup 2015 and now I am in Poland. I joined Piwik PRO back in May as enterprise support project coordinator in North America. I am now writing this from the Piwik PRO main office in Wrocław, where I’ll be working from for the next two weeks.

    The meetup was HOT in every sense ! Berlin temperatures reached 35 degrees (celsius), as I finally meet in person several long-time, dedicated Piwik community contributors.

    Meetup preparation in Berlin, photo by M. Zawadziński, licensed under CC-BY-SA 4.0

    Pictures from the meetup preparation sessions

    In the first leg of my trip I was in Berlin to meet Piwik community members and Piwik PRO staff to prepare for the 2015 annual Piwik community meetup. These are my notes taken during the meeting at the request of one of my colleagues. I also relayed live on Framasphère, Twitter and IRC.

    Community discussion at the meetup, photo by D.Czajka, licensed under CC-BY-SA 4.0

    More pictures from the Piwik meetup

    This was harder than I expected, as I took notes with my laptop, pictures with my phone, wrote live to social media (using the Android Diaspora Native Web App), and used my laptop to relay on IRC. Going forward this requires better preparation, I was glad I had a few links and pictures ready before hand but it really requires intense focus to achieve this. I am glad presenters were patient when I requested repeating some of the ideas they shared. I am also a bit disappointed not much happened in IRC.

    Two day preparation sessions

    The discussions and session we had during the two days prior to the meetup are available here.

    We gathered in rented apartments in Berlin, this reminded me very much of similar community gatherings and perhaps of BarCamp and, at a much smaller scale, UDS sessions.

    Piwik Pizza !, photo by F. Rodríguez, licensed under CC-BY-SA 4.0

    A list of ideas of topics was initially submitted, we then proceeded to have scheduled sessions for open discussion. Several people shared their concern there was no possible remote participation which led to making public the Trello boards used/linked here.

    Note : The Trello links below still have action items and notes that are pending bug report / feature requests filing which should happen over the coming weeks. Most importantly, many action items will need identifying leads for different community team including Translations and Documentation, and better coordination of coming community engagement.

    Monday sessions consisted of the following subjects :

    On Tuesday we met again to discuss the following subjects :

    Some more details about individual preparation sessions

    What are Piwik values & how to communicate them ?

    The main subjects in this session were important changes proposed in the project mission and values. This was edited directly on on the wiki page on GitHub, some of the changes can be seen by comparing revisions.

    Piwik mission statement (bug #7376)

    “To create the leading Free and open source analytics platform, and to support global organisations and communities to keep full control over their data.”

    Our values

    • Openness
    • Freedom
    • Transparency
    • Data ownership
    • Privacy
    • Kaizen (改善) : continuous improvement

    This was also presented by Matthieu Aubry at the meetup and is published in the Roadmap page. Bringing more visibility and perhaps having a top page for Mission and Values was also brought up.

    Meetup agenda and notes

    The official agenda is available here.

    Many Piwik PRO employees stayed in Berlin for the meetup, and we had good participation although less than last year in Munich as my colleagues told me. Some were consultants, others staff from public organizations, universities, etc. In retrospect considering the very hot weather and summer holidays the attendance was good. I was very happy to arrive at the beautiful Kulturbrauerei and enter the air-conditioned Soda Club. T-Shirts were waiting for all attendees and free drinks (non-alcohol !) were welcome