Box3D
Safe HaskellNone
LanguageGHC2021

Box3D.Recording

Synopsis

Documentation

create Source #

Arguments

:: Int
byteCapacity
-> IO (Ptr Recording) 

Create a recording buffer with an optional initial byte capacity. Pass 0 to use the default (64 KiB). The buffer grows on demand.

Returns: a new recording, owned by the caller

Binds b3CreateRecording.

destroy Source #

Arguments

:: Ptr Recording

recording: may be NULL

-> IO () 

Destroy a recording and free its buffer.

Binds b3DestroyRecording.

getData Source #

Arguments

:: Ptr Recording

recording: the recording handle

-> IO (Ptr Word8) 

Get a pointer to the raw recording bytes. Valid until the recording buffer is modified or destroyed.

Returns: pointer to the byte buffer, or NULL if no bytes have been written

Binds b3Recording_GetData.

getSize Source #

Arguments

:: Ptr Recording

recording: the recording handle

-> IO Int 

Get the number of bytes currently in the recording buffer.

Binds b3Recording_GetSize.