Class VulkanPipelineRasterizationStateCreateInfo.Builder
java.lang.Object
com.io7m.jcoronado.api.VulkanPipelineRasterizationStateCreateInfo.Builder
- Enclosing class:
VulkanPipelineRasterizationStateCreateInfo
Builds instances of type
VulkanPipelineRasterizationStateCreateInfo.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionaddAllCullMode(Iterable<VulkanCullModeFlag> elements) Adds elements tocullModeset.Adds elements toflagsset.addCullMode(VulkanCullModeFlag element) Adds one element tocullModeset.addCullMode(VulkanCullModeFlag... elements) Adds elements tocullModeset.Adds one element toflagsset.addFlags(VulkanPipelineRasterizationStateCreateFlag... elements) Adds elements toflagsset.build()Builds a newVulkanPipelineRasterizationStateCreateInfo.Fill a builder with attribute values from the providedVulkanPipelineRasterizationStateCreateInfoTypeinstance.setCullMode(Iterable<VulkanCullModeFlag> elements) Sets or replaces all elements forcullModeset.setDepthBiasClamp(float depthBiasClamp) Initializes the value for thedepthBiasClampattribute.setDepthBiasConstantFactor(float depthBiasConstantFactor) Initializes the value for thedepthBiasConstantFactorattribute.setDepthBiasEnable(boolean depthBiasEnable) Initializes the value for thedepthBiasEnableattribute.setDepthBiasSlopeFactor(float depthBiasSlopeFactor) Initializes the value for thedepthBiasSlopeFactorattribute.setDepthClampEnable(boolean depthClampEnable) Initializes the value for thedepthClampEnableattribute.Sets or replaces all elements forflagsset.setFrontFace(VulkanFrontFace frontFace) Initializes the value for thefrontFaceattribute.setLineWidth(float lineWidth) Initializes the value for thelineWidthattribute.setPolygonMode(VulkanPolygonMode polygonMode) Initializes the value for thepolygonModeattribute.setRasterizerDiscardEnable(boolean rasterizerDiscardEnable) Initializes the value for therasterizerDiscardEnableattribute.
-
Method Details
-
from
public final VulkanPipelineRasterizationStateCreateInfo.Builder from(VulkanPipelineRasterizationStateCreateInfoType instance) Fill a builder with attribute values from the providedVulkanPipelineRasterizationStateCreateInfoTypeinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
addFlags
public final VulkanPipelineRasterizationStateCreateInfo.Builder addFlags(VulkanPipelineRasterizationStateCreateFlag element) Adds one element toflagsset.- Parameters:
element- A flags element- Returns:
thisbuilder for use in a chained invocation
-
addFlags
public final VulkanPipelineRasterizationStateCreateInfo.Builder addFlags(VulkanPipelineRasterizationStateCreateFlag... elements) Adds elements toflagsset.- Parameters:
elements- An array of flags elements- Returns:
thisbuilder for use in a chained invocation
-
setFlags
public final VulkanPipelineRasterizationStateCreateInfo.Builder setFlags(Iterable<VulkanPipelineRasterizationStateCreateFlag> elements) Sets or replaces all elements forflagsset.- Parameters:
elements- An iterable of flags elements- Returns:
thisbuilder for use in a chained invocation
-
addAllFlags
public final VulkanPipelineRasterizationStateCreateInfo.Builder addAllFlags(Iterable<VulkanPipelineRasterizationStateCreateFlag> elements) Adds elements toflagsset.- Parameters:
elements- An iterable of flags elements- Returns:
thisbuilder for use in a chained invocation
-
setDepthClampEnable
public final VulkanPipelineRasterizationStateCreateInfo.Builder setDepthClampEnable(boolean depthClampEnable) Initializes the value for thedepthClampEnableattribute.- Parameters:
depthClampEnable- The value for depthClampEnable- Returns:
thisbuilder for use in a chained invocation
-
setRasterizerDiscardEnable
public final VulkanPipelineRasterizationStateCreateInfo.Builder setRasterizerDiscardEnable(boolean rasterizerDiscardEnable) Initializes the value for therasterizerDiscardEnableattribute.- Parameters:
rasterizerDiscardEnable- The value for rasterizerDiscardEnable- Returns:
thisbuilder for use in a chained invocation
-
setPolygonMode
public final VulkanPipelineRasterizationStateCreateInfo.Builder setPolygonMode(VulkanPolygonMode polygonMode) Initializes the value for thepolygonModeattribute.If not set, this attribute will have a default value as returned by the initializer of
polygonMode.- Parameters:
polygonMode- The value for polygonMode- Returns:
thisbuilder for use in a chained invocation
-
addCullMode
public final VulkanPipelineRasterizationStateCreateInfo.Builder addCullMode(VulkanCullModeFlag element) Adds one element tocullModeset.- Parameters:
element- A cullMode element- Returns:
thisbuilder for use in a chained invocation
-
addCullMode
public final VulkanPipelineRasterizationStateCreateInfo.Builder addCullMode(VulkanCullModeFlag... elements) Adds elements tocullModeset.- Parameters:
elements- An array of cullMode elements- Returns:
thisbuilder for use in a chained invocation
-
setCullMode
public final VulkanPipelineRasterizationStateCreateInfo.Builder setCullMode(Iterable<VulkanCullModeFlag> elements) Sets or replaces all elements forcullModeset.- Parameters:
elements- An iterable of cullMode elements- Returns:
thisbuilder for use in a chained invocation
-
addAllCullMode
public final VulkanPipelineRasterizationStateCreateInfo.Builder addAllCullMode(Iterable<VulkanCullModeFlag> elements) Adds elements tocullModeset.- Parameters:
elements- An iterable of cullMode elements- Returns:
thisbuilder for use in a chained invocation
-
setFrontFace
public final VulkanPipelineRasterizationStateCreateInfo.Builder setFrontFace(VulkanFrontFace frontFace) Initializes the value for thefrontFaceattribute.If not set, this attribute will have a default value as returned by the initializer of
frontFace.- Parameters:
frontFace- The value for frontFace- Returns:
thisbuilder for use in a chained invocation
-
setDepthBiasEnable
public final VulkanPipelineRasterizationStateCreateInfo.Builder setDepthBiasEnable(boolean depthBiasEnable) Initializes the value for thedepthBiasEnableattribute.- Parameters:
depthBiasEnable- The value for depthBiasEnable- Returns:
thisbuilder for use in a chained invocation
-
setDepthBiasConstantFactor
public final VulkanPipelineRasterizationStateCreateInfo.Builder setDepthBiasConstantFactor(float depthBiasConstantFactor) Initializes the value for thedepthBiasConstantFactorattribute.If not set, this attribute will have a default value as returned by the initializer of
depthBiasConstantFactor.- Parameters:
depthBiasConstantFactor- The value for depthBiasConstantFactor- Returns:
thisbuilder for use in a chained invocation
-
setDepthBiasClamp
public final VulkanPipelineRasterizationStateCreateInfo.Builder setDepthBiasClamp(float depthBiasClamp) Initializes the value for thedepthBiasClampattribute.If not set, this attribute will have a default value as returned by the initializer of
depthBiasClamp.- Parameters:
depthBiasClamp- The value for depthBiasClamp- Returns:
thisbuilder for use in a chained invocation
-
setDepthBiasSlopeFactor
public final VulkanPipelineRasterizationStateCreateInfo.Builder setDepthBiasSlopeFactor(float depthBiasSlopeFactor) Initializes the value for thedepthBiasSlopeFactorattribute.If not set, this attribute will have a default value as returned by the initializer of
depthBiasSlopeFactor.- Parameters:
depthBiasSlopeFactor- The value for depthBiasSlopeFactor- Returns:
thisbuilder for use in a chained invocation
-
setLineWidth
-
build
Builds a newVulkanPipelineRasterizationStateCreateInfo.- Returns:
- An immutable instance of VulkanPipelineRasterizationStateCreateInfo
- Throws:
IllegalStateException- if any required attributes are missing
-