Skip to content

  • Projects
  • Groups
  • Snippets
  • Help
  • This project
    • Loading...
  • Sign in / Register
S
swiftshader
  • 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
  • swiftshader
  • Repository

Switch branch/tag
  • swiftshader
  • src
  • Vulkan
  • VkPhysicalDevice.cpp
Find file
BlameHistoryPermalink
  • Nicolas Capens's avatar
    Document single-level YCbCr image assumption · 77b43d68
    Nicolas Capens authored Mar 12, 2020
    We currently rely on limiting the mipmap level count of YCbCr images
    and the presence of sampler YCbCr conversion to disable mipmapping.
    
    This is valid, but fragile. The Vulkan 1.2 spec guarantees that when
    sampler Y'CbCr conversion is used, the image view must have a Y'CbCr
    format:
    
    "If the descriptor refers to a sampler that performs Y'CbCr conversion,
     the sampler must only be used to sample the image in the same
     descriptor."
    
    "If the image view is to be used with a sampler which supports sampler
     Y'CbCr conversion, an identically defined object of type
     VkSamplerYcbcrConversion to that used to create the sampler must be
     passed to vkCreateImageView in a VkSamplerYcbcrConversionInfo included
     in the pNext chain of VkImageViewCreateInfo. Conversely, if a
     VkSamplerYcbcrConversion object is passed to vkCreateImageView, an
     identically defined VkSamplerYcbcrConversion object must be used when
     sampling the image."
    
    "maxMipLevels is the maximum number of mipmap levels. maxMipLevels must
     be equal to the number of levels in the complete mipmap chain based on
     the maxExtent.width, maxExtent.height, and maxExtent.depth, except when
     one of the following conditions is true, in which case it may instead
     be 1:
      * ...
      * image format is one of those listed in Formats requiring sampler
        Y′CBCR conversion for VK_IMAGE_ASPECT_COLOR_BIT image views"
    
    Bug: b/151263485
    Change-Id: Ibb8e3fe34ecda04d6fb41308437fa4c66815f1fb
    Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/42228
    Presubmit-Ready: Nicolas Capens <nicolascapens@google.com>
    Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
    Tested-by: 's avatarNicolas Capens <nicolascapens@google.com>
    Reviewed-by: 's avatarAlexis Hétu <sugoi@google.com>
    77b43d68
VkPhysicalDevice.cpp 38.9 KB
EditWeb IDE
×

Replace VkPhysicalDevice.cpp

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.