{-# language CPP #-}
-- No documentation found for Chapter "ImageAspectFlagBits"
module Vulkan.Core10.Enums.ImageAspectFlagBits  ( ImageAspectFlags
                                                , ImageAspectFlagBits( IMAGE_ASPECT_COLOR_BIT
                                                                     , IMAGE_ASPECT_DEPTH_BIT
                                                                     , IMAGE_ASPECT_STENCIL_BIT
                                                                     , IMAGE_ASPECT_METADATA_BIT
                                                                     , IMAGE_ASPECT_MEMORY_PLANE_3_BIT_EXT
                                                                     , IMAGE_ASPECT_MEMORY_PLANE_2_BIT_EXT
                                                                     , IMAGE_ASPECT_MEMORY_PLANE_1_BIT_EXT
                                                                     , IMAGE_ASPECT_MEMORY_PLANE_0_BIT_EXT
                                                                     , IMAGE_ASPECT_NONE
                                                                     , IMAGE_ASPECT_PLANE_2_BIT
                                                                     , IMAGE_ASPECT_PLANE_1_BIT
                                                                     , IMAGE_ASPECT_PLANE_0_BIT
                                                                     , ..
                                                                     )
                                                ) where

import Data.Bits (Bits)
import Data.Bits (FiniteBits)
import Vulkan.Internal.Utils (enumReadPrec)
import Vulkan.Internal.Utils (enumShowsPrec)
import GHC.Show (showString)
import Numeric (showHex)
import Vulkan.Zero (Zero)
import Foreign.Storable (Storable)
import GHC.Read (Read(readPrec))
import GHC.Show (Show(showsPrec))
import Vulkan.Core10.FundamentalTypes (Flags)
type ImageAspectFlags = ImageAspectFlagBits

-- | VkImageAspectFlagBits - Bitmask specifying which aspects of an image are
-- included in a view
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_VERSION_1_0 VK_VERSION_1_0>,
-- 'Vulkan.Core11.Promoted_From_VK_KHR_sampler_ycbcr_conversion.BindImagePlaneMemoryInfo',
-- 'Vulkan.Core13.Promoted_From_VK_KHR_maintenance4.DeviceImageMemoryRequirements',
-- 'Vulkan.Extensions.VK_EXT_metal_objects.ExportMetalTextureInfoEXT',
-- 'ImageAspectFlags',
-- 'Vulkan.Core11.Promoted_From_VK_KHR_sampler_ycbcr_conversion.ImagePlaneMemoryRequirementsInfo',
-- 'Vulkan.Extensions.VK_EXT_metal_objects.ImportMetalTextureInfoEXT'
newtype ImageAspectFlagBits = ImageAspectFlagBits Flags
  deriving newtype (ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
$c/= :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
== :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
$c== :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
Eq, Eq ImageAspectFlagBits
ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
ImageAspectFlagBits -> ImageAspectFlagBits -> Ordering
ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
$cmin :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
max :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
$cmax :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
>= :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
$c>= :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
> :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
$c> :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
<= :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
$c<= :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
< :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
$c< :: ImageAspectFlagBits -> ImageAspectFlagBits -> Bool
compare :: ImageAspectFlagBits -> ImageAspectFlagBits -> Ordering
$ccompare :: ImageAspectFlagBits -> ImageAspectFlagBits -> Ordering
Ord, Ptr ImageAspectFlagBits -> IO ImageAspectFlagBits
Ptr ImageAspectFlagBits -> Int -> IO ImageAspectFlagBits
Ptr ImageAspectFlagBits -> Int -> ImageAspectFlagBits -> IO ()
Ptr ImageAspectFlagBits -> ImageAspectFlagBits -> IO ()
ImageAspectFlagBits -> Int
forall b. Ptr b -> Int -> IO ImageAspectFlagBits
forall b. Ptr b -> Int -> ImageAspectFlagBits -> IO ()
forall a.
(a -> Int)
-> (a -> Int)
-> (Ptr a -> Int -> IO a)
-> (Ptr a -> Int -> a -> IO ())
-> (forall b. Ptr b -> Int -> IO a)
-> (forall b. Ptr b -> Int -> a -> IO ())
-> (Ptr a -> IO a)
-> (Ptr a -> a -> IO ())
-> Storable a
poke :: Ptr ImageAspectFlagBits -> ImageAspectFlagBits -> IO ()
$cpoke :: Ptr ImageAspectFlagBits -> ImageAspectFlagBits -> IO ()
peek :: Ptr ImageAspectFlagBits -> IO ImageAspectFlagBits
$cpeek :: Ptr ImageAspectFlagBits -> IO ImageAspectFlagBits
pokeByteOff :: forall b. Ptr b -> Int -> ImageAspectFlagBits -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> ImageAspectFlagBits -> IO ()
peekByteOff :: forall b. Ptr b -> Int -> IO ImageAspectFlagBits
$cpeekByteOff :: forall b. Ptr b -> Int -> IO ImageAspectFlagBits
pokeElemOff :: Ptr ImageAspectFlagBits -> Int -> ImageAspectFlagBits -> IO ()
$cpokeElemOff :: Ptr ImageAspectFlagBits -> Int -> ImageAspectFlagBits -> IO ()
peekElemOff :: Ptr ImageAspectFlagBits -> Int -> IO ImageAspectFlagBits
$cpeekElemOff :: Ptr ImageAspectFlagBits -> Int -> IO ImageAspectFlagBits
alignment :: ImageAspectFlagBits -> Int
$calignment :: ImageAspectFlagBits -> Int
sizeOf :: ImageAspectFlagBits -> Int
$csizeOf :: ImageAspectFlagBits -> Int
Storable, ImageAspectFlagBits
forall a. a -> Zero a
zero :: ImageAspectFlagBits
$czero :: ImageAspectFlagBits
Zero, Eq ImageAspectFlagBits
ImageAspectFlagBits
Int -> ImageAspectFlagBits
ImageAspectFlagBits -> Bool
ImageAspectFlagBits -> Int
ImageAspectFlagBits -> Maybe Int
ImageAspectFlagBits -> ImageAspectFlagBits
ImageAspectFlagBits -> Int -> Bool
ImageAspectFlagBits -> Int -> ImageAspectFlagBits
ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
forall a.
Eq a
-> (a -> a -> a)
-> (a -> a -> a)
-> (a -> a -> a)
-> (a -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> a
-> (Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> Bool)
-> (a -> Maybe Int)
-> (a -> Int)
-> (a -> Bool)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int)
-> Bits a
popCount :: ImageAspectFlagBits -> Int
$cpopCount :: ImageAspectFlagBits -> Int
rotateR :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$crotateR :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
rotateL :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$crotateL :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
unsafeShiftR :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$cunsafeShiftR :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
shiftR :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$cshiftR :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
unsafeShiftL :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$cunsafeShiftL :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
shiftL :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$cshiftL :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
isSigned :: ImageAspectFlagBits -> Bool
$cisSigned :: ImageAspectFlagBits -> Bool
bitSize :: ImageAspectFlagBits -> Int
$cbitSize :: ImageAspectFlagBits -> Int
bitSizeMaybe :: ImageAspectFlagBits -> Maybe Int
$cbitSizeMaybe :: ImageAspectFlagBits -> Maybe Int
testBit :: ImageAspectFlagBits -> Int -> Bool
$ctestBit :: ImageAspectFlagBits -> Int -> Bool
complementBit :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$ccomplementBit :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
clearBit :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$cclearBit :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
setBit :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$csetBit :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
bit :: Int -> ImageAspectFlagBits
$cbit :: Int -> ImageAspectFlagBits
zeroBits :: ImageAspectFlagBits
$czeroBits :: ImageAspectFlagBits
rotate :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$crotate :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
shift :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
$cshift :: ImageAspectFlagBits -> Int -> ImageAspectFlagBits
complement :: ImageAspectFlagBits -> ImageAspectFlagBits
$ccomplement :: ImageAspectFlagBits -> ImageAspectFlagBits
xor :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
$cxor :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
.|. :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
$c.|. :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
.&. :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
$c.&. :: ImageAspectFlagBits -> ImageAspectFlagBits -> ImageAspectFlagBits
Bits, Bits ImageAspectFlagBits
ImageAspectFlagBits -> Int
forall b.
Bits b -> (b -> Int) -> (b -> Int) -> (b -> Int) -> FiniteBits b
countTrailingZeros :: ImageAspectFlagBits -> Int
$ccountTrailingZeros :: ImageAspectFlagBits -> Int
countLeadingZeros :: ImageAspectFlagBits -> Int
$ccountLeadingZeros :: ImageAspectFlagBits -> Int
finiteBitSize :: ImageAspectFlagBits -> Int
$cfiniteBitSize :: ImageAspectFlagBits -> Int
FiniteBits)

-- | 'IMAGE_ASPECT_COLOR_BIT' specifies the color aspect.
pattern $bIMAGE_ASPECT_COLOR_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_COLOR_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_COLOR_BIT = ImageAspectFlagBits 0x00000001

-- | 'IMAGE_ASPECT_DEPTH_BIT' specifies the depth aspect.
pattern $bIMAGE_ASPECT_DEPTH_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_DEPTH_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_DEPTH_BIT = ImageAspectFlagBits 0x00000002

-- | 'IMAGE_ASPECT_STENCIL_BIT' specifies the stencil aspect.
pattern $bIMAGE_ASPECT_STENCIL_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_STENCIL_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_STENCIL_BIT = ImageAspectFlagBits 0x00000004

-- | 'IMAGE_ASPECT_METADATA_BIT' specifies the metadata aspect used for
-- <https://registry.khronos.org/vulkan/specs/1.3-extensions/html/vkspec.html#sparsememory sparse resource>
-- operations.
pattern $bIMAGE_ASPECT_METADATA_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_METADATA_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_METADATA_BIT = ImageAspectFlagBits 0x00000008

-- | 'IMAGE_ASPECT_MEMORY_PLANE_3_BIT_EXT' specifies /memory plane/ 3.
pattern $bIMAGE_ASPECT_MEMORY_PLANE_3_BIT_EXT :: ImageAspectFlagBits
$mIMAGE_ASPECT_MEMORY_PLANE_3_BIT_EXT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_MEMORY_PLANE_3_BIT_EXT = ImageAspectFlagBits 0x00000400

-- | 'IMAGE_ASPECT_MEMORY_PLANE_2_BIT_EXT' specifies /memory plane/ 2.
pattern $bIMAGE_ASPECT_MEMORY_PLANE_2_BIT_EXT :: ImageAspectFlagBits
$mIMAGE_ASPECT_MEMORY_PLANE_2_BIT_EXT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_MEMORY_PLANE_2_BIT_EXT = ImageAspectFlagBits 0x00000200

-- | 'IMAGE_ASPECT_MEMORY_PLANE_1_BIT_EXT' specifies /memory plane/ 1.
pattern $bIMAGE_ASPECT_MEMORY_PLANE_1_BIT_EXT :: ImageAspectFlagBits
$mIMAGE_ASPECT_MEMORY_PLANE_1_BIT_EXT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_MEMORY_PLANE_1_BIT_EXT = ImageAspectFlagBits 0x00000100

-- | 'IMAGE_ASPECT_MEMORY_PLANE_0_BIT_EXT' specifies /memory plane/ 0.
pattern $bIMAGE_ASPECT_MEMORY_PLANE_0_BIT_EXT :: ImageAspectFlagBits
$mIMAGE_ASPECT_MEMORY_PLANE_0_BIT_EXT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_MEMORY_PLANE_0_BIT_EXT = ImageAspectFlagBits 0x00000080

-- | 'IMAGE_ASPECT_NONE' specifies no image aspect, or the image aspect is
-- not applicable.
pattern $bIMAGE_ASPECT_NONE :: ImageAspectFlagBits
$mIMAGE_ASPECT_NONE :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_NONE = ImageAspectFlagBits 0x00000000

-- | 'IMAGE_ASPECT_PLANE_2_BIT' specifies plane 2 of a /multi-planar/ image
-- format.
pattern $bIMAGE_ASPECT_PLANE_2_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_PLANE_2_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_PLANE_2_BIT = ImageAspectFlagBits 0x00000040

-- | 'IMAGE_ASPECT_PLANE_1_BIT' specifies plane 1 of a /multi-planar/ image
-- format.
pattern $bIMAGE_ASPECT_PLANE_1_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_PLANE_1_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_PLANE_1_BIT = ImageAspectFlagBits 0x00000020

-- | 'IMAGE_ASPECT_PLANE_0_BIT' specifies plane 0 of a /multi-planar/ image
-- format.
pattern $bIMAGE_ASPECT_PLANE_0_BIT :: ImageAspectFlagBits
$mIMAGE_ASPECT_PLANE_0_BIT :: forall {r}.
ImageAspectFlagBits -> ((# #) -> r) -> ((# #) -> r) -> r
IMAGE_ASPECT_PLANE_0_BIT = ImageAspectFlagBits 0x00000010

conNameImageAspectFlagBits :: String
conNameImageAspectFlagBits :: String
conNameImageAspectFlagBits = String
"ImageAspectFlagBits"

enumPrefixImageAspectFlagBits :: String
enumPrefixImageAspectFlagBits :: String
enumPrefixImageAspectFlagBits = String
"IMAGE_ASPECT_"

showTableImageAspectFlagBits :: [(ImageAspectFlagBits, String)]
showTableImageAspectFlagBits :: [(ImageAspectFlagBits, String)]
showTableImageAspectFlagBits =
  [ (ImageAspectFlagBits
IMAGE_ASPECT_COLOR_BIT, String
"COLOR_BIT")
  , (ImageAspectFlagBits
IMAGE_ASPECT_DEPTH_BIT, String
"DEPTH_BIT")
  , (ImageAspectFlagBits
IMAGE_ASPECT_STENCIL_BIT, String
"STENCIL_BIT")
  , (ImageAspectFlagBits
IMAGE_ASPECT_METADATA_BIT, String
"METADATA_BIT")
  ,
    ( ImageAspectFlagBits
IMAGE_ASPECT_MEMORY_PLANE_3_BIT_EXT
    , String
"MEMORY_PLANE_3_BIT_EXT"
    )
  ,
    ( ImageAspectFlagBits
IMAGE_ASPECT_MEMORY_PLANE_2_BIT_EXT
    , String
"MEMORY_PLANE_2_BIT_EXT"
    )
  ,
    ( ImageAspectFlagBits
IMAGE_ASPECT_MEMORY_PLANE_1_BIT_EXT
    , String
"MEMORY_PLANE_1_BIT_EXT"
    )
  ,
    ( ImageAspectFlagBits
IMAGE_ASPECT_MEMORY_PLANE_0_BIT_EXT
    , String
"MEMORY_PLANE_0_BIT_EXT"
    )
  , (ImageAspectFlagBits
IMAGE_ASPECT_NONE, String
"NONE")
  , (ImageAspectFlagBits
IMAGE_ASPECT_PLANE_2_BIT, String
"PLANE_2_BIT")
  , (ImageAspectFlagBits
IMAGE_ASPECT_PLANE_1_BIT, String
"PLANE_1_BIT")
  , (ImageAspectFlagBits
IMAGE_ASPECT_PLANE_0_BIT, String
"PLANE_0_BIT")
  ]

instance Show ImageAspectFlagBits where
  showsPrec :: Int -> ImageAspectFlagBits -> ShowS
showsPrec =
    forall a i.
Eq a =>
String
-> [(a, String)]
-> String
-> (a -> i)
-> (i -> ShowS)
-> Int
-> a
-> ShowS
enumShowsPrec
      String
enumPrefixImageAspectFlagBits
      [(ImageAspectFlagBits, String)]
showTableImageAspectFlagBits
      String
conNameImageAspectFlagBits
      (\(ImageAspectFlagBits Flags
x) -> Flags
x)
      (\Flags
x -> String -> ShowS
showString String
"0x" forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall a. (Integral a, Show a) => a -> ShowS
showHex Flags
x)

instance Read ImageAspectFlagBits where
  readPrec :: ReadPrec ImageAspectFlagBits
readPrec =
    forall i a.
Read i =>
String -> [(a, String)] -> String -> (i -> a) -> ReadPrec a
enumReadPrec
      String
enumPrefixImageAspectFlagBits
      [(ImageAspectFlagBits, String)]
showTableImageAspectFlagBits
      String
conNameImageAspectFlagBits
      Flags -> ImageAspectFlagBits
ImageAspectFlagBits