Class VulkanPipelineMultisampleStateCreateInfo

java.lang.Object
com.io7m.jcoronado.api.VulkanPipelineMultisampleStateCreateInfo
All Implemented Interfaces:
VulkanPipelineMultisampleStateCreateInfoType

public final class VulkanPipelineMultisampleStateCreateInfo extends Object implements VulkanPipelineMultisampleStateCreateInfoType
See Also:
  • "VkPipelineMultisampleStateCreateInfo"
  • Method Details

    • flags

      Specified by:
      flags in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      Flags reserved for future use
    • rasterizationSamples

      public VulkanSampleCountFlag rasterizationSamples()
      Specified by:
      rasterizationSamples in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      The number of samples per pixel used in rasterization.
    • sampleShadingEnable

      public boolean sampleShadingEnable()
      Specified by:
      sampleShadingEnable in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      true if sample shading should be enabled
    • minSampleShading

      public float minSampleShading()
      Specified by:
      minSampleShading in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      minimum fraction of sample shading if sampleShadingEnable() is true
    • sampleMask

      public Optional<int[]> sampleMask()
      Specified by:
      sampleMask in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      static coverage information that is ANDed with the coverage information generated during rasterization.
    • alphaToCoverageEnable

      public boolean alphaToCoverageEnable()
      Specified by:
      alphaToCoverageEnable in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      true if a temporary coverage value is generated based on the alpha component of the fragment’s first color output
    • alphaToOneEnable

      public boolean alphaToOneEnable()
      Specified by:
      alphaToOneEnable in interface VulkanPipelineMultisampleStateCreateInfoType
      Returns:
      true if the alpha component of the fragment’s first color output is replaced with one as described in "Multisample Coverage".
    • withFlags

      Copy the current immutable object with elements that replace the content of flags.
      Parameters:
      elements - The elements to set
      Returns:
      A modified copy of this object
    • withFlags

      Copy the current immutable object with elements that replace the content of flags. A shallow reference equality check is used to prevent copying of the same value by returning this.
      Parameters:
      elements - An iterable of flags elements to set
      Returns:
      A modified copy of this object
    • withRasterizationSamples

      public final VulkanPipelineMultisampleStateCreateInfo withRasterizationSamples(VulkanSampleCountFlag value)
      Copy the current immutable object by setting a value for the rasterizationSamples attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for rasterizationSamples
      Returns:
      A modified copy of the this object
    • withSampleShadingEnable

      public final VulkanPipelineMultisampleStateCreateInfo withSampleShadingEnable(boolean value)
      Copy the current immutable object by setting a value for the sampleShadingEnable attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for sampleShadingEnable
      Returns:
      A modified copy of the this object
    • withMinSampleShading

      public final VulkanPipelineMultisampleStateCreateInfo withMinSampleShading(float value)
      Copy the current immutable object by setting a value for the minSampleShading attribute. A value strict bits equality used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for minSampleShading
      Returns:
      A modified copy of the this object
    • withSampleMask

      public final VulkanPipelineMultisampleStateCreateInfo withSampleMask(int[] value)
      Copy the current immutable object by setting a present value for the optional sampleMask attribute.
      Parameters:
      value - The value for sampleMask
      Returns:
      A modified copy of this object
    • withSampleMask

      public final VulkanPipelineMultisampleStateCreateInfo withSampleMask(Optional<? extends int[]> optional)
      Copy the current immutable object by setting an optional value for the sampleMask attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returning this.
      Parameters:
      optional - A value for sampleMask
      Returns:
      A modified copy of this object
    • withAlphaToCoverageEnable

      public final VulkanPipelineMultisampleStateCreateInfo withAlphaToCoverageEnable(boolean value)
      Copy the current immutable object by setting a value for the alphaToCoverageEnable attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for alphaToCoverageEnable
      Returns:
      A modified copy of the this object
    • withAlphaToOneEnable

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

      public boolean equals(Object another)
      This instance is equal to all instances of VulkanPipelineMultisampleStateCreateInfo 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: flags, rasterizationSamples, sampleShadingEnable, minSampleShading, sampleMask, alphaToCoverageEnable, alphaToOneEnable.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

      public static VulkanPipelineMultisampleStateCreateInfo of(Set<VulkanPipelineMultisampleStateCreateFlag> flags, VulkanSampleCountFlag rasterizationSamples, boolean sampleShadingEnable, float minSampleShading, Optional<int[]> sampleMask, boolean alphaToCoverageEnable, boolean alphaToOneEnable)
      Construct a new immutable VulkanPipelineMultisampleStateCreateInfo instance.
      Parameters:
      flags - The value for the flags attribute
      rasterizationSamples - The value for the rasterizationSamples attribute
      sampleShadingEnable - The value for the sampleShadingEnable attribute
      minSampleShading - The value for the minSampleShading attribute
      sampleMask - The value for the sampleMask attribute
      alphaToCoverageEnable - The value for the alphaToCoverageEnable attribute
      alphaToOneEnable - The value for the alphaToOneEnable attribute
      Returns:
      An immutable VulkanPipelineMultisampleStateCreateInfo instance
    • of

      public static VulkanPipelineMultisampleStateCreateInfo of(Iterable<VulkanPipelineMultisampleStateCreateFlag> flags, VulkanSampleCountFlag rasterizationSamples, boolean sampleShadingEnable, float minSampleShading, Optional<? extends int[]> sampleMask, boolean alphaToCoverageEnable, boolean alphaToOneEnable)
      Construct a new immutable VulkanPipelineMultisampleStateCreateInfo instance.
      Parameters:
      flags - The value for the flags attribute
      rasterizationSamples - The value for the rasterizationSamples attribute
      sampleShadingEnable - The value for the sampleShadingEnable attribute
      minSampleShading - The value for the minSampleShading attribute
      sampleMask - The value for the sampleMask attribute
      alphaToCoverageEnable - The value for the alphaToCoverageEnable attribute
      alphaToOneEnable - The value for the alphaToOneEnable attribute
      Returns:
      An immutable VulkanPipelineMultisampleStateCreateInfo instance
    • copyOf

      Creates an immutable copy of a VulkanPipelineMultisampleStateCreateInfoType 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 VulkanPipelineMultisampleStateCreateInfo instance
    • builder

      Creates a builder for VulkanPipelineMultisampleStateCreateInfo.
       VulkanPipelineMultisampleStateCreateInfo.builder()
          .addFlags|addAllFlags(com.io7m.jcoronado.api.VulkanPipelineMultisampleStateCreateFlag) // flags elements
          .setRasterizationSamples(com.io7m.jcoronado.api.VulkanSampleCountFlag) // required rasterizationSamples
          .setSampleShadingEnable(boolean) // required sampleShadingEnable
          .setMinSampleShading(float) // required minSampleShading
          .setSampleMask(int[]) // optional sampleMask
          .setAlphaToCoverageEnable(boolean) // required alphaToCoverageEnable
          .setAlphaToOneEnable(boolean) // required alphaToOneEnable
          .build();
       
      Returns:
      A new VulkanPipelineMultisampleStateCreateInfo builder