-- GENERATED by C->Haskell Compiler, version 0.16.3 Crystal Seed, 24 Jan 2009 (Haskell) -- Edit the ORIGNAL .chs file instead! {-# LINE 1 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-}{-# LANGUAGE ForeignFunctionInterface #-} {-# LANGUAGE TypeSynonymInstances #-} -- This source file is part of HGamer3D -- (A project to enable 3D game development in Haskell) -- For the latest info, see http://www.althainz.de/HGamer3D.html -- -- Copyright 2011 Dr. Peter Althainz -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. -- -- ClassRenderTarget.chs -- -- -- -- -- File for type, method, enum or function stubs -- in: "..\OgreSDK_vc10_v1-7-3\include\OGRE\OgreRenderTarget.h" -- -- each stub combines the following files: -- a C++ implementation file, transforming cpp calls into C-functions -- a C-header file, making this C-functions available for the C2HS parser -- a chs file, give instructions to the C2HS parser. -- -- module HGamer3D.Bindings.Ogre.ClassRenderTarget where import C2HS import Foreign import Foreign.Ptr import Foreign.C import Monad (liftM, liftM2) import HGamer3D.Data.HG3DClass import HGamer3D.Data.Vector2 import HGamer3D.Data.Vector3 import HGamer3D.Data.Vector4 import HGamer3D.Data.Quaternion import HGamer3D.Data.ColourValue import HGamer3D.Data.Radian import HGamer3D.Data.Degree import HGamer3D.Data.Angle import HGamer3D.Bindings.Ogre.TypeHG3DClass {-# LINE 54 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} import HGamer3D.Bindings.Ogre.ClassPtr {-# LINE 55 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} import HGamer3D.Bindings.Ogre.Utils {-# LINE 56 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} import HGamer3D.Bindings.Ogre.EnumPixelFormat {-# LINE 57 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} cRtGetName :: HG3DClass -> IO (String) cRtGetName a1 = withHG3DClass a1 $ \a1' -> alloc64k $ \a2' -> cRtGetName'_ a1' a2' >>= \res -> peekCString a2'>>= \a2'' -> return (a2'') {-# LINE 63 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtUpdate :: HG3DClass -> Bool -> IO () cRtUpdate a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromBool a2} in cRtUpdate'_ a1' a2' >>= \res -> return () {-# LINE 67 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtSwapBuffers :: HG3DClass -> Bool -> IO () cRtSwapBuffers a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromBool a2} in cRtSwapBuffers'_ a1' a2' >>= \res -> return () {-# LINE 71 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtAddViewport :: HG3DClass -> HG3DClass -> Int -> Float -> Float -> Float -> Float -> IO (HG3DClass) cRtAddViewport a1 a2 a3 a4 a5 a6 a7 = withHG3DClass a1 $ \a1' -> withHG3DClass a2 $ \a2' -> let {a3' = fromIntegral a3} in let {a4' = realToFrac a4} in let {a5' = realToFrac a5} in let {a6' = realToFrac a6} in let {a7' = realToFrac a7} in alloca $ \a8' -> cRtAddViewport'_ a1' a2' a3' a4' a5' a6' a7' a8' >>= \res -> peek a8'>>= \a8'' -> return (a8'') {-# LINE 81 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetNumViewports :: HG3DClass -> IO (Int) cRtGetNumViewports a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetNumViewports'_ a1' a2' >>= \res -> peekIntConv a2'>>= \a2'' -> return (a2'') {-# LINE 85 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetViewport :: HG3DClass -> Int -> IO (HG3DClass) cRtGetViewport a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromIntegral a2} in alloca $ \a3' -> cRtGetViewport'_ a1' a2' a3' >>= \res -> peek a3'>>= \a3'' -> return (a3'') {-# LINE 90 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtRemoveViewport :: HG3DClass -> Int -> IO () cRtRemoveViewport a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromIntegral a2} in cRtRemoveViewport'_ a1' a2' >>= \res -> return () {-# LINE 94 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtRemoveAllViewports :: HG3DClass -> IO () cRtRemoveAllViewports a1 = withHG3DClass a1 $ \a1' -> cRtRemoveAllViewports'_ a1' >>= \res -> return () {-# LINE 97 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetLastFPS :: HG3DClass -> IO (Float) cRtGetLastFPS a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetLastFPS'_ a1' a2' >>= \res -> peekFloatConv a2'>>= \a2'' -> return (a2'') {-# LINE 101 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetAverageFPS :: HG3DClass -> IO (Float) cRtGetAverageFPS a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetAverageFPS'_ a1' a2' >>= \res -> peekFloatConv a2'>>= \a2'' -> return (a2'') {-# LINE 105 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetBestFPS :: HG3DClass -> IO (Float) cRtGetBestFPS a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetBestFPS'_ a1' a2' >>= \res -> peekFloatConv a2'>>= \a2'' -> return (a2'') {-# LINE 109 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetWorstFPS :: HG3DClass -> IO (Float) cRtGetWorstFPS a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetWorstFPS'_ a1' a2' >>= \res -> peekFloatConv a2'>>= \a2'' -> return (a2'') {-# LINE 113 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetBestFrameTime :: HG3DClass -> IO (Float) cRtGetBestFrameTime a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetBestFrameTime'_ a1' a2' >>= \res -> peekFloatConv a2'>>= \a2'' -> return (a2'') {-# LINE 117 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetWorstFrameTime :: HG3DClass -> IO (Float) cRtGetWorstFrameTime a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetWorstFrameTime'_ a1' a2' >>= \res -> peekFloatConv a2'>>= \a2'' -> return (a2'') {-# LINE 121 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtResetStatistics :: HG3DClass -> IO () cRtResetStatistics a1 = withHG3DClass a1 $ \a1' -> cRtResetStatistics'_ a1' >>= \res -> return () {-# LINE 124 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtRemoveAllListeners :: HG3DClass -> IO () cRtRemoveAllListeners a1 = withHG3DClass a1 $ \a1' -> cRtRemoveAllListeners'_ a1' >>= \res -> return () {-# LINE 127 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtIsActive :: HG3DClass -> IO (Bool) cRtIsActive a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtIsActive'_ a1' a2' >>= \res -> peekBoolUtil a2'>>= \a2'' -> return (a2'') {-# LINE 131 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtSetActive :: HG3DClass -> Bool -> IO () cRtSetActive a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromBool a2} in cRtSetActive'_ a1' a2' >>= \res -> return () {-# LINE 135 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtSetAutoUpdated :: HG3DClass -> Bool -> IO () cRtSetAutoUpdated a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromBool a2} in cRtSetAutoUpdated'_ a1' a2' >>= \res -> return () {-# LINE 139 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtIsAutoUpdated :: HG3DClass -> IO (Bool) cRtIsAutoUpdated a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtIsAutoUpdated'_ a1' a2' >>= \res -> peekBoolUtil a2'>>= \a2'' -> return (a2'') {-# LINE 143 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtSuggestPixelFormat :: HG3DClass -> IO (EnumPixelFormat) cRtSuggestPixelFormat a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtSuggestPixelFormat'_ a1' a2' >>= \res -> peekEnumUtil a2'>>= \a2'' -> return (a2'') {-# LINE 147 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtWriteContentsToFile :: HG3DClass -> String -> IO () cRtWriteContentsToFile a1 a2 = withHG3DClass a1 $ \a1' -> withCString a2 $ \a2' -> cRtWriteContentsToFile'_ a1' a2' >>= \res -> return () {-# LINE 151 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtWriteContentsToTimestampedFile :: HG3DClass -> String -> String -> IO (String) cRtWriteContentsToTimestampedFile a1 a2 a3 = withHG3DClass a1 $ \a1' -> withCString a2 $ \a2' -> withCString a3 $ \a3' -> alloc64k $ \a4' -> cRtWriteContentsToTimestampedFile'_ a1' a2' a3' a4' >>= \res -> peekCString a4'>>= \a4'' -> return (a4'') {-# LINE 157 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetTriangleCount :: HG3DClass -> IO (Int) cRtGetTriangleCount a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetTriangleCount'_ a1' a2' >>= \res -> peekIntConv a2'>>= \a2'' -> return (a2'') {-# LINE 161 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetBatchCount :: HG3DClass -> IO (Int) cRtGetBatchCount a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtGetBatchCount'_ a1' a2' >>= \res -> peekIntConv a2'>>= \a2'' -> return (a2'') {-# LINE 165 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtIsPrimary :: HG3DClass -> IO (Bool) cRtIsPrimary a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtIsPrimary'_ a1' a2' >>= \res -> peekBoolUtil a2'>>= \a2'' -> return (a2'') {-# LINE 169 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtIsHardwareGammaEnabled :: HG3DClass -> IO (Bool) cRtIsHardwareGammaEnabled a1 = withHG3DClass a1 $ \a1' -> alloca $ \a2' -> cRtIsHardwareGammaEnabled'_ a1' a2' >>= \res -> peekBoolUtil a2'>>= \a2'' -> return (a2'') {-# LINE 173 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtGetFSAAHint :: HG3DClass -> IO (String) cRtGetFSAAHint a1 = withHG3DClass a1 $ \a1' -> alloc64k $ \a2' -> cRtGetFSAAHint'_ a1' a2' >>= \res -> peekCString a2'>>= \a2'' -> return (a2'') {-# LINE 177 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtBeginUpdate :: HG3DClass -> IO () cRtBeginUpdate a1 = withHG3DClass a1 $ \a1' -> cRtBeginUpdate'_ a1' >>= \res -> return () {-# LINE 180 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtUpdateViewport :: HG3DClass -> Int -> Bool -> IO () cRtUpdateViewport a1 a2 a3 = withHG3DClass a1 $ \a1' -> let {a2' = fromIntegral a2} in let {a3' = fromBool a3} in cRtUpdateViewport'_ a1' a2' a3' >>= \res -> return () {-# LINE 185 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtUpdateViewport2 :: HG3DClass -> HG3DClass -> Bool -> IO () cRtUpdateViewport2 a1 a2 a3 = withHG3DClass a1 $ \a1' -> withHG3DClass a2 $ \a2' -> let {a3' = fromBool a3} in cRtUpdateViewport2'_ a1' a2' a3' >>= \res -> return () {-# LINE 190 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; cRtUpdateAutoUpdatedViewports :: HG3DClass -> Bool -> IO () cRtUpdateAutoUpdatedViewports a1 a2 = withHG3DClass a1 $ \a1' -> let {a2' = fromBool a2} in cRtUpdateAutoUpdatedViewports'_ a1' a2' >>= \res -> return () {-# LINE 194 "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs" #-} ; foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getName_c" cRtGetName'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_update_c" cRtUpdate'_ :: ((HG3DClassPtr) -> (CInt -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_swapBuffers_c" cRtSwapBuffers'_ :: ((HG3DClassPtr) -> (CInt -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_addViewport_c" cRtAddViewport'_ :: ((HG3DClassPtr) -> ((HG3DClassPtr) -> (CInt -> (CFloat -> (CFloat -> (CFloat -> (CFloat -> ((HG3DClassPtr) -> (IO ()))))))))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getNumViewports_c" cRtGetNumViewports'_ :: ((HG3DClassPtr) -> ((Ptr CUInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getViewport_c" cRtGetViewport'_ :: ((HG3DClassPtr) -> (CUInt -> ((HG3DClassPtr) -> (IO ())))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_removeViewport_c" cRtRemoveViewport'_ :: ((HG3DClassPtr) -> (CInt -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_removeAllViewports_c" cRtRemoveAllViewports'_ :: ((HG3DClassPtr) -> (IO ())) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getLastFPS_c" cRtGetLastFPS'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getAverageFPS_c" cRtGetAverageFPS'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getBestFPS_c" cRtGetBestFPS'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getWorstFPS_c" cRtGetWorstFPS'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getBestFrameTime_c" cRtGetBestFrameTime'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getWorstFrameTime_c" cRtGetWorstFrameTime'_ :: ((HG3DClassPtr) -> ((Ptr CFloat) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_resetStatistics_c" cRtResetStatistics'_ :: ((HG3DClassPtr) -> (IO ())) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_removeAllListeners_c" cRtRemoveAllListeners'_ :: ((HG3DClassPtr) -> (IO ())) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_isActive_c" cRtIsActive'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_setActive_c" cRtSetActive'_ :: ((HG3DClassPtr) -> (CInt -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_setAutoUpdated_c" cRtSetAutoUpdated'_ :: ((HG3DClassPtr) -> (CInt -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_isAutoUpdated_c" cRtIsAutoUpdated'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_suggestPixelFormat_c" cRtSuggestPixelFormat'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_writeContentsToFile_c" cRtWriteContentsToFile'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_writeContentsToTimestampedFile_c" cRtWriteContentsToTimestampedFile'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> ((Ptr CChar) -> ((Ptr CChar) -> (IO ()))))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getTriangleCount_c" cRtGetTriangleCount'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getBatchCount_c" cRtGetBatchCount'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_isPrimary_c" cRtIsPrimary'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_isHardwareGammaEnabled_c" cRtIsHardwareGammaEnabled'_ :: ((HG3DClassPtr) -> ((Ptr CInt) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt_getFSAAHint_c" cRtGetFSAAHint'_ :: ((HG3DClassPtr) -> ((Ptr CChar) -> (IO ()))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt__beginUpdate_c" cRtBeginUpdate'_ :: ((HG3DClassPtr) -> (IO ())) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt__updateViewport_c" cRtUpdateViewport'_ :: ((HG3DClassPtr) -> (CInt -> (CInt -> (IO ())))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt__updateViewport2_c" cRtUpdateViewport2'_ :: ((HG3DClassPtr) -> ((HG3DClassPtr) -> (CInt -> (IO ())))) foreign import ccall safe "HGamer3D\\Bindings\\Ogre\\ClassRenderTarget.chs.h cRt__updateAutoUpdatedViewports_c" cRtUpdateAutoUpdatedViewports'_ :: ((HG3DClassPtr) -> (CInt -> (IO ())))