Recherche avancée

Médias (0)

Mot : - Tags -/objet éditorial

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

Autres articles (28)

  • List of compatible distributions

    26 avril 2011, par

    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 (...)

  • Use, discuss, criticize

    13 avril 2011, par

    Talk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
    The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
    A discussion list is available for all exchanges between users.

  • Automated installation script of MediaSPIP

    25 avril 2011, par

    To overcome the difficulties mainly due to the installation of server side software dependencies, an "all-in-one" installation script written in bash was created to facilitate this step on a server with a compatible Linux distribution.
    You must have access to your server via SSH and a root account to use it, which will install the dependencies. Contact your provider if you do not have that.
    The documentation of the use of this installation script is available here.
    The code of this (...)

Sur d’autres sites (6438)

  • Your guide to cookies, web analytics, and GDPR compliance

    25 février 2020, par Joselyn Khor — Analytics Tips, Privacy, Security

    It’s been almost two years since the GDPR came into effect and turned the online world on its head. Confusion around cookies/cookie consent/cookie compliance remains till today. So we’d like to take this chance to talk more about the supposed “big bad” of the latest century. 

    Online cookies seem to have a bad reputation, but are they as bad as they seem ?

    To start, what are cookies on the internet ?

    An internet cookie a.k.a. an HTTP cookie, is a small piece of data sent from websites that is stored on your computer or mobile when you visit that site.

    Are all cookies bad ?

    No. Cookies themselves are usually harmless as they can’t infect computers with malware. 

    They can also be helpful for both websites who use them and individuals visiting those websites. For example, when online shopping, cookies on ecommerce sites keep track of what you’re shopping for. If you didn’t have that tracking, your cart would be empty every time you moved away from that site.

    For businesses/websites, cookies can be used for authentication (logins) and tracking website user experience. For example, tracking multiple visits to the same site in order to provide better experiences to customers visiting their website.

    internet cookies tracking

    The not-so-sweet types of cookies :

    Cookies that contain personal data

    Another example of a bad cookie is when cookies contain personal data directly in the cookie itself. For example, when websites store demographics or your name in a cookie ; or when a website stores survey results in a cookie. Use of cookies in these ways is considered bad practice nowadays.

    Third-party cookies

    They can be used by websites to learn about your visit and activity across multiple websites. Cookies can enter harmful territory when employed for “big brother” types of tracking i.e. when they’re used to build a virtual fingerprint of individuals after their activity is tracked from website to website. For example most advertising networks create third party cookies in your browser when you view an ad, which lets these advertisers track users across these websites and let companies buy more targeted ads.

    Why does Matomo use cookies ?

    web analytics cookies

    For accurate reporting of new and returning visitors. Matomo uses cookies to store some information about visitors between visits. We also use cookies to remember if someone gave consent to tracking, or opted out of tracking. 

    Types of cookies Matomo uses :

    • Matomo by default uses first-party cookies, set on the domain of your site.
    • Cookies created by Matomo start with : _pk_ref_pk_cvar_pk_id_pk_ses. See a list of all Matomo cookies : https://matomo.org/faq/general/faq_146/

    Cookie-less tracking - disable cookies and ensure cookie compliance :

    It’s possible to disable tracking cookies in Matomo by adding a line on the javascript code. When cookies are disabled, Matomo data will become slightly less accurateAlso, when cookies are disabled, there may still be a few cookies created in specific cases.

    If you disable cookies, Matomo tries to detect unique visitors by a fingerprint based on a few browser attributes : operating system, browser, browser plugins, IP address and browser language.

    By disabling tracking cookies, you may also use Matomo without needing to display a cookie consent screen. You can also keep tracking when they reject cookie consent by keeping cookies disabled.

    Cookies and the GDPR

    In some countries and according to the GDPR, websites need to provide a way for users to opt-out of all tracking, in particular tracking cookies.

    The GDPR regulates the use of cookies when they compromise an individual’s privacy. When cookies can identify an individual, it is considered personal data.

    cookies and GDPR

    Cookie compliance and the GDPR

    To be GDPR compliant you must :

    • Receive user consent before using any cookies (except strictly necessary cookies). Read more on cookies that are “clearly exempt from consent”.
    • Provide accurate and specific information about the data each cookie tracks and its purpose in plain language before consent is received.
    • Document and store consent received from users.
    • Allow users to access your service even if they refuse to allow the use of certain cookies
    • Make it as easy for users to withdraw their consent as it was for them to give their consent in the first place.

    Source : https://gdpr.eu/cookies/

    When does GDPR require cookie consent ?

    The purpose of the GDPR is to give individuals control over their personal data. As such this regulation has provisions and requirements which regulate the processing of personal data to protect the privacy of individuals. 

    This means in order to use cookies, you will sometimes need explicit consent from those individuals.

    When does GDPR not require cookie consent ?

    Then there are many cookies that generally do NOT require consent (Source : https://wikis.ec.europa.eu/display/WEBGUIDE/04.+Cookies). 

    These are :

    • user input cookies, for the duration of a session
    • authentication cookies, for the duration of a session
    • user-centric security cookies, used to detect authentication abuses and linked to the functionality explicitly requested by the user, for a limited persistent duration
    • multimedia content player session cookies, such as flash player cookies, for the duration of a session
    • load balancing session cookies and other technical cookies, for the duration of session
    • user interface customisation cookies, for a browser session or a few hours, when additional information in a prominent location is provided (e.g. “uses cookies” written next to the customisation feature)

    Tracking cookies and consent vs legitimate interest

    cookie consent and GDPR legitimate interests

    User consent is not always required :

    We understand that whenever you collect and process personal data, you need – almost always – to ask for their consent. However, there are instances where you have to process data under “legitimate interests”. The GDPR states that processing of personal data is lawful “if processing is necessary for the purposes of the legitimate interests”. This means if you have “legitimate interests” you can avoid asking for consent for collecting and processing personal information. Learn more : https://cookieinformation.com/resources/blog/what-is-legitimate-interest-under-the-gdpr 

    A lawful basis for processing personal data (proceeding with caution) :

    We’ve also written about having a lawful basis for processing personal data under GDPR with Matomo. The caveat here is you need to have a strong argument for legitimate interests. If you are processing personal data which may represent a risk to the final user, then getting consent is, for us, still the right lawful basis. If you are not sure, at the time of writing ICO is providing a tool in order to help you make this decision.

    How is Matomo Analytics GDPR compliant ?

    Matomo can be configured to automatically anonymise data so you don’t process any personal data. This allows you to completely avoid GDPR. If you decide to process personal data, Matomo provides you with 12 steps to easily comply with the GDPR guidelines.

    New developments on cookies and the GDPR

    In the early days of the GDPR, a spate of cookie management platforms (CMPs) popped up to help websites and people comply with GDPR rules around cookies.

    These have become problematic in recent years. Europe’s highest court ruled pre-checked box for cookie boxes does not give enough consent

    As well as that, new research suggests most cookie consent pop-ups in the EU fall short of GDPR. A new study called, ‘Dark Patterns after the GDPR’ from MIT, UCL and Aarhus University found that a vast majority of websites aren’t following GDPR rules around cookies. The study found most cookie consent pop-ups in the EU to be undermining the GDPR by finding sneaky ways to convince website visitors to click ‘accept’.

    Disclaimer

    We are not lawyers and don’t claim to be. The information provided here is to help give an introduction to issues you may encounter when dealing cookies. We encourage every business and website to take data privacy seriously and discuss these issues with your lawyer if you have any concerns. 

    Additional resources :

  • record rtsp stream to file(muxing)

    11 avril 2014, par user3521863
    AVFormatContext *g_oc = NULL;
    AVStream *g_in_audio_st, *g_in_video_st;
    AVStream *g_out_audio_st, *g_out_video_st;
    int audio_pts = 0, video_pts = 0, audio_dts = 0, video_dts = 0;
    int last_video_pts = 0;
    AVPacket outpkt, *av_pkt;

    // initialize video codec
    static void init_video_codec(AVFormatContext *context) {
       LOGI(1, "enter init_video_codec");
       AVFormatContext *in_format_ctx = NULL;
       AVCodecContext *avcodec_ctx = NULL;
       int fps = 0;

       if(context->streams[1]->r_frame_rate.num != AV_NOPTS_VALUE &&
               context->streams[1]->r_frame_rate.den != 0)
           fps = context->streams[1]->r_frame_rate.num / context->streams[1]->r_frame_rate.den;
       else
           fps = 25;

       g_out_video_st = avformat_new_stream(g_oc, context->streams[1]->codec->codec);
       LOGI(1, "video avformat_new_stream");
       if( g_out_video_st == NULL ) {
           LOGE(1, "Fail to Allocate Output Video Stream");
           return ;
       }
       else {
           LOGI(1, "Allocated Video Stream");
           if( avcodec_copy_context(g_out_video_st->codec, context->streams[1]->codec) != 0 ) {
               LOGE(1, "Failed to video Copy Context");

               return ;
           }
           else {
               LOGI(1, "Success to video Copy Context");
    // how to setting video stream parameter?

               g_out_video_st->sample_aspect_ratio.den = g_in_video_st->codec->sample_aspect_ratio.den;
               g_out_video_st->sample_aspect_ratio.num = g_in_video_st->codec->sample_aspect_ratio.num;
               g_out_video_st->codec->codec_id         = g_in_video_st->codec->codec->id;
               g_out_video_st->codec->time_base.num    = 1;
               g_out_video_st->codec->time_base.den    = fps * (g_in_video_st->codec->ticks_per_frame);
               g_out_video_st->time_base.num           = 1;
               g_out_video_st->time_base.den           = 1000;
               g_out_video_st->r_frame_rate.num        = fps;
               g_out_video_st->r_frame_rate.den        = 1;
               g_out_video_st->avg_frame_rate.den      = 1;
               g_out_video_st->avg_frame_rate.num      = fps;
               g_out_video_st->codec->width            = g_frame_width;
               g_out_video_st->codec->height           = g_frame_height;
               g_out_video_st->codec->flags |= CODEC_FLAG_GLOBAL_HEADER;
           }
       }

       LOGI(1, "end video init");
    }

    // initialize audio codec
    static void init_audio_codec(AVFormatContext *context) {
       LOGI(1, "enter init_audio_codec");
       AVFormatContext *in_format_ctx = NULL;
       AVCodecContext *avcodec_ctx = NULL;

       g_out_audio_st = avformat_new_stream(g_oc, context->streams[0]->codec->codec);
       LOGI(1, "audio avformat_new_stream");
       if( avcodec_copy_context(g_out_audio_st->codec, context->streams[0]->codec) != 0 ) {
           LOGE(1, "Failed to Copy audio Context");

           return ;
       }
       else {
           LOGI(1, "Success to Copy audio Context");
    // how to setting video stream parameter?
           g_out_audio_st->codec->codec_id         = g_in_audio_st->codec->codec_id;
           g_out_audio_st->codec->codec_tag        = 0;
           g_out_audio_st->pts                     = g_in_audio_st->pts;
           g_out_audio_st->time_base.num           = g_in_audio_st->time_base.num;
           g_out_audio_st->time_base.den           = g_in_audio_st->time_base.den;
           g_out_audio_st->codec->flags |= CODEC_FLAG_GLOBAL_HEADER;
       }

       LOGI(1, "end init audio");
    }

    // write video stream
    static void write_video_stream(AVPacket *pkt) {
       av_pkt = NULL;
       av_pkt = pkt;

       if( pkt == NULL || sizeof(*pkt) == 0 )
           return;

       av_rescale_q(av_pkt->pts, g_in_video_st->time_base, g_in_video_st->codec->time_base);
       av_rescale_q(av_pkt->dts, g_in_video_st->time_base, g_in_video_st->codec->time_base);

       av_init_packet(&outpkt);

       if( av_pkt->pts != AV_NOPTS_VALUE ) {
           if( last_video_pts == video_pts ) {
               video_pts++;
               last_video_pts = video_pts;
           }
           outpkt.pts = video_pts;
       }
       else {
           outpkt.pts = AV_NOPTS_VALUE;
       }

       if( av_pkt->dts == AV_NOPTS_VALUE )
           outpkt.dts = AV_NOPTS_VALUE;
       else
           outpkt.dts = video_pts;

       outpkt.data = av_pkt->data;
       outpkt.size = av_pkt->size;
       outpkt.stream_index = av_pkt->stream_index;
       outpkt.flags |= AV_PKT_FLAG_KEY;
       last_video_pts = video_pts;

       if(av_interleaved_write_frame(g_oc, &outpkt) < 0) {
    //  if(av_write_frame(g_oc, &outpkt) < 0) {
           LOGE(1, "Failed Video Write");
       }
       else {
           g_out_video_st->codec->frame_number++;
       }

       if( !&outpkt || sizeof(outpkt) == 0 )
           return;
       if( !av_pkt || sizeof(*av_pkt) == 0 )
           return;

       av_free_packet(&outpkt);
    }

    // write audio stream
    static void write_audio_stream(AVPacket *pkt) {
       av_pkt = NULL;
       av_pkt = pkt;

       if( pkt == NULL || sizeof(*pkt) == 0 )
               return;

       av_rescale_q(av_pkt->pts, g_in_audio_st->time_base, g_in_audio_st->codec->time_base);
       av_rescale_q(av_pkt->dts, g_in_audio_st->time_base, g_in_audio_st->codec->time_base);

       av_init_packet(&outpkt);

       if(av_pkt->pts != AV_NOPTS_VALUE)
           outpkt.pts = audio_pts;
       else
           outpkt.pts = AV_NOPTS_VALUE;

       if(av_pkt->dts == AV_NOPTS_VALUE)
           outpkt.dts = AV_NOPTS_VALUE;
       else {
           outpkt.dts = audio_pts;

           if( outpkt.pts >= outpkt.dts)
               outpkt.dts = outpkt.pts;

           if(outpkt.dts == audio_dts)
               outpkt.dts++;

           if(outpkt.pts < outpkt.dts) {
               outpkt.pts = outpkt.dts;
               audio_pts = outpkt.pts;
           }

           outpkt.data = av_pkt->data;
           outpkt.size = av_pkt->size;
           outpkt.stream_index = av_pkt->stream_index;
           outpkt.flags |= AV_PKT_FLAG_KEY;
           video_pts = audio_pts;
           audio_pts++;

           if( av_interleaved_write_frame(g_oc, &outpkt) < 0 ) {
    //      if( av_write_frame(g_oc, &outpkt) < 0 ) {
               LOGE(1, "Failed Audio Write");
           }
           else {
               g_out_audio_st->codec->frame_number++;
           }

           if( !&outpkt || sizeof(outpkt) == 0 )
               return;
           if( !av_pkt || sizeof(*av_pkt) == 0 )
               return;

           av_free_packet(&outpkt);
       }
    }

    here result : recorded file
    here full source : player.c

    I want to record rtsp stream to file on playing
    i try tested video and audio streams while changing the parameters
    but this result file does not match sync between video and audio
    i try search about ffmpeg but almost command run or video recording was only.
    please advice me.

  • FFmpeg -segment with a lot of time codes

    24 février 2020, par Grenight

    I’m making program that splits videos for running parallel encodes.

    My problem is that with putting all segments into command like i can hit a limit of maximum characters in windows console. Approximately 600, while 1-2 hour movie can easily be 1000-2000 scenes.

    Is there a way to use .csv file for segment so i don’t need to put all time codes to command line ? Or is there another ways ?

    Here is example of command line that is used in program :
    timecodes is where all time codes passed.

    cmd = f'{self.FFMPEG} -i {video} -map_metadata 0 -an -f segment -segment_times {timecodes} -c copy -avoid_negative_ts 1 {self.temp_dir / "split" / "%04d.mkv"}