Class VulkanDescriptorImageInfo

java.lang.Object
com.io7m.jcoronado.api.VulkanDescriptorImageInfo
All Implemented Interfaces:
VulkanDescriptorImageInfoType

public final class VulkanDescriptorImageInfo extends Object implements VulkanDescriptorImageInfoType
See Also:
  • "VkDescriptorImageInfo"
  • Method Details

    • sampler

      public VulkanSamplerType sampler()
      Specified by:
      sampler in interface VulkanDescriptorImageInfoType
      Returns:
      A sampler handle, and is used in descriptor updates for types VK_DESCRIPTOR_TYPE_SAMPLER and VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER if the binding being updated does not use immutable samplers.
    • imageView

      public VulkanImageViewType imageView()
      Specified by:
      imageView in interface VulkanDescriptorImageInfoType
      Returns:
      An image view handle, and is used in descriptor updates for types VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE, VK_DESCRIPTOR_TYPE_STORAGE_IMAGE, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, and VK_DESCRIPTOR_TYPE_INPUT_ATTACHMENT.
    • imageLayout

      public VulkanImageLayout imageLayout()
      Specified by:
      imageLayout in interface VulkanDescriptorImageInfoType
      Returns:
      The layout that the image subresources accessible from imageView will be in at the time this descriptor is accessed. imageLayout is used in descriptor updates for types VK_DESCRIPTOR_TYPE_SAMPLED_IMAGE, VK_DESCRIPTOR_TYPE_STORAGE_IMAGE, VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER, and VK_DESCRIPTOR_TYPE_INPUT_ATTACHMENT.
    • withSampler

      public final VulkanDescriptorImageInfo withSampler(VulkanSamplerType value)
      Copy the current immutable object by setting a value for the sampler attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for sampler
      Returns:
      A modified copy of the this object
    • withImageView

      public final VulkanDescriptorImageInfo withImageView(VulkanImageViewType value)
      Copy the current immutable object by setting a value for the imageView attribute. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for imageView
      Returns:
      A modified copy of the this object
    • withImageLayout

      public final VulkanDescriptorImageInfo withImageLayout(VulkanImageLayout value)
      Copy the current immutable object by setting a value for the imageLayout attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for imageLayout
      Returns:
      A modified copy of the this object
    • equals

      public boolean equals(Object another)
      This instance is equal to all instances of VulkanDescriptorImageInfo that have equal attribute values.
      Overrides:
      equals in class Object
      Returns:
      true if this is equal to another instance
    • hashCode

      public int hashCode()
      Computes a hash code from attributes: sampler, imageView, imageLayout.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

      public String toString()
      Prints the immutable value VulkanDescriptorImageInfo with attribute values.
      Overrides:
      toString in class Object
      Returns:
      A string representation of the value
    • of

      public static VulkanDescriptorImageInfo of(VulkanSamplerType sampler, VulkanImageViewType imageView, VulkanImageLayout imageLayout)
      Construct a new immutable VulkanDescriptorImageInfo instance.
      Parameters:
      sampler - The value for the sampler attribute
      imageView - The value for the imageView attribute
      imageLayout - The value for the imageLayout attribute
      Returns:
      An immutable VulkanDescriptorImageInfo instance
    • copyOf

      Creates an immutable copy of a VulkanDescriptorImageInfoType value. 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 VulkanDescriptorImageInfo instance
    • builder

      public static VulkanDescriptorImageInfo.Builder builder()
      Creates a builder for VulkanDescriptorImageInfo.
       VulkanDescriptorImageInfo.builder()
          .setSampler(com.io7m.jcoronado.api.VulkanSamplerType) // required sampler
          .setImageView(com.io7m.jcoronado.api.VulkanImageViewType) // required imageView
          .setImageLayout(com.io7m.jcoronado.api.VulkanImageLayout) // required imageLayout
          .build();
       
      Returns:
      A new VulkanDescriptorImageInfo builder