Changeset View
Changeset View
Standalone View
Standalone View
effects/blur/blur.cpp
Show First 20 Lines • Show All 641 Lines • ▼ Show 20 Line(s) | 638 | { | |||
---|---|---|---|---|---|
642 | const int yTranslate = effects->virtualScreenSize().height() - screen.height() - screen.y(); | 642 | const int yTranslate = effects->virtualScreenSize().height() - screen.height() - screen.y(); | ||
643 | 643 | | |||
644 | const QRegion expandedBlurRegion = expand(shape) & expand(screen); | 644 | const QRegion expandedBlurRegion = expand(shape) & expand(screen); | ||
645 | 645 | | |||
646 | const bool isGLES = GLPlatform::instance()->isGLES(); | 646 | const bool isGLES = GLPlatform::instance()->isGLES(); | ||
647 | 647 | | |||
648 | // Upload geometry for the down and upsample iterations | 648 | // Upload geometry for the down and upsample iterations | ||
649 | GLVertexBuffer *vbo = GLVertexBuffer::streamingBuffer(); | 649 | GLVertexBuffer *vbo = GLVertexBuffer::streamingBuffer(); | ||
650 | vbo->reset(); | ||||
650 | 651 | | |||
651 | uploadGeometry(vbo, expandedBlurRegion.translated(xTranslate, yTranslate), shape); | 652 | uploadGeometry(vbo, expandedBlurRegion.translated(xTranslate, yTranslate), shape); | ||
652 | vbo->bindArrays(); | 653 | vbo->bindArrays(); | ||
653 | 654 | | |||
654 | const QRect sourceRect = expandedBlurRegion.boundingRect() & screen; | 655 | const QRect sourceRect = expandedBlurRegion.boundingRect() & screen; | ||
655 | const QRect destRect = sourceRect.translated(xTranslate, yTranslate); | 656 | const QRect destRect = sourceRect.translated(xTranslate, yTranslate); | ||
656 | 657 | | |||
657 | GLRenderTarget::pushRenderTargets(m_renderTargetStack); | 658 | GLRenderTarget::pushRenderTargets(m_renderTargetStack); | ||
▲ Show 20 Lines • Show All 156 Lines • Show Last 20 Lines |