~linaro-graphics-wg/compiz-plugins-main/linaro-gles2-old

« back to all changes in this revision

Viewing changes to grid/src/grid.cpp

  • Committer: Alexandros Frantzis
  • Date: 2012-01-25 10:39:45 UTC
  • Revision ID: alexandros.frantzis@linaro.org-20120125103945-kq0y1d5kwoijfdsp
grid: Ensure blending is enabled when drawing rectangles.

Show diffs side-by-side

added added

removed removed

Lines of Context:
410
410
    GLfloat         vertexData[12];
411
411
    GLushort        colorData[4];
412
412
    GLushort       *color;
 
413
    GLboolean       isBlendingEnabled;
413
414
 
414
415
    getPaintRectangle (rect);
415
416
 
418
419
 
419
420
    sTransform.toScreenSpace (output, -DEFAULT_Z_CAMERA);
420
421
 
 
422
    glGetBooleanv (GL_BLEND, &isBlendingEnabled);
 
423
    glEnable (GL_BLEND);
421
424
 
422
425
        for (iter = animations.begin (); iter != animations.end () && animating; iter++)
423
426
        {
544
547
                streamingBuffer->end ();
545
548
                streamingBuffer->render (sTransform);
546
549
        }
 
550
 
 
551
        if (!isBlendingEnabled)
 
552
            glDisable (GL_BLEND);
547
553
}
548
554
 
549
555
bool