# Class VulkanImageCreateInfo

java.lang.Object
com.io7m.jcoronado.api.VulkanImageCreateInfo

All Implemented Interfaces:
  `VulkanImageCreateInfoType`

public final class VulkanImageCreateInfo extends Object implements VulkanImageCreateInfoType

See Also:
  - "VkImageCreateInfo"

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static final class`
  `VulkanImageCreateInfo.Builder`
  Builds instances of type `VulkanImageCreateInfo`.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `arrayLayers()`
  `static VulkanImageCreateInfo.Builder`
  `builder()`
  Creates a builder for `VulkanImageCreateInfo`.
  `static VulkanImageCreateInfo`
  `copyOf(VulkanImageCreateInfoType instance)`
  Creates an immutable copy of a `VulkanImageCreateInfoType` value.
  `boolean`
  `equals(Object another)`
  This instance is equal to all instances of `VulkanImageCreateInfo` that have equal attribute values.
  `VulkanExtent3D`
  `extent()`
  `Set<VulkanImageCreateFlag>`
  `flags()`
  `VulkanFormat`
  `format()`
  `int`
  `hashCode()`
  Computes a hash code from attributes: `flags`, `imageType`, `format`, `extent`, `mipLevels`, `arrayLayers`, `samples`, `tiling`, `usage`, `sharingMode`, `queueFamilyIndices`, `initialLayout`.
  `VulkanImageKind`
  `imageType()`
  `VulkanImageLayout`
  `initialLayout()`
  `int`
  `mipLevels()`
  `List<Integer>`
  `queueFamilyIndices()`
  `Set<VulkanSampleCountFlag>`
  `samples()`
  `VulkanSharingMode`
  `sharingMode()`
  `VulkanImageTiling`
  `tiling()`
  `String`
  `toString()`
  Prints the immutable value `VulkanImageCreateInfo` with attribute values.
  `Set<VulkanImageUsageFlag>`
  `usage()`
  `final VulkanImageCreateInfo`
  `withArrayLayers(int value)`
  Copy the current immutable object by setting a value for the `arrayLayers` attribute.
  `final VulkanImageCreateInfo`
  `withExtent(VulkanExtent3D value)`
  Copy the current immutable object by setting a value for the `extent` attribute.
  `final VulkanImageCreateInfo`
  `withFlags(VulkanImageCreateFlag... elements)`
  Copy the current immutable object with elements that replace the content of `flags`.
  `final VulkanImageCreateInfo`
  `withFlags(Iterable<VulkanImageCreateFlag> elements)`
  Copy the current immutable object with elements that replace the content of `flags`.
  `final VulkanImageCreateInfo`
  `withFormat(VulkanFormat value)`
  Copy the current immutable object by setting a value for the `format` attribute.
  `final VulkanImageCreateInfo`
  `withImageType(VulkanImageKind value)`
  Copy the current immutable object by setting a value for the `imageType` attribute.
  `final VulkanImageCreateInfo`
  `withInitialLayout(VulkanImageLayout value)`
  Copy the current immutable object by setting a value for the `initialLayout` attribute.
  `final VulkanImageCreateInfo`
  `withMipLevels(int value)`
  Copy the current immutable object by setting a value for the `mipLevels` attribute.
  `final VulkanImageCreateInfo`
  `withQueueFamilyIndices(int... elements)`
  Copy the current immutable object with elements that replace the content of `queueFamilyIndices`.
  `final VulkanImageCreateInfo`
  `withQueueFamilyIndices(Iterable<Integer> elements)`
  Copy the current immutable object with elements that replace the content of `queueFamilyIndices`.
  `final VulkanImageCreateInfo`
  `withSamples(VulkanSampleCountFlag... elements)`
  Copy the current immutable object with elements that replace the content of `samples`.
  `final VulkanImageCreateInfo`
  `withSamples(Iterable<VulkanSampleCountFlag> elements)`
  Copy the current immutable object with elements that replace the content of `samples`.
  `final VulkanImageCreateInfo`
  `withSharingMode(VulkanSharingMode value)`
  Copy the current immutable object by setting a value for the `sharingMode` attribute.
  `final VulkanImageCreateInfo`
  `withTiling(VulkanImageTiling value)`
  Copy the current immutable object by setting a value for the `tiling` attribute.
  `final VulkanImageCreateInfo`
  `withUsage(VulkanImageUsageFlag... elements)`
  Copy the current immutable object with elements that replace the content of `usage`.
  `final VulkanImageCreateInfo`
  `withUsage(Iterable<VulkanImageUsageFlag> elements)`
  Copy the current immutable object with elements that replace the content of `usage`.

  ### Methods inherited from class Object

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Method Details

  - ### flags

    public Set<VulkanImageCreateFlag> flags()
    Specified by:
      `flags` in interface `VulkanImageCreateInfoType`
    Returns:
      A set of flags describing additional parameters of the image.

  - ### imageType

    public VulkanImageKind imageType()
    Specified by:
      `imageType` in interface `VulkanImageCreateInfoType`
    Returns:
      A value specifying the basic dimensionality of the image. Layers in array textures do not count as a dimension for the purposes of the image type.

  - ### format

    public VulkanFormat format()
    Specified by:
      `format` in interface `VulkanImageCreateInfoType`
    Returns:
      A value describing the format and type of the texel blocks that will be contained in the image.

  - ### extent

    public VulkanExtent3D extent()
    Specified by:
      `extent` in interface `VulkanImageCreateInfoType`
    Returns:
      A value describing the number of data elements in each dimension of the base level.

  - ### mipLevels

    public int mipLevels()
    Specified by:
      `mipLevels` in interface `VulkanImageCreateInfoType`
    Returns:
      The number of levels of detail available for minified sampling of the image.

  - ### arrayLayers

    public int arrayLayers()
    Specified by:
      `arrayLayers` in interface `VulkanImageCreateInfoType`
    Returns:
      The the number of layers in the image.

  - ### samples

    public Set<VulkanSampleCountFlag> samples()
    Specified by:
      `samples` in interface `VulkanImageCreateInfoType`
    Returns:
      A value specifying the number of samples per texel.

  - ### tiling

    public VulkanImageTiling tiling()
    Specified by:
      `tiling` in interface `VulkanImageCreateInfoType`
    Returns:
      A value specifying the tiling arrangement of the texel blocks in memory.

  - ### usage

    public Set<VulkanImageUsageFlag> usage()
    Specified by:
      `usage` in interface `VulkanImageCreateInfoType`
    Returns:
      A value describing the intended usage of the image.

  - ### sharingMode

    public VulkanSharingMode sharingMode()
    Specified by:
      `sharingMode` in interface `VulkanImageCreateInfoType`
    Returns:
      A value specifying the sharing mode of the image when it will be accessed by multiple queue families.

  - ### queueFamilyIndices

    public List<Integer> queueFamilyIndices()
    Specified by:
      `queueFamilyIndices` in interface `VulkanImageCreateInfoType`
    Returns:
      A list of queue families that will access this image (ignored if sharingMode is not VK_SHARING_MODE_CONCURRENT).

  - ### initialLayout

    public VulkanImageLayout initialLayout()
    Specified by:
      `initialLayout` in interface `VulkanImageCreateInfoType`
    Returns:
      A value specifying the initial layout of all image subresources of the image.

  - ### withFlags

    public final VulkanImageCreateInfo withFlags(VulkanImageCreateFlag... elements)
    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

    public final VulkanImageCreateInfo withFlags(Iterable<VulkanImageCreateFlag> elements)
    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 or `this` if not changed

  - ### withImageType

    public final VulkanImageCreateInfo withImageType(VulkanImageKind value)
    Copy the current immutable object by setting a value for the `imageType` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for imageType
    Returns:
      A modified copy or the `this` object

  - ### withFormat

    public final VulkanImageCreateInfo withFormat(VulkanFormat value)
    Copy the current immutable object by setting a value for the `format` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for format
    Returns:
      A modified copy or the `this` object

  - ### withExtent

    public final VulkanImageCreateInfo withExtent(VulkanExtent3D value)
    Copy the current immutable object by setting a value for the `extent` attribute. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for extent
    Returns:
      A modified copy or the `this` object

  - ### withMipLevels

    public final VulkanImageCreateInfo withMipLevels(int value)
    Copy the current immutable object by setting a value for the `mipLevels` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for mipLevels
    Returns:
      A modified copy or the `this` object

  - ### withArrayLayers

    public final VulkanImageCreateInfo withArrayLayers(int value)
    Copy the current immutable object by setting a value for the `arrayLayers` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for arrayLayers
    Returns:
      A modified copy or the `this` object

  - ### withSamples

    public final VulkanImageCreateInfo withSamples(VulkanSampleCountFlag... elements)
    Copy the current immutable object with elements that replace the content of `samples`.
    Parameters:
      `elements` - The elements to set
    Returns:
      A modified copy of `this` object

  - ### withSamples

    public final VulkanImageCreateInfo withSamples(Iterable<VulkanSampleCountFlag> elements)
    Copy the current immutable object with elements that replace the content of `samples`. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `elements` - An iterable of samples elements to set
    Returns:
      A modified copy or `this` if not changed

  - ### withTiling

    public final VulkanImageCreateInfo withTiling(VulkanImageTiling value)
    Copy the current immutable object by setting a value for the `tiling` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for tiling
    Returns:
      A modified copy or the `this` object

  - ### withUsage

    public final VulkanImageCreateInfo withUsage(VulkanImageUsageFlag... elements)
    Copy the current immutable object with elements that replace the content of `usage`.
    Parameters:
      `elements` - The elements to set
    Returns:
      A modified copy of `this` object

  - ### withUsage

    public final VulkanImageCreateInfo withUsage(Iterable<VulkanImageUsageFlag> elements)
    Copy the current immutable object with elements that replace the content of `usage`. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `elements` - An iterable of usage elements to set
    Returns:
      A modified copy or `this` if not changed

  - ### withSharingMode

    public final VulkanImageCreateInfo withSharingMode(VulkanSharingMode value)
    Copy the current immutable object by setting a value for the `sharingMode` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for sharingMode
    Returns:
      A modified copy or the `this` object

  - ### withQueueFamilyIndices

    public final VulkanImageCreateInfo withQueueFamilyIndices(int... elements)
    Copy the current immutable object with elements that replace the content of `queueFamilyIndices`.
    Parameters:
      `elements` - The elements to set
    Returns:
      A modified copy of `this` object

  - ### withQueueFamilyIndices

    public final VulkanImageCreateInfo withQueueFamilyIndices(Iterable<Integer> elements)
    Copy the current immutable object with elements that replace the content of `queueFamilyIndices`. A shallow reference equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `elements` - An iterable of queueFamilyIndices elements to set
    Returns:
      A modified copy or `this` if not changed

  - ### withInitialLayout

    public final VulkanImageCreateInfo withInitialLayout(VulkanImageLayout value)
    Copy the current immutable object by setting a value for the `initialLayout` attribute. A value equality check is used to prevent copying of the same value by returning `this`.
    Parameters:
      `value` - A new value for initialLayout
    Returns:
      A modified copy or the `this` object

  - ### equals

    public boolean equals(Object another)
    This instance is equal to all instances of `VulkanImageCreateInfo` 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`, `imageType`, `format`, `extent`, `mipLevels`, `arrayLayers`, `samples`, `tiling`, `usage`, `sharingMode`, `queueFamilyIndices`, `initialLayout`.
    Overrides:
      `hashCode` in class `Object`
    Returns:
      hashCode value

  - ### toString

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

  - ### copyOf

    public static VulkanImageCreateInfo copyOf(VulkanImageCreateInfoType instance)
    Creates an immutable copy of a `VulkanImageCreateInfoType` 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 VulkanImageCreateInfo instance

  - ### builder

    public static VulkanImageCreateInfo.Builder builder()
    Creates a builder for `VulkanImageCreateInfo`.

        VulkanImageCreateInfo.builder()
           .addFlags|addAllFlags(com.io7m.jcoronado.api.VulkanImageCreateFlag) // flags elements
           .setImageType(com.io7m.jcoronado.api.VulkanImageKind) // optional imageType
           .setFormat(com.io7m.jcoronado.api.VulkanFormat) // optional format
           .setExtent(com.io7m.jcoronado.api.VulkanExtent3D) // optional extent
           .setMipLevels(int) // optional mipLevels
           .setArrayLayers(int) // optional arrayLayers
           .addSamples|addAllSamples(com.io7m.jcoronado.api.VulkanSampleCountFlag) // samples elements
           .setTiling(com.io7m.jcoronado.api.VulkanImageTiling) // optional tiling
           .addUsage|addAllUsage(com.io7m.jcoronado.api.VulkanImageUsageFlag) // usage elements
           .setSharingMode(com.io7m.jcoronado.api.VulkanSharingMode) // optional sharingMode
           .addQueueFamilyIndices|addAllQueueFamilyIndices(int) // queueFamilyIndices elements
           .setInitialLayout(com.io7m.jcoronado.api.VulkanImageLayout) // optional initialLayout
           .build();

    Returns:
      A new VulkanImageCreateInfo builder