{-# LINE 1 "src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc" #-}
{-# OPTIONS_GHC -Wno-unused-imports #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE NoImplicitPrelude #-}

-- This file was generated by wgpu-raw-hs-codegen on:
--   2021-08-25T10:02:03.522705
-- Using wgpu-native git hash:
--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)

module WGPU.Raw.Generated.Struct.WGPUComputePassDescriptor where



import Data.Word (Word16, Word32, Word64)
import Data.Int (Int32)
import Foreign
import Foreign.C.Types
import WGPU.Raw.Types
import Prelude (pure, ($!))
import WGPU.Raw.Generated.Struct.WGPUChainedStruct

data WGPUComputePassDescriptor = WGPUComputePassDescriptor {
  WGPUComputePassDescriptor -> Ptr WGPUChainedStruct
nextInChain :: Ptr (WGPUChainedStruct),
  WGPUComputePassDescriptor -> Ptr CChar
label :: Ptr (CChar)
}

instance Storable WGPUComputePassDescriptor where
  sizeOf :: WGPUComputePassDescriptor -> Int
sizeOf WGPUComputePassDescriptor
_ = ((Int
16))
{-# LINE 29 "src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc" #-}
  {-# INLINABLE sizeOf #-}
  alignment :: WGPUComputePassDescriptor -> Int
alignment = WGPUComputePassDescriptor -> Int
forall a. Storable a => a -> Int
sizeOf
  {-# INLINABLE alignment #-}
  peek :: Ptr WGPUComputePassDescriptor -> IO WGPUComputePassDescriptor
peek Ptr WGPUComputePassDescriptor
ptr = do
    Ptr WGPUChainedStruct
nextInChain <- ((\Ptr WGPUComputePassDescriptor
hsc_ptr -> Ptr WGPUComputePassDescriptor -> Int -> IO (Ptr WGPUChainedStruct)
forall a b. Storable a => Ptr b -> Int -> IO a
peekByteOff Ptr WGPUComputePassDescriptor
hsc_ptr Int
0)) Ptr WGPUComputePassDescriptor
ptr
{-# LINE 34 "src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc" #-}
    label <- ((\hsc_ptr -> peekByteOff hsc_ptr 8)) ptr
{-# LINE 35 "src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc" #-}
    pure $! WGPUComputePassDescriptor{..}
  {-# INLINABLE peek #-}
  poke :: Ptr WGPUComputePassDescriptor -> WGPUComputePassDescriptor -> IO ()
poke Ptr WGPUComputePassDescriptor
ptr WGPUComputePassDescriptor{Ptr CChar
Ptr WGPUChainedStruct
label :: Ptr CChar
nextInChain :: Ptr WGPUChainedStruct
label :: WGPUComputePassDescriptor -> Ptr CChar
nextInChain :: WGPUComputePassDescriptor -> Ptr WGPUChainedStruct
..} = do
    ((\Ptr WGPUComputePassDescriptor
hsc_ptr -> Ptr WGPUComputePassDescriptor
-> Int -> Ptr WGPUChainedStruct -> IO ()
forall a b. Storable a => Ptr b -> Int -> a -> IO ()
pokeByteOff Ptr WGPUComputePassDescriptor
hsc_ptr Int
0)) Ptr WGPUComputePassDescriptor
ptr Ptr WGPUChainedStruct
nextInChain
{-# LINE 39 "src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc" #-}
    ((\hsc_ptr -> pokeByteOff hsc_ptr 8)) ptr label
{-# LINE 40 "src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc" #-}
  {-# INLINABLE poke #-}