{-# language CPP #-}
-- No documentation found for Chapter "ShaderFloatControlsIndependence"
module Vulkan.Core12.Enums.ShaderFloatControlsIndependence  (ShaderFloatControlsIndependence( SHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY
                                                                                            , SHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL
                                                                                            , SHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE
                                                                                            , ..
                                                                                            )) where

import Vulkan.Internal.Utils (enumReadPrec)
import Vulkan.Internal.Utils (enumShowsPrec)
import GHC.Show (showsPrec)
import Vulkan.Zero (Zero)
import Foreign.Storable (Storable)
import Data.Int (Int32)
import GHC.Read (Read(readPrec))
import GHC.Show (Show(showsPrec))

-- | VkShaderFloatControlsIndependence - Bitmask specifying whether, and how,
-- shader float controls can be set separately
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_KHR_shader_float_controls VK_KHR_shader_float_controls>,
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_VERSION_1_2 VK_VERSION_1_2>,
-- 'Vulkan.Core12.Promoted_From_VK_KHR_shader_float_controls.PhysicalDeviceFloatControlsProperties',
-- 'Vulkan.Core12.PhysicalDeviceVulkan12Properties'
newtype ShaderFloatControlsIndependence = ShaderFloatControlsIndependence Int32
  deriving newtype (ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
$c/= :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
== :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
$c== :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
Eq, Eq ShaderFloatControlsIndependence
ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Ordering
ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
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 :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
$cmin :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
max :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
$cmax :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence
>= :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
$c>= :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
> :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
$c> :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
<= :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
$c<= :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
< :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
$c< :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Bool
compare :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Ordering
$ccompare :: ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> Ordering
Ord, Ptr ShaderFloatControlsIndependence
-> IO ShaderFloatControlsIndependence
Ptr ShaderFloatControlsIndependence
-> Int -> IO ShaderFloatControlsIndependence
Ptr ShaderFloatControlsIndependence
-> Int -> ShaderFloatControlsIndependence -> IO ()
Ptr ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> IO ()
ShaderFloatControlsIndependence -> Int
forall b. Ptr b -> Int -> IO ShaderFloatControlsIndependence
forall b. Ptr b -> Int -> ShaderFloatControlsIndependence -> 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 ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> IO ()
$cpoke :: Ptr ShaderFloatControlsIndependence
-> ShaderFloatControlsIndependence -> IO ()
peek :: Ptr ShaderFloatControlsIndependence
-> IO ShaderFloatControlsIndependence
$cpeek :: Ptr ShaderFloatControlsIndependence
-> IO ShaderFloatControlsIndependence
pokeByteOff :: forall b. Ptr b -> Int -> ShaderFloatControlsIndependence -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> ShaderFloatControlsIndependence -> IO ()
peekByteOff :: forall b. Ptr b -> Int -> IO ShaderFloatControlsIndependence
$cpeekByteOff :: forall b. Ptr b -> Int -> IO ShaderFloatControlsIndependence
pokeElemOff :: Ptr ShaderFloatControlsIndependence
-> Int -> ShaderFloatControlsIndependence -> IO ()
$cpokeElemOff :: Ptr ShaderFloatControlsIndependence
-> Int -> ShaderFloatControlsIndependence -> IO ()
peekElemOff :: Ptr ShaderFloatControlsIndependence
-> Int -> IO ShaderFloatControlsIndependence
$cpeekElemOff :: Ptr ShaderFloatControlsIndependence
-> Int -> IO ShaderFloatControlsIndependence
alignment :: ShaderFloatControlsIndependence -> Int
$calignment :: ShaderFloatControlsIndependence -> Int
sizeOf :: ShaderFloatControlsIndependence -> Int
$csizeOf :: ShaderFloatControlsIndependence -> Int
Storable, ShaderFloatControlsIndependence
forall a. a -> Zero a
zero :: ShaderFloatControlsIndependence
$czero :: ShaderFloatControlsIndependence
Zero)

-- | 'SHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY' specifies that shader
-- float controls for 32-bit floating point /can/ be set independently;
-- other bit widths /must/ be set identically to each other.
pattern $bSHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY :: ShaderFloatControlsIndependence
$mSHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY :: forall {r}.
ShaderFloatControlsIndependence
-> ((# #) -> r) -> ((# #) -> r) -> r
SHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY = ShaderFloatControlsIndependence 0

-- | 'SHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL' specifies that shader float
-- controls for all bit widths /can/ be set independently.
pattern $bSHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL :: ShaderFloatControlsIndependence
$mSHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL :: forall {r}.
ShaderFloatControlsIndependence
-> ((# #) -> r) -> ((# #) -> r) -> r
SHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL = ShaderFloatControlsIndependence 1

-- | 'SHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE' specifies that shader float
-- controls for all bit widths /must/ be set identically.
pattern $bSHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE :: ShaderFloatControlsIndependence
$mSHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE :: forall {r}.
ShaderFloatControlsIndependence
-> ((# #) -> r) -> ((# #) -> r) -> r
SHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE = ShaderFloatControlsIndependence 2

{-# COMPLETE
  SHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY
  , SHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL
  , SHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE ::
    ShaderFloatControlsIndependence
  #-}

conNameShaderFloatControlsIndependence :: String
conNameShaderFloatControlsIndependence :: String
conNameShaderFloatControlsIndependence = String
"ShaderFloatControlsIndependence"

enumPrefixShaderFloatControlsIndependence :: String
enumPrefixShaderFloatControlsIndependence :: String
enumPrefixShaderFloatControlsIndependence = String
"SHADER_FLOAT_CONTROLS_INDEPENDENCE_"

showTableShaderFloatControlsIndependence :: [(ShaderFloatControlsIndependence, String)]
showTableShaderFloatControlsIndependence :: [(ShaderFloatControlsIndependence, String)]
showTableShaderFloatControlsIndependence =
  [
    ( ShaderFloatControlsIndependence
SHADER_FLOAT_CONTROLS_INDEPENDENCE_32_BIT_ONLY
    , String
"32_BIT_ONLY"
    )
  ,
    ( ShaderFloatControlsIndependence
SHADER_FLOAT_CONTROLS_INDEPENDENCE_ALL
    , String
"ALL"
    )
  ,
    ( ShaderFloatControlsIndependence
SHADER_FLOAT_CONTROLS_INDEPENDENCE_NONE
    , String
"NONE"
    )
  ]

instance Show ShaderFloatControlsIndependence where
  showsPrec :: Int -> ShaderFloatControlsIndependence -> ShowS
showsPrec =
    forall a i.
Eq a =>
String
-> [(a, String)]
-> String
-> (a -> i)
-> (i -> ShowS)
-> Int
-> a
-> ShowS
enumShowsPrec
      String
enumPrefixShaderFloatControlsIndependence
      [(ShaderFloatControlsIndependence, String)]
showTableShaderFloatControlsIndependence
      String
conNameShaderFloatControlsIndependence
      (\(ShaderFloatControlsIndependence Int32
x) -> Int32
x)
      (forall a. Show a => Int -> a -> ShowS
showsPrec Int
11)

instance Read ShaderFloatControlsIndependence where
  readPrec :: ReadPrec ShaderFloatControlsIndependence
readPrec =
    forall i a.
Read i =>
String -> [(a, String)] -> String -> (i -> a) -> ReadPrec a
enumReadPrec
      String
enumPrefixShaderFloatControlsIndependence
      [(ShaderFloatControlsIndependence, String)]
showTableShaderFloatControlsIndependence
      String
conNameShaderFloatControlsIndependence
      Int32 -> ShaderFloatControlsIndependence
ShaderFloatControlsIndependence