VkSamplerBorderColorComponentMappingCreateInfoEXT(3)

# VkSamplerBorderColorComponentMappingCreateInfoEXT(3) Manual Page

## Name

VkSamplerBorderColorComponentMappingCreateInfoEXT - Structure specifying the component mapping of the border color

Loading… please wait.

## C Specification

If the sampler is created with `VK_BORDER_COLOR_FLOAT_OPAQUE_BLACK`, `VK_BORDER_COLOR_INT_OPAQUE_BLACK`, `VK_BORDER_COLOR_FLOAT_CUSTOM_EXT`, or `VK_BORDER_COLOR_INT_CUSTOM_EXT` `borderColor`, and that sampler will be combined with an image view that does not have an identity swizzle, and VkPhysicalDeviceBorderColorSwizzleFeaturesEXT::`borderColorSwizzleFromImage` is not enabled, then it is necessary to specify the component mapping of the border color, by including the `VkSamplerBorderColorComponentMappingCreateInfoEXT` structure in the VkSamplerCreateInfo::`pNext` chain, to get defined results.

The `VkSamplerBorderColorComponentMappingCreateInfoEXT` structure is defined as:

    // Provided by VK_EXT_border_color_swizzle
    typedef struct VkSamplerBorderColorComponentMappingCreateInfoEXT {
        VkStructureType       sType;
        const void*           pNext;
        VkComponentMapping    components;
        VkBool32              srgb;
    } VkSamplerBorderColorComponentMappingCreateInfoEXT;

## Members

- `sType` is a VkStructureType value identifying this structure.

- `pNext` is `NULL` or a pointer to a structure extending this structure.

- `components` is a VkComponentMapping structure specifying a remapping of the border color components.

- `srgb` indicates that the sampler will be combined with an image view that has an image format which is sRGB encoded.

## Description

The VkComponentMapping `components` member describes a remapping from components of the border color to components of the vector returned by shader image instructions when the border color is used.

Valid Usage

- VUID-VkSamplerBorderColorComponentMappingCreateInfoEXT-borderColorSwizzle-06437
  The `borderColorSwizzle` feature must be enabled

Valid Usage (Implicit)

- VUID-VkSamplerBorderColorComponentMappingCreateInfoEXT-sType-sType
  `sType` must be `VK_STRUCTURE_TYPE_SAMPLER_BORDER_COLOR_COMPONENT_MAPPING_CREATE_INFO_EXT`

- VUID-VkSamplerBorderColorComponentMappingCreateInfoEXT-components-parameter
  `components` must be a valid VkComponentMapping structure

## See Also

VK_EXT_border_color_swizzle, VkBool32, VkComponentMapping, VkStructureType

## Document Notes

For more information, see the Vulkan Specification

This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.

## Copyright

Copyright 2014-2023 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0