{-# language CPP #-}
module OpenXR.Extensions.XR_EXT_thermal_query ( thermalGetTemperatureTrendEXT
, EXT_thermal_query_SPEC_VERSION
, pattern EXT_thermal_query_SPEC_VERSION
, EXT_THERMAL_QUERY_EXTENSION_NAME
, pattern EXT_THERMAL_QUERY_EXTENSION_NAME
, PerfSettingsDomainEXT(..)
, PerfSettingsNotificationLevelEXT(..)
) where
import OpenXR.Internal.Utils (traceAroundEvent)
import Control.Exception.Base (bracket)
import Control.Monad (unless)
import Control.Monad.IO.Class (liftIO)
import Foreign.Marshal.Alloc (callocBytes)
import Foreign.Marshal.Alloc (free)
import GHC.Base (when)
import GHC.IO (throwIO)
import GHC.Ptr (nullFunPtr)
import Data.Coerce (coerce)
import Control.Monad.Trans.Class (lift)
import Control.Monad.Trans.Cont (evalContT)
import Foreign.C.Types (CFloat(..))
import Control.Monad.IO.Class (MonadIO)
import Data.String (IsString)
import Foreign.C.Types (CFloat)
import Foreign.C.Types (CFloat(..))
import Foreign.Storable (Storable(peek))
import GHC.IO.Exception (IOErrorType(..))
import GHC.IO.Exception (IOException(..))
import Foreign.Ptr (FunPtr)
import Foreign.Ptr (Ptr)
import Control.Monad.Trans.Cont (ContT(..))
import OpenXR.NamedType ((:::))
import OpenXR.Dynamic (InstanceCmds(pXrThermalGetTemperatureTrendEXT))
import OpenXR.Exception (OpenXrException(..))
import OpenXR.Extensions.XR_EXT_performance_settings (PerfSettingsDomainEXT)
import OpenXR.Extensions.XR_EXT_performance_settings (PerfSettingsDomainEXT(..))
import OpenXR.Extensions.XR_EXT_performance_settings (PerfSettingsNotificationLevelEXT)
import OpenXR.Extensions.XR_EXT_performance_settings (PerfSettingsNotificationLevelEXT(..))
import OpenXR.Core10.Enums.Result (Result)
import OpenXR.Core10.Enums.Result (Result(..))
import OpenXR.Core10.Handles (Session)
import OpenXR.Core10.Handles (Session(..))
import OpenXR.Core10.Handles (Session_T)
import OpenXR.Core10.Enums.Result (Result(SUCCESS))
import OpenXR.Extensions.XR_EXT_performance_settings (PerfSettingsDomainEXT(..))
import OpenXR.Extensions.XR_EXT_performance_settings (PerfSettingsNotificationLevelEXT(..))
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkXrThermalGetTemperatureTrendEXT
:: FunPtr (Ptr Session_T -> PerfSettingsDomainEXT -> Ptr PerfSettingsNotificationLevelEXT -> Ptr CFloat -> Ptr CFloat -> IO Result) -> Ptr Session_T -> PerfSettingsDomainEXT -> Ptr PerfSettingsNotificationLevelEXT -> Ptr CFloat -> Ptr CFloat -> IO Result
thermalGetTemperatureTrendEXT :: forall io
. (MonadIO io)
=>
Session
->
PerfSettingsDomainEXT
-> io (Result, PerfSettingsNotificationLevelEXT, ("tempHeadroom" ::: Float), ("tempSlope" ::: Float))
thermalGetTemperatureTrendEXT :: Session
-> PerfSettingsDomainEXT
-> io
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
thermalGetTemperatureTrendEXT session :: Session
session domain :: PerfSettingsDomainEXT
domain = IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> io
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> io
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> (ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> io
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> io
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> io
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall a b. (a -> b) -> a -> b
$ do
let xrThermalGetTemperatureTrendEXTPtr :: FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
xrThermalGetTemperatureTrendEXTPtr = InstanceCmds
-> FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
pXrThermalGetTemperatureTrendEXT (Session -> InstanceCmds
instanceCmds (Session
session :: Session))
IO ()
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO ()
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
())
-> IO ()
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
()
forall a b. (a -> b) -> a -> b
$ Bool -> IO () -> IO ()
forall (f :: * -> *). Applicative f => Bool -> f () -> f ()
unless (FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
xrThermalGetTemperatureTrendEXTPtr FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
-> FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
-> Bool
forall a. Eq a => a -> a -> Bool
/= FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for xrThermalGetTemperatureTrendEXT is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let xrThermalGetTemperatureTrendEXT' :: Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result
xrThermalGetTemperatureTrendEXT' = FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
-> Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result
mkXrThermalGetTemperatureTrendEXT FunPtr
(Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result)
xrThermalGetTemperatureTrendEXTPtr
Ptr PerfSettingsNotificationLevelEXT
pNotificationLevel <- ((Ptr PerfSettingsNotificationLevelEXT
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Ptr PerfSettingsNotificationLevelEXT)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr PerfSettingsNotificationLevelEXT
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Ptr PerfSettingsNotificationLevelEXT))
-> ((Ptr PerfSettingsNotificationLevelEXT
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Ptr PerfSettingsNotificationLevelEXT)
forall a b. (a -> b) -> a -> b
$ IO (Ptr PerfSettingsNotificationLevelEXT)
-> (Ptr PerfSettingsNotificationLevelEXT -> IO ())
-> (Ptr PerfSettingsNotificationLevelEXT
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall a b c. IO a -> (a -> IO b) -> (a -> IO c) -> IO c
bracket (Int -> IO (Ptr PerfSettingsNotificationLevelEXT)
forall a. Int -> IO (Ptr a)
callocBytes @PerfSettingsNotificationLevelEXT 4) Ptr PerfSettingsNotificationLevelEXT -> IO ()
forall a. Ptr a -> IO ()
free
"tempHeadroom" ::: Ptr CFloat
pTempHeadroom <- ((("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
("tempHeadroom" ::: Ptr CFloat)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
("tempHeadroom" ::: Ptr CFloat))
-> ((("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
("tempHeadroom" ::: Ptr CFloat)
forall a b. (a -> b) -> a -> b
$ IO ("tempHeadroom" ::: Ptr CFloat)
-> (("tempHeadroom" ::: Ptr CFloat) -> IO ())
-> (("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall a b c. IO a -> (a -> IO b) -> (a -> IO c) -> IO c
bracket (Int -> IO ("tempHeadroom" ::: Ptr CFloat)
forall a. Int -> IO (Ptr a)
callocBytes @CFloat 4) ("tempHeadroom" ::: Ptr CFloat) -> IO ()
forall a. Ptr a -> IO ()
free
"tempHeadroom" ::: Ptr CFloat
pTempSlope <- ((("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
("tempHeadroom" ::: Ptr CFloat)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
("tempHeadroom" ::: Ptr CFloat))
-> ((("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
("tempHeadroom" ::: Ptr CFloat)
forall a b. (a -> b) -> a -> b
$ IO ("tempHeadroom" ::: Ptr CFloat)
-> (("tempHeadroom" ::: Ptr CFloat) -> IO ())
-> (("tempHeadroom" ::: Ptr CFloat)
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall a b c. IO a -> (a -> IO b) -> (a -> IO c) -> IO c
bracket (Int -> IO ("tempHeadroom" ::: Ptr CFloat)
forall a. Int -> IO (Ptr a)
callocBytes @CFloat 4) ("tempHeadroom" ::: Ptr CFloat) -> IO ()
forall a. Ptr a -> IO ()
free
Result
r <- IO Result
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
Result
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO Result
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
Result)
-> IO Result
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
Result
forall a b. (a -> b) -> a -> b
$ String -> IO Result -> IO Result
forall a. String -> IO a -> IO a
traceAroundEvent "xrThermalGetTemperatureTrendEXT" (Ptr Session_T
-> PerfSettingsDomainEXT
-> Ptr PerfSettingsNotificationLevelEXT
-> ("tempHeadroom" ::: Ptr CFloat)
-> ("tempHeadroom" ::: Ptr CFloat)
-> IO Result
xrThermalGetTemperatureTrendEXT' (Session -> Ptr Session_T
sessionHandle (Session
session)) (PerfSettingsDomainEXT
domain) (Ptr PerfSettingsNotificationLevelEXT
pNotificationLevel) ("tempHeadroom" ::: Ptr CFloat
pTempHeadroom) ("tempHeadroom" ::: Ptr CFloat
pTempSlope))
IO ()
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO ()
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
())
-> IO ()
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
()
forall a b. (a -> b) -> a -> b
$ Bool -> IO () -> IO ()
forall (f :: * -> *). Applicative f => Bool -> f () -> f ()
when (Result
r Result -> Result -> Bool
forall a. Ord a => a -> a -> Bool
< Result
SUCCESS) (OpenXrException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (Result -> OpenXrException
OpenXrException Result
r))
PerfSettingsNotificationLevelEXT
notificationLevel <- IO PerfSettingsNotificationLevelEXT
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
PerfSettingsNotificationLevelEXT
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO PerfSettingsNotificationLevelEXT
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
PerfSettingsNotificationLevelEXT)
-> IO PerfSettingsNotificationLevelEXT
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
PerfSettingsNotificationLevelEXT
forall a b. (a -> b) -> a -> b
$ Ptr PerfSettingsNotificationLevelEXT
-> IO PerfSettingsNotificationLevelEXT
forall a. Storable a => Ptr a -> IO a
peek @PerfSettingsNotificationLevelEXT Ptr PerfSettingsNotificationLevelEXT
pNotificationLevel
CFloat
tempHeadroom <- IO CFloat
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
CFloat
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO CFloat
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
CFloat)
-> IO CFloat
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
CFloat
forall a b. (a -> b) -> a -> b
$ ("tempHeadroom" ::: Ptr CFloat) -> IO CFloat
forall a. Storable a => Ptr a -> IO a
peek @CFloat "tempHeadroom" ::: Ptr CFloat
pTempHeadroom
CFloat
tempSlope <- IO CFloat
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
CFloat
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO CFloat
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
CFloat)
-> IO CFloat
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
CFloat
forall a b. (a -> b) -> a -> b
$ ("tempHeadroom" ::: Ptr CFloat) -> IO CFloat
forall a. Storable a => Ptr a -> IO a
peek @CFloat "tempHeadroom" ::: Ptr CFloat
pTempSlope
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall (f :: * -> *) a. Applicative f => a -> f a
pure ((Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float))
-> (Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
-> ContT
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
IO
(Result, PerfSettingsNotificationLevelEXT,
"tempHeadroom" ::: Float, "tempHeadroom" ::: Float)
forall a b. (a -> b) -> a -> b
$ (Result
r, PerfSettingsNotificationLevelEXT
notificationLevel, (CFloat -> "tempHeadroom" ::: Float
forall a b. Coercible a b => a -> b
coerce @CFloat @Float CFloat
tempHeadroom), (CFloat -> "tempHeadroom" ::: Float
forall a b. Coercible a b => a -> b
coerce @CFloat @Float CFloat
tempSlope))
type EXT_thermal_query_SPEC_VERSION = 1
pattern EXT_thermal_query_SPEC_VERSION :: forall a . Integral a => a
pattern $bEXT_thermal_query_SPEC_VERSION :: a
$mEXT_thermal_query_SPEC_VERSION :: forall r a. Integral a => a -> (Void# -> r) -> (Void# -> r) -> r
EXT_thermal_query_SPEC_VERSION = 1
type EXT_THERMAL_QUERY_EXTENSION_NAME = "XR_EXT_thermal_query"
pattern EXT_THERMAL_QUERY_EXTENSION_NAME :: forall a . (Eq a, IsString a) => a
pattern $bEXT_THERMAL_QUERY_EXTENSION_NAME :: a
$mEXT_THERMAL_QUERY_EXTENSION_NAME :: forall r a.
(Eq a, IsString a) =>
a -> (Void# -> r) -> (Void# -> r) -> r
EXT_THERMAL_QUERY_EXTENSION_NAME = "XR_EXT_thermal_query"