⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 199045 in webkit


Ignore:
Timestamp:
Apr 4, 2016, 11:11:22 PM (11 years ago)
Author:
zandobersek@gmail.com
Message:

[TexMap] Improve viewport array access in TextureMapperGL::bindDefaultSurface()
​https://bugs.webkit.org/show_bug.cgi?id=156159

Reviewed by Antonio Gomes.

  • platform/graphics/texmap/TextureMapperGL.cpp:

(WebCore::TextureMapperGL::bindDefaultSurface): Create a reference to the
viewport array in the TextureMapperGLData object. Inline the IntSize constructor
for the object that's passed to createProjectionMatrix(), and use the reference
to access all four elements of the array as necessary.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r199044 r199045  
     12016-04-04  Zan Dobersek  <zdobersek@igalia.com>
     2
     3        [TexMap] Improve viewport array access in TextureMapperGL::bindDefaultSurface()
     4        https://bugs.webkit.org/show_bug.cgi?id=156159
     5
     6        Reviewed by Antonio Gomes.
     7
     8        * platform/graphics/texmap/TextureMapperGL.cpp:
     9        (WebCore::TextureMapperGL::bindDefaultSurface): Create a reference to the
     10        viewport array in the TextureMapperGLData object. Inline the IntSize constructor
     11        for the object that's passed to createProjectionMatrix(), and use the reference
     12        to access all four elements of the array as necessary.
     13
    1142016-04-04  Zan Dobersek  <zdobersek@igalia.com>
    215
  • trunk/Source/WebCore/platform/graphics/texmap/TextureMapperGL.cpp

    r197387 r199045  
    619619{
    620620    m_context3D->bindFramebuffer(GraphicsContext3D::FRAMEBUFFER, data().targetFrameBuffer);
    621     IntSize viewportSize(data().viewport[2], data().viewport[3]);
    622     data().projectionMatrix = createProjectionMatrix(viewportSize, data().PaintFlags & PaintingMirrored);
    623     m_context3D->viewport(data().viewport[0], data().viewport[1], viewportSize.width(), viewportSize.height());
     621    auto& viewport = data().viewport;
     622    data().projectionMatrix = createProjectionMatrix(IntSize(viewport[2], viewport[3]), data().PaintFlags & PaintingMirrored);
     623    m_context3D->viewport(viewport[0], viewport[1], viewport[2], viewport[3]);
    624624    m_clipStack.apply(*m_context3D);
    625625    data().currentSurface = nullptr;
Note: See TracChangeset for help on using the changeset viewer.