Skip to content

  • Projects
  • Groups
  • Snippets
  • Help
  • This project
    • Loading...
  • Sign in / Register
A
angle
  • Project
    • Overview
    • Details
    • Activity
    • Cycle Analytics
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Charts
  • Issues 0
    • Issues 0
    • List
    • Board
    • Labels
    • Milestones
  • Merge Requests 0
    • Merge Requests 0
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Charts
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Chen Yisong
  • angle
  • Repository

Switch branch/tag
  • angle
  • src
  • compiler
  • translator
  • TextureFunctionHLSL.h
Find file
BlameHistoryPermalink
  • Jiawei Shao's avatar
    ES31: Support translating textureGather into HLSL - Part I · a977acc8
    Jiawei Shao authored Sep 19, 2018
    This patch is the first one in the series of supporting GLSL texture
    function textureGather/textureGatherOffset on D3D11.
    
    According to ESSL 3.1 SPEC (Chapter 8.9.3, Page 130), the definition
    of textureGather on sampler2D is:
        gvec4 textureGather (gsampler2D sampler, vec2 P[, int comp])
    
    The parameter "comp" is optional, and if it is specified, the value
    of "comp" must be a constant integer expression with a value of 0, 1,
    2, or 3, identifying the x, y, z, or w postswizzled component of the
    four-component vector lookup result for each texel, respectively. If
    comp is not specified, it is treated as 0.
    
    According to the definition above, textureGather is equivalent to
    Texture2D.Gather[Red|Green|Blue|Alpha] in HLSL, where we can use a
    switch-case expression to choose the right HLSL texture function.
    
    The features listed here will be implemented in the following patches:
    1. Support textureGatherOffset
    2. Support textureGather[Offset] on isamplers and usamplers
    3. Support textureGather[Offset] on textures when swizzle is on
    4. Support textureGather[Offset] on shadow samplers
    
    BUG=angleproject:2826
    TEST=dEQP-GLES31.functional.texture.gather.basic.2d.rgba8.*
         dEQP-GLES31.functional.texture.gather.basic.cube.rgba8.*
         (without texture_swizzle)
         dEQP-GLES31.functional.texture.gather.basic.2d_array.rgba8.*
         (without texture_swizzle)
    
    Change-Id: Iff2ed4f8b65dad613cb0bafdfd19f8f0528e832c
    Reviewed-on: https://chromium-review.googlesource.com/1232980
    Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
    Reviewed-by: 's avatarCorentin Wallez <cwallez@chromium.org>
    a977acc8
TextureFunctionHLSL.h 2.36 KB
EditWeb IDE
×

Replace TextureFunctionHLSL.h

Attach a file by drag & drop or click to upload


Cancel
A new branch will be created in your fork and a new merge request will be started.