Class VulkanStencilOpState.Builder
java.lang.Object
com.io7m.jcoronado.api.VulkanStencilOpState.Builder
- Enclosing class:
VulkanStencilOpState
Builds instances of type
VulkanStencilOpState.
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 TypeMethodDescriptionbuild()Builds a newVulkanStencilOpState.from(VulkanStencilOpStateType instance) Fill a builder with attribute values from the providedVulkanStencilOpStateTypeinstance.setCompareMask(int compareMask) Initializes the value for thecompareMaskattribute.setCompareOp(VulkanCompareOp compareOp) Initializes the value for thecompareOpattribute.setDepthFailOp(VulkanStencilOp depthFailOp) Initializes the value for thedepthFailOpattribute.setFailOp(VulkanStencilOp failOp) Initializes the value for thefailOpattribute.setPassOp(VulkanStencilOp passOp) Initializes the value for thepassOpattribute.setReference(int reference) Initializes the value for thereferenceattribute.setWriteMask(int writeMask) Initializes the value for thewriteMaskattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedVulkanStencilOpStateTypeinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
setFailOp
-
setPassOp
-
setDepthFailOp
Initializes the value for thedepthFailOpattribute.If not set, this attribute will have a default value as returned by the initializer of
depthFailOp.- Parameters:
depthFailOp- The value for depthFailOp- Returns:
thisbuilder for use in a chained invocation
-
setCompareOp
-
setCompareMask
Initializes the value for thecompareMaskattribute.If not set, this attribute will have a default value as returned by the initializer of
compareMask.- Parameters:
compareMask- The value for compareMask- Returns:
thisbuilder for use in a chained invocation
-
setWriteMask
-
setReference
-
build
Builds a newVulkanStencilOpState.- Returns:
- An immutable instance of VulkanStencilOpState
- Throws:
IllegalStateException- if any required attributes are missing
-