Class VulkanComputePipelineCreateInfo
java.lang.Object
com.io7m.jcoronado.api.VulkanComputePipelineCreateInfo
- All Implemented Interfaces:
VulkanComputePipelineCreateInfoType
public final class VulkanComputePipelineCreateInfo
extends Object
implements VulkanComputePipelineCreateInfoType
Structure specifying parameters of a newly created compute pipeline.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeVulkanComputePipelineCreateInfo. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forVulkanComputePipelineCreateInfo.copyOf(VulkanComputePipelineCreateInfoType instance) Creates an immutable copy of aVulkanComputePipelineCreateInfoTypevalue.booleanThis instance is equal to all instances ofVulkanComputePipelineCreateInfothat have equal attribute values.flags()inthashCode()Computes a hash code from attributes:flags,stage,layout,basePipeline,basePipelineIndex.layout()of(Iterable<VulkanPipelineCreateFlag> flags, VulkanPipelineShaderStageCreateInfo stage, VulkanPipelineLayoutType layout, Optional<? extends VulkanPipelineType> basePipeline, OptionalInt basePipelineIndex) Construct a new immutableVulkanComputePipelineCreateInfoinstance.of(Set<VulkanPipelineCreateFlag> flags, VulkanPipelineShaderStageCreateInfo stage, VulkanPipelineLayoutType layout, Optional<VulkanPipelineType> basePipeline, OptionalInt basePipelineIndex) Construct a new immutableVulkanComputePipelineCreateInfoinstance.stage()toString()Prints the immutable valueVulkanComputePipelineCreateInfowith attribute values.Copy the current immutable object by setting a present value for the optionalbasePipelineattribute.withBasePipeline(Optional<? extends VulkanPipelineType> optional) Copy the current immutable object by setting an optional value for thebasePipelineattribute.withBasePipelineIndex(int value) Copy the current immutable object by setting a present value for the optionalbasePipelineIndexattribute.withBasePipelineIndex(OptionalInt optional) Copy the current immutable object by setting an optional value for thebasePipelineIndexattribute.withFlags(VulkanPipelineCreateFlag... elements) Copy the current immutable object with elements that replace the content offlags.withFlags(Iterable<VulkanPipelineCreateFlag> elements) Copy the current immutable object with elements that replace the content offlags.Copy the current immutable object by setting a value for thelayoutattribute.Copy the current immutable object by setting a value for thestageattribute.
-
Method Details
-
flags
- Specified by:
flagsin interfaceVulkanComputePipelineCreateInfoType- Returns:
- Flags specifying how the pipeline will be generated.
-
stage
- Specified by:
stagein interfaceVulkanComputePipelineCreateInfoType- Returns:
- The shader stages to be included in the graphics pipeline.
-
layout
- Specified by:
layoutin interfaceVulkanComputePipelineCreateInfoType- Returns:
- The description of binding locations used by both the pipeline and descriptor sets used with the pipeline.
-
basePipeline
- Specified by:
basePipelinein interfaceVulkanComputePipelineCreateInfoType- Returns:
- A pipeline to derive from.
-
basePipelineIndex
- Specified by:
basePipelineIndexin interfaceVulkanComputePipelineCreateInfoType- Returns:
- An index into the createInfos parameter to use as a pipeline to derive from.
-
withFlags
Copy the current immutable object with elements that replace the content offlags.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withFlags
Copy the current immutable object with elements that replace the content offlags. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of flags elements to set- Returns:
- A modified copy of
thisobject
-
withStage
Copy the current immutable object by setting a value for thestageattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for stage- Returns:
- A modified copy of the
thisobject
-
withLayout
Copy the current immutable object by setting a value for thelayoutattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for layout- Returns:
- A modified copy of the
thisobject
-
withBasePipeline
Copy the current immutable object by setting a present value for the optionalbasePipelineattribute.- Parameters:
value- The value for basePipeline- Returns:
- A modified copy of
thisobject
-
withBasePipeline
public final VulkanComputePipelineCreateInfo withBasePipeline(Optional<? extends VulkanPipelineType> optional) Copy the current immutable object by setting an optional value for thebasePipelineattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for basePipeline- Returns:
- A modified copy of
thisobject
-
withBasePipelineIndex
Copy the current immutable object by setting a present value for the optionalbasePipelineIndexattribute.- Parameters:
value- The value for basePipelineIndex- Returns:
- A modified copy of
thisobject
-
withBasePipelineIndex
Copy the current immutable object by setting an optional value for thebasePipelineIndexattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for basePipelineIndex- Returns:
- A modified copy of
thisobject
-
equals
-
hashCode
-
toString
-
of
public static VulkanComputePipelineCreateInfo of(Set<VulkanPipelineCreateFlag> flags, VulkanPipelineShaderStageCreateInfo stage, VulkanPipelineLayoutType layout, Optional<VulkanPipelineType> basePipeline, OptionalInt basePipelineIndex) Construct a new immutableVulkanComputePipelineCreateInfoinstance.- Parameters:
flags- The value for theflagsattributestage- The value for thestageattributelayout- The value for thelayoutattributebasePipeline- The value for thebasePipelineattributebasePipelineIndex- The value for thebasePipelineIndexattribute- Returns:
- An immutable VulkanComputePipelineCreateInfo instance
-
of
public static VulkanComputePipelineCreateInfo of(Iterable<VulkanPipelineCreateFlag> flags, VulkanPipelineShaderStageCreateInfo stage, VulkanPipelineLayoutType layout, Optional<? extends VulkanPipelineType> basePipeline, OptionalInt basePipelineIndex) Construct a new immutableVulkanComputePipelineCreateInfoinstance.- Parameters:
flags- The value for theflagsattributestage- The value for thestageattributelayout- The value for thelayoutattributebasePipeline- The value for thebasePipelineattributebasePipelineIndex- The value for thebasePipelineIndexattribute- Returns:
- An immutable VulkanComputePipelineCreateInfo instance
-
copyOf
Creates an immutable copy of aVulkanComputePipelineCreateInfoTypevalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable VulkanComputePipelineCreateInfo instance
-
builder
Creates a builder forVulkanComputePipelineCreateInfo.VulkanComputePipelineCreateInfo.builder() .addFlags|addAllFlags(com.io7m.jcoronado.api.VulkanPipelineCreateFlag) //flagselements .setStage(com.io7m.jcoronado.api.VulkanPipelineShaderStageCreateInfo) // requiredstage.setLayout(com.io7m.jcoronado.api.VulkanPipelineLayoutType) // requiredlayout.setBasePipeline(com.io7m.jcoronado.api.VulkanPipelineType) // optionalbasePipeline.setBasePipelineIndex(int) // optionalbasePipelineIndex.build();- Returns:
- A new VulkanComputePipelineCreateInfo builder
-