Recherche avancée

Médias (1)

Mot : - Tags -/lev manovitch

Autres articles (89)

  • Récupération d’informations sur le site maître à l’installation d’une instance

    26 novembre 2010, par

    Utilité
    Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
    Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...)

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • Possibilité de déploiement en ferme

    12 avril 2011, par

    MediaSPIP peut être installé comme une ferme, avec un seul "noyau" hébergé sur un serveur dédié et utilisé par une multitude de sites différents.
    Cela permet, par exemple : de pouvoir partager les frais de mise en œuvre entre plusieurs projets / individus ; de pouvoir déployer rapidement une multitude de sites uniques ; d’éviter d’avoir à mettre l’ensemble des créations dans un fourre-tout numérique comme c’est le cas pour les grandes plate-formes tout public disséminées sur le (...)

Sur d’autres sites (6207)

  • Optimizing Painting video encoding in Android

    26 octobre 2013, par coder000001

    I want to create live painting video as export feature for a painting application.

    I can create a video with a series of images, with the use of a library ( FFMPEG or MediaCodec). But, this would require too much processing power to compare the images and encode the video.

    While drawing, I know exactly which pixels are changed. So, I can save lot of processing if I can pass this info to FFMPEG, instead of having the FFMPEG figure this out from the images.

    Is there away to efficiently encode the video for this purpose ?

  • Latch-Based Performance Optimization for Field-Programmable Gate Arrays [on hold]

    22 mars 2014, par user3448912

    how can i replace the flip-flops in fpga by pulsed latches ?i tried that with howard algorithm by writing the verilog code for that.i have to take the area and power analysis.which synopsis tool is useful ?i am getting the timing report from xilinx.

  • a lot of GREEN Color at YUV420p —> RGB in OpenGL 2.0 Shader on iOS

    25 octobre 2012, par 이형근

    I want to make a movie player for iOS using ffmpeg and OpenGL ES 2.0
    but I have some problem. Output RGB image has a lot of GREEN color.
    This is code and images

    • 480x320 width & height :
    • 512x512 Texture width & height

    I got a YUV420p row data from ffmpeg AVFrame.

       for (int i = 0, nDataLen = 0; i < 3; i++) {
           int nShift = (i == 0) ? 0 : 1;
           uint8_t *pYUVData = (uint8_t *)_frame->data[i];
           for (int j = 0; j < (mHeight >> nShift); j++) {
               memcpy(&pData->pOutBuffer[nDataLen], pYUVData, (mWidth >> nShift));
               pYUVData += _frame->linesize[i];
               nDataLen += (mWidth >> nShift);
           }
       }

    and prepare texture for Y, U & V channel.

    //: U Texture
       if (sampler1Texture) glDeleteTextures(1, &sampler1Texture);

       glActiveTexture(GL_TEXTURE1);
       glGenTextures(1, &sampler1Texture);
       glBindTexture(GL_TEXTURE_2D, sampler1Texture);

       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
       // This is necessary for non-power-of-two textures
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
       glEnable(GL_TEXTURE_2D);

       glTexImage2D(GL_TEXTURE_2D,
                    0,
                    GL_LUMINANCE,
                    texW / 2,
                    texH / 2,
                    0,
                    GL_LUMINANCE,
                    GL_UNSIGNED_BYTE,
                    NULL);

       //: V Texture
       if (sampler2Texture) glDeleteTextures(1, &sampler2Texture);

       glActiveTexture(GL_TEXTURE2);
       glGenTextures(1, &sampler2Texture);
       glBindTexture(GL_TEXTURE_2D, sampler2Texture);

       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
       // This is necessary for non-power-of-two textures
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
       glEnable(GL_TEXTURE_2D);

       glTexImage2D(GL_TEXTURE_2D,
                    0,
                    GL_LUMINANCE,
                    texW / 2,
                    texH / 2,
                    0,
                    GL_LUMINANCE,
                    GL_UNSIGNED_BYTE,
                    NULL);

       //: Y Texture
       if (sampler0Texture) glDeleteTextures(1, &sampler0Texture);

       glActiveTexture(GL_TEXTURE0);
       glGenTextures(1, &sampler0Texture);
       glBindTexture(GL_TEXTURE_2D, sampler0Texture);

       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
       // This is necessary for non-power-of-two textures
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
       glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
       glEnable(GL_TEXTURE_2D);

       glTexImage2D(GL_TEXTURE_2D,
                    0,
                    GL_LUMINANCE,
                    texW,
                    texH,
                    0,
                    GL_LUMINANCE,
                    GL_UNSIGNED_BYTE,
                    NULL);

    Rendering part is below.

    int _idxU = mFrameW * mFrameH;
    int _idxV = _idxU + (_idxU / 4);

    // U data
    glActiveTexture(GL_TEXTURE1);
    glBindTexture(GL_TEXTURE_2D, sampler1Texture);
    glUniform1i(sampler1Uniform, 1);

    glTexSubImage2D(
                   GL_TEXTURE_2D,
                   0,
                   0,
                   0,
                   mFrameW / 2,            // source width
                   mFrameH / 2,            // source height
                   GL_LUMINANCE,
                   GL_UNSIGNED_BYTE,
                   &_frameData[_idxU]);

    // V data
    glActiveTexture(GL_TEXTURE2);
    glBindTexture(GL_TEXTURE_2D, sampler2Texture);
    glUniform1i(sampler2Texture, 2);

    glTexSubImage2D(
                   GL_TEXTURE_2D,
                   0,
                   0,
                   0,
                   mFrameW / 2,            // source width
                   mFrameH / 2,            // source height
                   GL_LUMINANCE,
                   GL_UNSIGNED_BYTE,
                   &_frameData[_idxV]);

    // Y data
    glActiveTexture(GL_TEXTURE0);
    glBindTexture(GL_TEXTURE_2D, sampler0Texture);
    glUniform1i(sampler0Uniform, 0);

    glTexSubImage2D(
                   GL_TEXTURE_2D,
                   0,
                   0,
                   0,
                   mFrameW,            // source width
                   mFrameH,            // source height
                   GL_LUMINANCE,
                   GL_UNSIGNED_BYTE,
                   _frameData);

    Vertex Shader & Fragment Shader is below.

    attribute vec4 Position;
    attribute vec2 TexCoordIn;

    varying vec2 TexCoordOut;
    varying vec2 TexCoordOut_UV;

    uniform mat4 Projection;
    uniform mat4 Modelview;

    void main()
    {
       gl_Position = Projection * Modelview * Position;
       TexCoordOut = TexCoordIn;
    }



    uniform sampler2D sampler0; // Y Texture Sampler
    uniform sampler2D sampler1; // U Texture Sampler
    uniform sampler2D sampler2; // V Texture Sampler

    varying highp vec2 TexCoordOut;

    void main()
    {
       highp float y = texture2D(sampler0, TexCoordOut).r;
       highp float u = texture2D(sampler2, TexCoordOut).r - 0.5;
       highp float v = texture2D(sampler1, TexCoordOut).r - 0.5;

       //y = 0.0;
       //u = 0.0;
       //v = 0.0;

       highp float r = y + 1.13983 * v;
       highp float g = y - 0.39465 * u - 0.58060 * v;
       highp float b = y + 2.03211 * u;

       gl_FragColor = vec4(r, g, b, 1.0);
    }

    Y Texture (Grayscale) is correct but U & V has a lot of Green Color.
    So final RGB image (Y+U+V) has a lot of GREEN Color.
    What's the problem ?

    Please help.
    thanks.