Recherche avancée

Médias (91)

Autres articles (105)

  • Encoding and processing into web-friendly formats

    13 avril 2011, par

    MediaSPIP automatically converts uploaded files to internet-compatible formats.
    Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
    Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
    Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
    All uploaded files are stored online in their original format, so you can (...)

  • Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs

    12 avril 2011, par

    La manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
    Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras.

  • Gestion de la ferme

    2 mars 2010, par

    La ferme est gérée dans son ensemble par des "super admins".
    Certains réglages peuvent être fais afin de réguler les besoins des différents canaux.
    Dans un premier temps il utilise le plugin "Gestion de mutualisation"

Sur d’autres sites (11513)

  • Packet (AV_PIX_FMT_UYVY422) to Planar (AV_PIX_FMT_YUVJ422P) format conversion

    25 août 2017, par user3743908

    My image format is "YUV422_8_UYVY" which is packed AV_PIX_FMT_UYVY422 format, i am trying to convert it in Planar "AV_PIX_FMT_YUVJ422P", but not able to succeed yet, below is the code on which i am working.

    error message : [swscaler @ 004b3fa0] deprecetd pixel format used, make sure you did set range correctly

    resultant image (file ) having 0 k size

    what would be the last argument of av_image_alloc() for conversion like 16,32 etc

    my aim to convert packet yuv image in planar yuv format

       static  AVCodecContext      *pCodecCtx;
       static  AVFormatContext     *pFormatCtx;
       static  AVCodec             *pCodec;
       static  AVOutputFormat*     fmt;
       static  AVFrame             *RawPic;
       static  AVFrame             *ScalePic;
       static  AVPacket            pkt;
       static  AVStream*           video_st;
       static  FILE                *file;
       static  struct SwsContext   *sws_ctx;

    enum    AVPixelFormat       src_pix_fmt     =   AV_PIX_FMT_UYVY422;
    enum    AVPixelFormat       dst_pix_fmt     =   AV_PIX_FMT_YUVJ422P;

    int main(  ) {

           FILE    *in_file            =   NULL;               //packed Source
           FILE    *out_file           =   NULL;               //planar output
            int        in_width        =   2448;               //YUV's width
            int        in_height       =   2050;               //YUV's heigh

            int        out_width       =   2448;               //YUV's width
            int        out_height      =   2050;               //YUV's heigh


           unsigned long int       ret;

           in_file = fopen("c:\\yuv422_8_uyvy.yuv","rb");      //Source Input File
           if(in_file == NULL) { printf("\n\tinput File Opening error...!!"); exit(1); }



           out_file = fopen("d:\\test_Planar.yuv", "wb");              //Source Input File
           if(out_file == NULL) {  printf("\n\toutput File Opening error...!!"); exit(1); }
           else                 {  printf("\n\tOutput File Created...!!");  }  


    //------Loads the whole database of available codecs and formats------
           av_register_all();  
           printf("\t\n\tCodac database Loaded...\n");

    //------Contex Variable assignment--------------------------------
           pFormatCtx              =   avformat_alloc_context();      
           fmt                     =   NULL;
           fmt                     =   av_guess_format("mjpeg",NULL,NULL);
           pFormatCtx->oformat     =   fmt;


           video_st = avformat_new_stream(pFormatCtx, 0);  if (video_st==NULL)    return -1;

           pCodecCtx               =   video_st->codec;
           pCodecCtx->codec_id     =   fmt->video_codec;
           pCodecCtx->codec_type   =   AVMEDIA_TYPE_VIDEO;
           pCodecCtx->pix_fmt      =   src_pix_fmt;
           printf("\t\n\tContex Variable assigned...\n");

    //------Allocate Source Image Buffer--------------------------------
           AVFrame *RawPic =   av_frame_alloc();  
           if(!RawPic) {   printf("\nCould not allocate Raw Image frame\n");   exit(1);}
           RawPic->format  =   pCodecCtx->pix_fmt;
           RawPic->width   =   in_width;
           RawPic->height  =   in_height;      
           ret =   av_image_alloc(RawPic->data,RawPic->linesize,in_width,in_height,src_pix_fmt, 16);
           if(ret < 0) {   printf("\nCould not allocate raw picture buffer\n"); exit(1);}
           printf("\n\tAllocate Source Image Buffer");

    //------Allocate Desitnation Image Buffer-------------------
           AVFrame *ScalePic   =   av_frame_alloc();
           if(!ScalePic)   {   printf("\nCould not allocate Scale Image frame\n"); exit(1);}      
           ScalePic->format    =   pCodecCtx->pix_fmt;
           ScalePic->width     =   out_width;
           ScalePic->height    =   out_height;    
           ret =   av_image_alloc(ScalePic->data,ScalePic->linesize,out_width,out_height,dst_pix_fmt, 32);
           if(ret < 0) {   printf("\nCould not allocate Scale picture buffer\n"); exit(1);}
           dst_bufsize =   ret;
           printf("\n\tAllocate Destination Image Buffer");


    //------Create scaling context------------------------------sws_getContex
           printf("\t\n\tCreating Scaling context..[sws_getContext]\n");

           sws_ctx =   sws_getContext( in_width,       in_height,      src_pix_fmt,
                                       out_width,      out_height,     dst_pix_fmt,
                                       SWS_BICUBIC, NULL, NULL, NULL);
           if(!sws_ctx) { printf("\nContext Error..\n"); }
           printf("\t\n\tScaling context...Created\n");  


    //------Create scaling context---OR CONVERTED TO DESTINATION FORMAT--      
           sws_scale(sws_ctx, RawPic->data, RawPic->linesize, 0, in_height, ScalePic->data, ScalePic->linesize);      
           printf("\t\n\tCreating Scaling context...sws_scale...done\n");

           int num_bytes   =   avpicture_get_size(src_pix_fmt,in_width,in_height);
           uint8_t*    ScalePic_Buffer =   (uint8_t *)av_malloc(num_bytes*sizeof(int8_t));    
           avpicture_fill((AVPicture*)ScalePic,ScalePic_Buffer,AV_PIX_FMT_YUVJ422P,out_width,out_height);


    //-----Write Scale Image to outputfile----------------------------
           fwrite(ScalePic->data,1,dst_bufsize,out_file);



    //---Release all memory and close file----------------------------------
       fclose(in_file);
       fclose(out_file);
       avcodec_close(pCodecCtx);
       av_free(pCodecCtx);
       av_freep(&RawPic->data[0]);
       av_frame_free(&RawPic);
       av_freep(&ScalePic->data[0]);
       av_frame_free(&ScalePic);
       av_frame_free(&RawPic);

       printf("\n\n");
       system("PAUSE");
       exit(1);

    }
  • swscale/aarch64/output.S : refactor ff_yuv2plane1_8_neon

    31 janvier, par Krzysztof Pyrkosz
    swscale/aarch64/output.S : refactor ff_yuv2plane1_8_neon
    

    The benchmarks (before vs after) were gathered using
    ./tests/checkasm/checkasm —test=sw_scale —bench —runs=6 | grep yuv2yuv1

    A78 before :
    yuv2yuv1_0_512_accurate_c : 2039.5 ( 1.00x)
    yuv2yuv1_0_512_accurate_neon : 385.5 ( 5.29x)
    yuv2yuv1_0_512_approximate_c : 2110.5 ( 1.00x)
    yuv2yuv1_0_512_approximate_neon : 385.5 ( 5.47x)
    yuv2yuv1_3_512_accurate_c : 2061.2 ( 1.00x)
    yuv2yuv1_3_512_accurate_neon : 381.2 ( 5.41x)
    yuv2yuv1_3_512_approximate_c : 2099.2 ( 1.00x)
    yuv2yuv1_3_512_approximate_neon : 381.2 ( 5.51x)
    yuv2yuv1_8_512_accurate_c : 2054.2 ( 1.00x)
    yuv2yuv1_8_512_accurate_neon : 385.5 ( 5.33x)
    yuv2yuv1_8_512_approximate_c : 2112.2 ( 1.00x)
    yuv2yuv1_8_512_approximate_neon : 385.5 ( 5.48x)
    yuv2yuv1_11_512_accurate_c : 2036.0 ( 1.00x)
    yuv2yuv1_11_512_accurate_neon : 381.2 ( 5.34x)
    yuv2yuv1_11_512_approximate_c : 2115.0 ( 1.00x)
    yuv2yuv1_11_512_approximate_neon : 381.2 ( 5.55x)
    yuv2yuv1_16_512_accurate_c : 2066.5 ( 1.00x)
    yuv2yuv1_16_512_accurate_neon : 385.5 ( 5.36x)
    yuv2yuv1_16_512_approximate_c : 2100.8 ( 1.00x)
    yuv2yuv1_16_512_approximate_neon : 385.5 ( 5.45x)
    yuv2yuv1_19_512_accurate_c : 2059.8 ( 1.00x)
    yuv2yuv1_19_512_accurate_neon : 381.2 ( 5.40x)
    yuv2yuv1_19_512_approximate_c : 2102.8 ( 1.00x)
    yuv2yuv1_19_512_approximate_neon : 381.2 ( 5.52x)

    After :
    yuv2yuv1_0_512_accurate_c : 2206.0 ( 1.00x)
    yuv2yuv1_0_512_accurate_neon : 139.2 (15.84x)
    yuv2yuv1_0_512_approximate_c : 2050.0 ( 1.00x)
    yuv2yuv1_0_512_approximate_neon : 139.2 (14.72x)
    yuv2yuv1_3_512_accurate_c : 2205.2 ( 1.00x)
    yuv2yuv1_3_512_accurate_neon : 138.0 (15.98x)
    yuv2yuv1_3_512_approximate_c : 2052.5 ( 1.00x)
    yuv2yuv1_3_512_approximate_neon : 138.0 (14.87x)
    yuv2yuv1_8_512_accurate_c : 2171.0 ( 1.00x)
    yuv2yuv1_8_512_accurate_neon : 139.2 (15.59x)
    yuv2yuv1_8_512_approximate_c : 2064.2 ( 1.00x)
    yuv2yuv1_8_512_approximate_neon : 139.2 (14.82x)
    yuv2yuv1_11_512_accurate_c : 2164.8 ( 1.00x)
    yuv2yuv1_11_512_accurate_neon : 138.0 (15.69x)
    yuv2yuv1_11_512_approximate_c : 2048.8 ( 1.00x)
    yuv2yuv1_11_512_approximate_neon : 138.0 (14.85x)
    yuv2yuv1_16_512_accurate_c : 2154.5 ( 1.00x)
    yuv2yuv1_16_512_accurate_neon : 139.2 (15.47x)
    yuv2yuv1_16_512_approximate_c : 2047.2 ( 1.00x)
    yuv2yuv1_16_512_approximate_neon : 139.2 (14.70x)
    yuv2yuv1_19_512_accurate_c : 2144.5 ( 1.00x)
    yuv2yuv1_19_512_accurate_neon : 138.0 (15.54x)
    yuv2yuv1_19_512_approximate_c : 2046.0 ( 1.00x)
    yuv2yuv1_19_512_approximate_neon : 138.0 (14.83x)

    A72 before :
    yuv2yuv1_0_512_accurate_c : 3779.8 ( 1.00x)
    yuv2yuv1_0_512_accurate_neon : 527.8 ( 7.16x)
    yuv2yuv1_0_512_approximate_c : 4128.2 ( 1.00x)
    yuv2yuv1_0_512_approximate_neon : 528.2 ( 7.81x)
    yuv2yuv1_3_512_accurate_c : 3836.2 ( 1.00x)
    yuv2yuv1_3_512_accurate_neon : 527.0 ( 7.28x)
    yuv2yuv1_3_512_approximate_c : 3991.0 ( 1.00x)
    yuv2yuv1_3_512_approximate_neon : 526.8 ( 7.58x)
    yuv2yuv1_8_512_accurate_c : 3732.8 ( 1.00x)
    yuv2yuv1_8_512_accurate_neon : 525.5 ( 7.10x)
    yuv2yuv1_8_512_approximate_c : 4060.0 ( 1.00x)
    yuv2yuv1_8_512_approximate_neon : 527.0 ( 7.70x)
    yuv2yuv1_11_512_accurate_c : 3836.2 ( 1.00x)
    yuv2yuv1_11_512_accurate_neon : 530.0 ( 7.24x)
    yuv2yuv1_11_512_approximate_c : 4014.0 ( 1.00x)
    yuv2yuv1_11_512_approximate_neon : 530.0 ( 7.57x)
    yuv2yuv1_16_512_accurate_c : 3726.2 ( 1.00x)
    yuv2yuv1_16_512_accurate_neon : 525.5 ( 7.09x)
    yuv2yuv1_16_512_approximate_c : 4114.2 ( 1.00x)
    yuv2yuv1_16_512_approximate_neon : 526.2 ( 7.82x)
    yuv2yuv1_19_512_accurate_c : 3812.2 ( 1.00x)
    yuv2yuv1_19_512_accurate_neon : 530.0 ( 7.19x)
    yuv2yuv1_19_512_approximate_c : 4012.2 ( 1.00x)
    yuv2yuv1_19_512_approximate_neon : 530.0 ( 7.57x)

    After :
    yuv2yuv1_0_512_accurate_c : 3716.8 ( 1.00x)
    yuv2yuv1_0_512_accurate_neon : 215.1 (17.28x)
    yuv2yuv1_0_512_approximate_c : 3877.8 ( 1.00x)
    yuv2yuv1_0_512_approximate_neon : 222.8 (17.40x)
    yuv2yuv1_3_512_accurate_c : 3717.1 ( 1.00x)
    yuv2yuv1_3_512_accurate_neon : 217.8 (17.06x)
    yuv2yuv1_3_512_approximate_c : 3801.6 ( 1.00x)
    yuv2yuv1_3_512_approximate_neon : 220.3 (17.25x)
    yuv2yuv1_8_512_accurate_c : 3716.6 ( 1.00x)
    yuv2yuv1_8_512_accurate_neon : 213.8 (17.38x)
    yuv2yuv1_8_512_approximate_c : 3831.8 ( 1.00x)
    yuv2yuv1_8_512_approximate_neon : 218.1 (17.57x)
    yuv2yuv1_11_512_accurate_c : 3717.1 ( 1.00x)
    yuv2yuv1_11_512_accurate_neon : 219.1 (16.97x)
    yuv2yuv1_11_512_approximate_c : 3801.6 ( 1.00x)
    yuv2yuv1_11_512_approximate_neon : 216.1 (17.59x)
    yuv2yuv1_16_512_accurate_c : 3716.6 ( 1.00x)
    yuv2yuv1_16_512_accurate_neon : 213.6 (17.40x)
    yuv2yuv1_16_512_approximate_c : 3831.6 ( 1.00x)
    yuv2yuv1_16_512_approximate_neon : 215.1 (17.82x)
    yuv2yuv1_19_512_accurate_c : 3717.1 ( 1.00x)
    yuv2yuv1_19_512_accurate_neon : 223.8 (16.61x)
    yuv2yuv1_19_512_approximate_c : 3801.6 ( 1.00x)
    yuv2yuv1_19_512_approximate_neon : 219.1 (17.35x)

    x13s before :
    yuv2yuv1_0_512_accurate_c : 1435.1 ( 1.00x)
    yuv2yuv1_0_512_accurate_neon : 221.1 ( 6.49x)
    yuv2yuv1_0_512_approximate_c : 1405.4 ( 1.00x)
    yuv2yuv1_0_512_approximate_neon : 219.1 ( 6.41x)
    yuv2yuv1_3_512_accurate_c : 1418.6 ( 1.00x)
    yuv2yuv1_3_512_accurate_neon : 215.9 ( 6.57x)
    yuv2yuv1_3_512_approximate_c : 1405.9 ( 1.00x)
    yuv2yuv1_3_512_approximate_neon : 224.1 ( 6.27x)
    yuv2yuv1_8_512_accurate_c : 1433.9 ( 1.00x)
    yuv2yuv1_8_512_accurate_neon : 218.6 ( 6.56x)
    yuv2yuv1_8_512_approximate_c : 1412.9 ( 1.00x)
    yuv2yuv1_8_512_approximate_neon : 218.9 ( 6.46x)
    yuv2yuv1_11_512_accurate_c : 1449.1 ( 1.00x)
    yuv2yuv1_11_512_accurate_neon : 217.6 ( 6.66x)
    yuv2yuv1_11_512_approximate_c : 1410.9 ( 1.00x)
    yuv2yuv1_11_512_approximate_neon : 221.1 ( 6.38x)
    yuv2yuv1_16_512_accurate_c : 1402.1 ( 1.00x)
    yuv2yuv1_16_512_accurate_neon : 214.6 ( 6.53x)
    yuv2yuv1_16_512_approximate_c : 1422.4 ( 1.00x)
    yuv2yuv1_16_512_approximate_neon : 222.9 ( 6.38x)
    yuv2yuv1_19_512_accurate_c : 1421.6 ( 1.00x)
    yuv2yuv1_19_512_accurate_neon : 217.4 ( 6.54x)
    yuv2yuv1_19_512_approximate_c : 1421.6 ( 1.00x)
    yuv2yuv1_19_512_approximate_neon : 221.4 ( 6.42x)

    After :
    yuv2yuv1_0_512_accurate_c : 1413.6 ( 1.00x)
    yuv2yuv1_0_512_accurate_neon : 80.6 (17.53x)
    yuv2yuv1_0_512_approximate_c : 1455.6 ( 1.00x)
    yuv2yuv1_0_512_approximate_neon : 80.6 (18.05x)
    yuv2yuv1_3_512_accurate_c : 1429.1 ( 1.00x)
    yuv2yuv1_3_512_accurate_neon : 77.4 (18.47x)
    yuv2yuv1_3_512_approximate_c : 1462.6 ( 1.00x)
    yuv2yuv1_3_512_approximate_neon : 80.6 (18.14x)
    yuv2yuv1_8_512_accurate_c : 1425.4 ( 1.00x)
    yuv2yuv1_8_512_accurate_neon : 77.9 (18.30x)
    yuv2yuv1_8_512_approximate_c : 1436.6 ( 1.00x)
    yuv2yuv1_8_512_approximate_neon : 80.9 (17.76x)
    yuv2yuv1_11_512_accurate_c : 1429.4 ( 1.00x)
    yuv2yuv1_11_512_accurate_neon : 76.1 (18.78x)
    yuv2yuv1_11_512_approximate_c : 1447.1 ( 1.00x)
    yuv2yuv1_11_512_approximate_neon : 78.4 (18.46x)
    yuv2yuv1_16_512_accurate_c : 1439.9 ( 1.00x)
    yuv2yuv1_16_512_accurate_neon : 77.6 (18.55x)
    yuv2yuv1_16_512_approximate_c : 1422.1 ( 1.00x)
    yuv2yuv1_16_512_approximate_neon : 78.1 (18.20x)
    yuv2yuv1_19_512_accurate_c : 1447.1 ( 1.00x)
    yuv2yuv1_19_512_accurate_neon : 78.1 (18.52x)
    yuv2yuv1_19_512_approximate_c : 1474.4 ( 1.00x)
    yuv2yuv1_19_512_approximate_neon : 78.1 (18.87x)

    Signed-off-by : Martin Storsjö <martin@martin.st>

    • [DH] libswscale/aarch64/output.S
  • Anomalie #3418 : Les tables des plugins ne s’installent pas

    9 mai 2015, par Maïeul Rouquette

    Ma config local

    PHP Version 5.2.17

    System Darwin FTSR22998 12.6.0 Darwin Kernel Version 12.6.0 : Wed Mar 18 16:23:48 PDT 2015 ; root:xnu-2050.48.19 1/RELEASE_X86_64 x86_64
    Build Date Sep 18 2013 13:58:06
    Configure Command ’./configure’ ’—with-mysql=/Applications/MAMP/Library’ ’—with-apxs2=/Applications/MAMP/Library/bin/apxs’ ’—with-gd’ ’—with-jpeg-dir=/Applications/MAMP/Library’ ’—with-png-dir=/Applications/MAMP/Library’ ’—with-zlib’ ’—with-freetype-dir=/Applications/MAMP/Library’ ’—prefix=/Applications/MAMP/bin/php/php5.2.17’ ’—exec-prefix=/Applications/MAMP/bin/php/php5.2.17’ ’—sysconfdir=/Applications/MAMP/bin/php/php5.2.17/conf’ ’—with-soap’ ’—with-config-file-path=/Applications/MAMP/bin/php/php5.2.17/conf’ ’—enable-track-vars’ ’—enable-bcmath’ ’—enable-ftp’ ’—enable-gd-native-ttf’ ’—with-bz2=/usr’ ’—with-ldap’ ’—with-mysqli=/Applications/MAMP/Library/bin/mysql_config’ ’—with-sqlite’ ’—with-ttf’ ’—with-t1lib=/Applications/MAMP/Library’ ’—enable-mbstring=all’ ’—with-curl=/Applications/MAMP/Library’ ’—enable-dbx’ ’—enable-sockets’ ’—enable-bcmath’ ’—with-imap=shared,/Applications/MAMP/Library/lib/imap-2007f’ ’—enable-soap’ ’—with-kerberos’ ’—enable-calendar’ ’—with-pgsql=shared,/Applications/MAMP/Library/pg’ ’—enable-dbase’ ’—enable-exif’ ’—with-libxml-dir=/Applications/MAMP/Library’ ’—with-gettext=shared,/Applications/MAMP/Library’ ’—with-xsl=/Applications/MAMP/Library’ ’—with-pdo-mysql=shared,/Applications/MAMP/Library’ ’—with-pdo-pgsql=shared,/Applications/MAMP/Library/pg’ ’—with-mcrypt=shared,/Applications/MAMP/Library’ ’—with-openssl’ ’—enable-zip’ ’—with-iconv=/Applications/MAMP/Library’
    Server API Apache 2.0 Handler
    Virtual Directory Support disabled
    Configuration File (php.ini) Path /Applications/MAMP/bin/php/php5.2.17/conf
    Loaded Configuration File /Applications/MAMP/bin/php/php5.2.17/conf/php.ini
    Scan this dir for additional .ini files (none)
    additional .ini files parsed (none)
    PHP API 20041225
    PHP Extension 20060613
    Zend Extension 220060519
    Debug Build no
    Thread Safety disabled
    Zend Memory Manager enabled
    IPv6 Support enabled
    Registered PHP Streams https, ftps, compress.zlib, compress.bzip2, php, file, data, http, ftp, zip
    Registered Stream Socket Transports tcp, udp, unix, udg, ssl, sslv3, sslv2, tls
    Registered Stream Filters zlib.*, bzip2.*, convert.iconv.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed

    Mon test
    1) spip 3.1 svn 22109
    2) pas de plugins/auto mais le flux déclaré
    3) plugin tickets mis manuellement dans plugins
    4) j’active le plugin. Il se "préactive" en entendance les dépendances
    5) lorsque j’installe saisies, le plugin tickets peut bien s’activer
    6) mais les tables n’ont pas été installées