1. 31 Aug, 2017 3 commits
    • Prefix user-defined names in GLSL output · 855d964b
      Olli Etuaho authored
      Now user-defined names are prefixed by _u in GLSL output in case name
      hashing is not on. Internal names such as names of temporary variables
      created in AST transformations are written out as such.
      
      This makes handling of internal function names and internal variable
      names consistent. It also removes the possibility of name conflicts
      between user-defined names and internal names in case name hashing is
      not on. In the same vein, it makes it safe to use GLSL reserved words
      that are not reserved in ESSL as variable names in case name hashing
      is not on.
      
      This also makes the GLSL output more consistent with how names are
      handled in HLSL output. Name hashing code is shared between
      VariableInfo and OutputGLSLBase to ensure names are handled
      consistently in both. The name that's used in the shader source for a
      given interface variable is written out to ShaderVariable::mappedName.
      
      An exception needs to be made for identifiers close to the length
      limit, since adding any prefix would take them over the limit. But
      they can be just written out as such, since we don't have any builtins
      or ANGLE internal variables that have as long names and could create a
      conflict.
      
      BUG=angleproject:2139
      BUG=angleproject:2038
      TEST=angle_unittests, angle_end2end_tests, WebGL conformance tests
      
      Change-Id: Id6ed052c4fab2d091227dc9a3668083053b67a38
      Reviewed-on: https://chromium-review.googlesource.com/507647
      Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
      Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
    • D3D11: Handle multi-view Draw* calls · ced5c86c
      Martin Radev authored
      Because the ANGLE_multiview extension uses instancing to multiply
      geometry for each view, Draw* calls with an active multiview program
      have to be handled in the follwing way:
      1) Convert non-instanced Draw calls to their instanced versions.
      2) Multiply the number of instances in an instanced Draw call by the
      number of views.
      The patch also applies the viewport offsets to the viewport and scissor
      rectangle and propagates the computed viewports and scissors to the
      D3D11 runtime.
      
      BUG=angleproject:2062
      TEST=angle_end2end_tests
      
      Change-Id: I8b4295c95c2cc0c1046c67e1fb1a782a46703292
      Reviewed-on: https://chromium-review.googlesource.com/618331
      Commit-Queue: Martin Radev <mradev@nvidia.com>
      Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
    • Update multiview state on program executable change · 0abb7a2a
      Martin Radev authored
      Relinking the active program can change its number of views and the
      state has to be correspondingly adjusted.
      
      BUG=angleproject:2062
      TEST=angle_end2end_tests
      
      Change-Id: I20102a428d7566a8cec5d81eeaa55980665812f4
      Reviewed-on: https://chromium-review.googlesource.com/637994
      Commit-Queue: Martin Radev <mradev@nvidia.com>
      Reviewed-by: 's avatarOlli Etuaho <oetuaho@nvidia.com>
      Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
  2. 30 Aug, 2017 5 commits
  3. 29 Aug, 2017 7 commits
  4. 28 Aug, 2017 16 commits
  5. 27 Aug, 2017 1 commit
  6. 26 Aug, 2017 1 commit
  7. 25 Aug, 2017 3 commits
    • ES3.1: Implement framebuffer default parameters for d3d part. · 511937d9
      JiangYizhou authored
      Set framebuffer default params with glFramebufferParameteri and
      glGetFramebufferParameteriv, keep framebuffer default parameters
      in cache for query.
      The es 3.1 spec section 9.2 states that, "If there are no attachments
      , rendering will be limited to a rectangle having a lower left of
      (0, 0) and an upper right of (width, height), where width and height
      are the framebuffer object's default width and height."
      If the Framebuffer has no color attachment and the default width or
      height is smaller than the current viewport, use the smaller of the
      two sizes.
      
      BUG=angleproject:1594
      TEST=dEQP-GLES31.functional.state_query.framebuffer_default.framebuffer_default*
      TEST=dEQP-GLES31.functional.fbo.completeness.no_attachments
      TEST=dEQP-GLES31.functional.fbo.no_attachments.*
      TEST=angle_end2end_tests --gtest_filter=FramebufferTest_ES31.*
      
      Change-Id: I8041fd655161390acf115efa08ce0f04b10810a0
      Reviewed-on: https://chromium-review.googlesource.com/609414
      Commit-Queue: Jamie Madill <jmadill@chromium.org>
      Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
    • ES31: Implement GL_OES_geometry_shader built-ins in GLSL compiler · d27f5c8d
      Jiawei Shao authored
      This patch intends to implement all built-in constants, variables and
      functions defined in OpenGL ES 3.1 extension GL_OES_geometry_shader
      in ANGLE GLSL compiler.
      
      1. Add all built-in constants defined in GL_OES_geometry_shader.
      2. Add built-in functions EmitVertex() and EndPrimitive() required
         in Geometry Shader.
      3. Add built-in variables gl_PrimitiveIDIn and gl_InvocationID to
         Geometry Shader.
      4. Add built-in variables gl_PrimitiveID and gl_Layer to both
         Geometry Shader and Fragment Shader when GL_OES_geometry_shader
         is enabled.
      
      BUG=angleproject:1941
      TEST=angle_unittests
      
      Change-Id: I92821553ed0efee2ccb77fead6e065e7799819d0
      Reviewed-on: https://chromium-review.googlesource.com/627670
      Commit-Queue: Corentin Wallez <cwallez@chromium.org>
      Reviewed-by: 's avatarCorentin Wallez <cwallez@chromium.org>
      Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org>
    • Enable all multiview rendering tests for layered framebuffers · 3c25ad07
      Martin Radev authored
      The patch restructures the tests in MultiviewDrawTests.cpp, so that
      all rendering tests can be instantiated for side-by-side and layered
      framebuffers.
      
      BUG=angleproject:2062
      TEST=angle_end2end_tests
      
      Change-Id: I2c32fd3bd57b6afd1eb8d6cedb2d1b88b9fd6525
      Reviewed-on: https://chromium-review.googlesource.com/627918
      Commit-Queue: Martin Radev <mradev@nvidia.com>
      Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org>
  8. 24 Aug, 2017 4 commits