-- This file was automatically generated.
{-# LANGUAGE CPP, ScopedTypeVariables, PatternSynonyms #-}
module Graphics.GL.Ext.APPLE.FlushBufferRange (
  -- * Extension Support
    gl_APPLE_flush_buffer_range

  -- * GL_APPLE_flush_buffer_range
  , glBufferParameteriAPPLE
  , glFlushMappedBufferRangeAPPLE
  , pattern GL_BUFFER_FLUSHING_UNMAP_APPLE
  , pattern GL_BUFFER_SERIALIZED_MODIFY_APPLE
) where

import Control.Monad.IO.Class
import Data.Set
import Foreign.Ptr
import Graphics.GL.Internal.FFI
import Graphics.GL.Internal.Proc
import Graphics.GL.Types
import System.IO.Unsafe

-- | Checks that the <https://cvs.khronos.org/svn/repos/ogl/trunk/doc/registry/public/specs/APPLE/flush_buffer_range.txt GL_APPLE_flush_buffer_range> extension is available.

gl_APPLE_flush_buffer_range :: Bool
gl_APPLE_flush_buffer_range :: Bool
gl_APPLE_flush_buffer_range = [Char] -> Set [Char] -> Bool
forall a. Ord a => a -> Set a -> Bool
member "GL_APPLE_flush_buffer_range" Set [Char]
extensions
{-# NOINLINE gl_APPLE_flush_buffer_range #-}

-- | Usage: @'glBufferParameteriAPPLE' target pname param@


glBufferParameteriAPPLE :: MonadIO m => GLenum -> GLenum -> GLint -> m ()
glBufferParameteriAPPLE :: GLenum -> GLenum -> GLint -> m ()
glBufferParameteriAPPLE = FunPtr (GLenum -> GLenum -> GLint -> IO ())
-> GLenum -> GLenum -> GLint -> m ()
forall (m :: * -> *).
MonadIO m =>
FunPtr (GLenum -> GLenum -> GLint -> IO ())
-> GLenum -> GLenum -> GLint -> m ()
ffienumenumintIOV FunPtr (GLenum -> GLenum -> GLint -> IO ())
glBufferParameteriAPPLEFunPtr

glBufferParameteriAPPLEFunPtr :: FunPtr (GLenum -> GLenum -> GLint -> IO ())
glBufferParameteriAPPLEFunPtr :: FunPtr (GLenum -> GLenum -> GLint -> IO ())
glBufferParameteriAPPLEFunPtr = IO (FunPtr (GLenum -> GLenum -> GLint -> IO ()))
-> FunPtr (GLenum -> GLenum -> GLint -> IO ())
forall a. IO a -> a
unsafePerformIO ([Char] -> IO (FunPtr (GLenum -> GLenum -> GLint -> IO ()))
forall a. [Char] -> IO (FunPtr a)
getProcAddress "glBufferParameteriAPPLE")

{-# NOINLINE glBufferParameteriAPPLEFunPtr #-}

-- | Usage: @'glFlushMappedBufferRangeAPPLE' target offset size@
--
-- The parameter @offset@ is a @BufferOffset@.
--
-- The parameter @size@ is a @BufferSize@.
--
-- This command is an alias for 'Graphics.GL.Internal.Shared.glFlushMappedBufferRange'.


glFlushMappedBufferRangeAPPLE :: MonadIO m => GLenum -> GLintptr -> GLsizeiptr -> m ()
glFlushMappedBufferRangeAPPLE :: GLenum -> GLintptr -> GLintptr -> m ()
glFlushMappedBufferRangeAPPLE = FunPtr (GLenum -> GLintptr -> GLintptr -> IO ())
-> GLenum -> GLintptr -> GLintptr -> m ()
forall (m :: * -> *).
MonadIO m =>
FunPtr (GLenum -> GLintptr -> GLintptr -> IO ())
-> GLenum -> GLintptr -> GLintptr -> m ()
ffienumintptrsizeiptrIOV FunPtr (GLenum -> GLintptr -> GLintptr -> IO ())
glFlushMappedBufferRangeAPPLEFunPtr

glFlushMappedBufferRangeAPPLEFunPtr :: FunPtr (GLenum -> GLintptr -> GLsizeiptr -> IO ())
glFlushMappedBufferRangeAPPLEFunPtr :: FunPtr (GLenum -> GLintptr -> GLintptr -> IO ())
glFlushMappedBufferRangeAPPLEFunPtr = IO (FunPtr (GLenum -> GLintptr -> GLintptr -> IO ()))
-> FunPtr (GLenum -> GLintptr -> GLintptr -> IO ())
forall a. IO a -> a
unsafePerformIO ([Char] -> IO (FunPtr (GLenum -> GLintptr -> GLintptr -> IO ()))
forall a. [Char] -> IO (FunPtr a)
getProcAddress "glFlushMappedBufferRangeAPPLE")

{-# NOINLINE glFlushMappedBufferRangeAPPLEFunPtr #-}

pattern $bGL_BUFFER_FLUSHING_UNMAP_APPLE :: a
$mGL_BUFFER_FLUSHING_UNMAP_APPLE :: forall r a. (Eq a, Num a) => a -> (Void# -> r) -> (Void# -> r) -> r
GL_BUFFER_FLUSHING_UNMAP_APPLE = 0x8A13

pattern $bGL_BUFFER_SERIALIZED_MODIFY_APPLE :: a
$mGL_BUFFER_SERIALIZED_MODIFY_APPLE :: forall r a. (Eq a, Num a) => a -> (Void# -> r) -> (Void# -> r) -> r
GL_BUFFER_SERIALIZED_MODIFY_APPLE = 0x8A12