VkLineRasterizationModeKHR(3)

# VkLineRasterizationModeKHR(3) Manual Page

## Name

VkLineRasterizationModeKHR - Line rasterization modes

Loading… please wait.

## C Specification

Possible values of VkPipelineRasterizationLineStateCreateInfoKHR::`lineRasterizationMode` are:

    // Provided by VK_KHR_line_rasterization
    typedef enum VkLineRasterizationModeKHR {
        VK_LINE_RASTERIZATION_MODE_DEFAULT_KHR = 0,
        VK_LINE_RASTERIZATION_MODE_RECTANGULAR_KHR = 1,
        VK_LINE_RASTERIZATION_MODE_BRESENHAM_KHR = 2,
        VK_LINE_RASTERIZATION_MODE_RECTANGULAR_SMOOTH_KHR = 3,
        VK_LINE_RASTERIZATION_MODE_DEFAULT_EXT = VK_LINE_RASTERIZATION_MODE_DEFAULT_KHR,
        VK_LINE_RASTERIZATION_MODE_RECTANGULAR_EXT = VK_LINE_RASTERIZATION_MODE_RECTANGULAR_KHR,
        VK_LINE_RASTERIZATION_MODE_BRESENHAM_EXT = VK_LINE_RASTERIZATION_MODE_BRESENHAM_KHR,
        VK_LINE_RASTERIZATION_MODE_RECTANGULAR_SMOOTH_EXT = VK_LINE_RASTERIZATION_MODE_RECTANGULAR_SMOOTH_KHR,
    } VkLineRasterizationModeKHR;

or the equivalent

    // Provided by VK_EXT_line_rasterization
    typedef VkLineRasterizationModeKHR VkLineRasterizationModeEXT;

## Description

- `VK_LINE_RASTERIZATION_MODE_DEFAULT_KHR` is equivalent to `VK_LINE_RASTERIZATION_MODE_RECTANGULAR_KHR` if VkPhysicalDeviceLimits::`strictLines` is `VK_TRUE`, otherwise lines are drawn as non-`strictLines` parallelograms. Both of these modes are defined in Basic Line Segment Rasterization.

- `VK_LINE_RASTERIZATION_MODE_RECTANGULAR_KHR` specifies lines drawn as if they were rectangles extruded from the line

- `VK_LINE_RASTERIZATION_MODE_BRESENHAM_KHR` specifies lines drawn by determining which pixel diamonds the line intersects and exits, as defined in Bresenham Line Segment Rasterization.

- `VK_LINE_RASTERIZATION_MODE_RECTANGULAR_SMOOTH_KHR` specifies lines drawn if they were rectangles extruded from the line, with alpha falloff, as defined in Smooth Lines.

## See Also

VK_EXT_line_rasterization, VK_KHR_line_rasterization, VkPipelineRasterizationLineStateCreateInfoKHR, vkCmdSetLineRasterizationModeEXT

## 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-2024 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0