gi-gst-1.0.25: GStreamer bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.Gst.Callbacks

Description

 
Synopsis

Signals

BufferForeachMetaFunc

type BufferForeachMetaFunc Source #

Arguments

 = Buffer

buffer: a Buffer

-> IO (Bool, Maybe Meta)

Returns: False when bufferForeachMeta should stop

A function that will be called from bufferForeachMeta. The meta field will point to a the reference of the meta.

buffer should not be modified from this callback.

When this function returns True, the next meta will be returned. When False is returned, bufferForeachMeta will return.

When meta is set to Nothing, the item will be removed from the buffer.

type BufferForeachMetaFunc_WithClosures Source #

Arguments

 = Buffer

buffer: a Buffer

-> Ptr ()

userData: user data passed to bufferForeachMeta

-> IO (Bool, Maybe Meta)

Returns: False when bufferForeachMeta should stop

A function that will be called from bufferForeachMeta. The meta field will point to a the reference of the meta.

buffer should not be modified from this callback.

When this function returns True, the next meta will be returned. When False is returned, bufferForeachMeta will return.

When meta is set to Nothing, the item will be removed from the buffer.

type C_BufferForeachMetaFunc = Ptr Buffer -> Ptr (Ptr Meta) -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

dynamic_BufferForeachMetaFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_BufferForeachMetaFunc 
-> Buffer

buffer: a Buffer

-> Ptr ()

userData: user data passed to bufferForeachMeta

-> m (Bool, Maybe Meta)

Returns: False when bufferForeachMeta should stop

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_BufferForeachMetaFunc :: C_BufferForeachMetaFunc -> IO (FunPtr C_BufferForeachMetaFunc) Source #

Generate a function pointer callable from C code, from a C_BufferForeachMetaFunc.

BufferListFunc

type BufferListFunc Source #

Arguments

 = Word32

idx: the index of buffer

-> IO (Bool, Maybe Buffer)

Returns: False when bufferListForeach should stop

A function that will be called from bufferListForeach. The buffer field will point to a the reference of the buffer at idx.

When this function returns True, the next buffer will be returned. When False is returned, bufferListForeach will return.

When buffer is set to Nothing, the item will be removed from the bufferlist. When buffer has been made writable, the new buffer reference can be assigned to buffer. This function is responsible for unreffing the old buffer when removing or modifying.

type BufferListFunc_WithClosures Source #

Arguments

 = Word32

idx: the index of buffer

-> Ptr ()

userData: user data passed to bufferListForeach

-> IO (Bool, Maybe Buffer)

Returns: False when bufferListForeach should stop

A function that will be called from bufferListForeach. The buffer field will point to a the reference of the buffer at idx.

When this function returns True, the next buffer will be returned. When False is returned, bufferListForeach will return.

When buffer is set to Nothing, the item will be removed from the bufferlist. When buffer has been made writable, the new buffer reference can be assigned to buffer. This function is responsible for unreffing the old buffer when removing or modifying.

type C_BufferListFunc = Ptr (Ptr Buffer) -> Word32 -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

drop_closures_BufferListFunc :: BufferListFunc -> BufferListFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_BufferListFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_BufferListFunc 
-> Word32

idx: the index of buffer

-> Ptr ()

userData: user data passed to bufferListForeach

-> m (Bool, Maybe Buffer)

Returns: False when bufferListForeach should stop

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_BufferListFunc :: C_BufferListFunc -> IO (FunPtr C_BufferListFunc) Source #

Generate a function pointer callable from C code, from a C_BufferListFunc.

BusFunc

type BusFunc Source #

Arguments

 = Bus

bus: the Bus that sent the message

-> Message

message: the Message

-> IO Bool

Returns: False if the event source should be removed.

Specifies the type of function passed to gst_bus_add_watch() or busAddWatch, which is called from the mainloop when a message is available on the bus.

The message passed to the function will be unreffed after execution of this function so it should not be freed in the function.

Note that this function is used as a SourceFunc which means that returning False will remove the Source from the mainloop.

type BusFunc_WithClosures Source #

Arguments

 = Bus

bus: the Bus that sent the message

-> Message

message: the Message

-> Ptr ()

userData: user data that has been given, when registering the handler

-> IO Bool

Returns: False if the event source should be removed.

Specifies the type of function passed to gst_bus_add_watch() or busAddWatch, which is called from the mainloop when a message is available on the bus.

The message passed to the function will be unreffed after execution of this function so it should not be freed in the function.

Note that this function is used as a SourceFunc which means that returning False will remove the Source from the mainloop.

type C_BusFunc = Ptr Bus -> Ptr Message -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

drop_closures_BusFunc :: BusFunc -> BusFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_BusFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsBus a) 
=> FunPtr C_BusFunc 
-> a

bus: the Bus that sent the message

-> Message

message: the Message

-> Ptr ()

userData: user data that has been given, when registering the handler

-> m Bool

Returns: False if the event source should be removed.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

genClosure_BusFunc :: MonadIO m => BusFunc -> m (GClosure C_BusFunc) Source #

Wrap the callback into a GClosure.

mk_BusFunc :: C_BusFunc -> IO (FunPtr C_BusFunc) Source #

Generate a function pointer callable from C code, from a C_BusFunc.

noBusFunc :: Maybe BusFunc Source #

A convenience synonym for Nothing :: Maybe BusFunc.

BusSyncHandler

type BusSyncHandler Source #

Arguments

 = Bus

bus: the Bus that sent the message

-> Message

message: the Message

-> IO BusSyncReply

Returns: BusSyncReply stating what to do with the message

Handler will be invoked synchronously, when a new message has been injected into the bus. This function is mostly used internally. Only one sync handler can be attached to a given bus.

If the handler returns BusSyncReplyDrop, it should unref the message, else the message should not be unreffed by the sync handler.

type BusSyncHandler_WithClosures Source #

Arguments

 = Bus

bus: the Bus that sent the message

-> Message

message: the Message

-> Ptr ()

userData: user data that has been given, when registering the handler

-> IO BusSyncReply

Returns: BusSyncReply stating what to do with the message

Handler will be invoked synchronously, when a new message has been injected into the bus. This function is mostly used internally. Only one sync handler can be attached to a given bus.

If the handler returns BusSyncReplyDrop, it should unref the message, else the message should not be unreffed by the sync handler.

type C_BusSyncHandler = Ptr Bus -> Ptr Message -> Ptr () -> IO CUInt Source #

Type for the callback on the (unwrapped) C side.

drop_closures_BusSyncHandler :: BusSyncHandler -> BusSyncHandler_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_BusSyncHandler Source #

Arguments

:: (HasCallStack, MonadIO m, IsBus a) 
=> FunPtr C_BusSyncHandler 
-> a

bus: the Bus that sent the message

-> Message

message: the Message

-> Ptr ()

userData: user data that has been given, when registering the handler

-> m BusSyncReply

Returns: BusSyncReply stating what to do with the message

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_BusSyncHandler :: C_BusSyncHandler -> IO (FunPtr C_BusSyncHandler) Source #

Generate a function pointer callable from C code, from a C_BusSyncHandler.

CapsFilterMapFunc

type C_CapsFilterMapFunc = Ptr CapsFeatures -> Ptr Structure -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type CapsFilterMapFunc Source #

Arguments

 = CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> IO Bool

Returns: True if the features and structure should be preserved, False if it should be removed.

A function that will be called in capsFilterAndMapInPlace. The function may modify features and structure, and both will be removed from the caps if False is returned.

type CapsFilterMapFunc_WithClosures Source #

Arguments

 = CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> Ptr ()

userData: user data

-> IO Bool

Returns: True if the features and structure should be preserved, False if it should be removed.

A function that will be called in capsFilterAndMapInPlace. The function may modify features and structure, and both will be removed from the caps if False is returned.

drop_closures_CapsFilterMapFunc :: CapsFilterMapFunc -> CapsFilterMapFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_CapsFilterMapFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_CapsFilterMapFunc 
-> CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> Ptr ()

userData: user data

-> m Bool

Returns: True if the features and structure should be preserved, False if it should be removed.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_CapsFilterMapFunc :: C_CapsFilterMapFunc -> IO (FunPtr C_CapsFilterMapFunc) Source #

Generate a function pointer callable from C code, from a C_CapsFilterMapFunc.

CapsForeachFunc

type C_CapsForeachFunc = Ptr CapsFeatures -> Ptr Structure -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type CapsForeachFunc Source #

Arguments

 = CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> IO Bool

Returns: True if the foreach operation should continue, False if the foreach operation should stop with False.

A function that will be called in capsForeach. The function may not modify features or structure.

Since: 1.6

type CapsForeachFunc_WithClosures Source #

Arguments

 = CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> Ptr ()

userData: user data

-> IO Bool

Returns: True if the foreach operation should continue, False if the foreach operation should stop with False.

A function that will be called in capsForeach. The function may not modify features or structure.

Since: 1.6

drop_closures_CapsForeachFunc :: CapsForeachFunc -> CapsForeachFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_CapsForeachFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_CapsForeachFunc 
-> CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> Ptr ()

userData: user data

-> m Bool

Returns: True if the foreach operation should continue, False if the foreach operation should stop with False.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_CapsForeachFunc :: C_CapsForeachFunc -> IO (FunPtr C_CapsForeachFunc) Source #

Generate a function pointer callable from C code, from a C_CapsForeachFunc.

CapsMapFunc

type C_CapsMapFunc = Ptr CapsFeatures -> Ptr Structure -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type CapsMapFunc Source #

Arguments

 = CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> IO Bool

Returns: True if the map operation should continue, False if the map operation should stop with False.

A function that will be called in capsMapInPlace. The function may modify features and structure.

type CapsMapFunc_WithClosures Source #

Arguments

 = CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> Ptr ()

userData: user data

-> IO Bool

Returns: True if the map operation should continue, False if the map operation should stop with False.

A function that will be called in capsMapInPlace. The function may modify features and structure.

drop_closures_CapsMapFunc :: CapsMapFunc -> CapsMapFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_CapsMapFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_CapsMapFunc 
-> CapsFeatures

features: the CapsFeatures

-> Structure

structure: the Structure

-> Ptr ()

userData: user data

-> m Bool

Returns: True if the map operation should continue, False if the map operation should stop with False.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_CapsMapFunc :: C_CapsMapFunc -> IO (FunPtr C_CapsMapFunc) Source #

Generate a function pointer callable from C code, from a C_CapsMapFunc.

ClockCallback

type C_ClockCallback = Ptr Clock -> Word64 -> Ptr () -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type ClockCallback Source #

Arguments

 = Clock

clock: The clock that triggered the callback

-> Word64

time: The time it was triggered

-> Ptr ()

id: The GstClockID that expired

-> IO Bool

Returns: True or False (currently unused)

The function prototype of the callback.

type ClockCallback_WithClosures Source #

Arguments

 = Clock

clock: The clock that triggered the callback

-> Word64

time: The time it was triggered

-> Ptr ()

id: The GstClockID that expired

-> Ptr ()

userData: user data passed in the clockIdWaitAsync function

-> IO Bool

Returns: True or False (currently unused)

The function prototype of the callback.

drop_closures_ClockCallback :: ClockCallback -> ClockCallback_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_ClockCallback Source #

Arguments

:: (HasCallStack, MonadIO m, IsClock a) 
=> FunPtr C_ClockCallback 
-> a

clock: The clock that triggered the callback

-> Word64

time: The time it was triggered

-> Ptr ()

id: The GstClockID that expired

-> Ptr ()

userData: user data passed in the clockIdWaitAsync function

-> m Bool

Returns: True or False (currently unused)

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ClockCallback :: C_ClockCallback -> IO (FunPtr C_ClockCallback) Source #

Generate a function pointer callable from C code, from a C_ClockCallback.

ControlBindingConvert

type C_ControlBindingConvert = Ptr ControlBinding -> CDouble -> Ptr GValue -> IO () Source #

Type for the callback on the (unwrapped) C side.

type ControlBindingConvert = ControlBinding -> Double -> GValue -> IO () Source #

FIXME(2.0): remove, this is unused

dynamic_ControlBindingConvert :: (HasCallStack, MonadIO m, IsControlBinding a) => FunPtr C_ControlBindingConvert -> a -> Double -> GValue -> m () Source #

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ControlBindingConvert :: C_ControlBindingConvert -> IO (FunPtr C_ControlBindingConvert) Source #

Generate a function pointer callable from C code, from a C_ControlBindingConvert.

ControlSourceGetValue

type C_ControlSourceGetValue = Ptr ControlSource -> Word64 -> CDouble -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type ControlSourceGetValue Source #

Arguments

 = ControlSource

self: the ControlSource instance

-> Word64

timestamp: timestamp for which a value should be calculated

-> Double

value: a value which will be set to the result.

-> IO Bool

Returns: True if the value was successfully calculated.

Function for returning a value for a given timestamp.

dynamic_ControlSourceGetValue Source #

Arguments

:: (HasCallStack, MonadIO m, IsControlSource a) 
=> FunPtr C_ControlSourceGetValue 
-> a

self: the ControlSource instance

-> Word64

timestamp: timestamp for which a value should be calculated

-> Double

value: a value which will be set to the result.

-> m Bool

Returns: True if the value was successfully calculated.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ControlSourceGetValue :: C_ControlSourceGetValue -> IO (FunPtr C_ControlSourceGetValue) Source #

Generate a function pointer callable from C code, from a C_ControlSourceGetValue.

ControlSourceGetValueArray

type C_ControlSourceGetValueArray = Ptr ControlSource -> Word64 -> Word64 -> Word32 -> CDouble -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type ControlSourceGetValueArray Source #

Arguments

 = ControlSource

self: the ControlSource instance

-> Word64

timestamp: timestamp for which a value should be calculated

-> Word64

interval: the time spacing between subsequent values

-> Word32

nValues: the number of values

-> Double

values: array to put control-values in

-> IO Bool

Returns: True if the values were successfully calculated.

Function for returning an array of values starting at a given timestamp.

dynamic_ControlSourceGetValueArray Source #

Arguments

:: (HasCallStack, MonadIO m, IsControlSource a) 
=> FunPtr C_ControlSourceGetValueArray 
-> a

self: the ControlSource instance

-> Word64

timestamp: timestamp for which a value should be calculated

-> Word64

interval: the time spacing between subsequent values

-> Word32

nValues: the number of values

-> Double

values: array to put control-values in

-> m Bool

Returns: True if the values were successfully calculated.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

CustomMetaTransformFunction

type C_CustomMetaTransformFunction = Ptr Buffer -> Ptr CustomMeta -> Ptr Buffer -> Word32 -> Ptr () -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type CustomMetaTransformFunction Source #

Arguments

 = Buffer

transbuf: a Buffer

-> CustomMeta

meta: a CustomMeta

-> Buffer

buffer: a Buffer

-> Word32

type: the transform type

-> Ptr ()

data: transform specific data.

-> IO Bool

Returns: True if the transform could be performed

Function called for each meta in buffer as a result of performing a transformation on transbuf. Additional type specific transform data is passed to the function as data.

Implementations should check the type of the transform and parse additional type specific fields in data that should be used to update the metadata on transbuf.

Since: 1.20

type CustomMetaTransformFunction_WithClosures Source #

Arguments

 = Buffer

transbuf: a Buffer

-> CustomMeta

meta: a CustomMeta

-> Buffer

buffer: a Buffer

-> Word32

type: the transform type

-> Ptr ()

data: transform specific data.

-> Ptr ()

userData: user data passed when registering the meta

-> IO Bool

Returns: True if the transform could be performed

Function called for each meta in buffer as a result of performing a transformation on transbuf. Additional type specific transform data is passed to the function as data.

Implementations should check the type of the transform and parse additional type specific fields in data that should be used to update the metadata on transbuf.

Since: 1.20

dynamic_CustomMetaTransformFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_CustomMetaTransformFunction 
-> Buffer

transbuf: a Buffer

-> CustomMeta

meta: a CustomMeta

-> Buffer

buffer: a Buffer

-> Word32

type: the transform type

-> Ptr ()

data: transform specific data.

-> Ptr ()

userData: user data passed when registering the meta

-> m Bool

Returns: True if the transform could be performed

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

DebugFuncPtr

type C_DebugFuncPtr = IO () Source #

Type for the callback on the (unwrapped) C side.

type DebugFuncPtr = IO () Source #

we define this to avoid a compiler warning regarding a cast from a function pointer to a void pointer (see https://bugzilla.gnome.org/show_bug.cgi?id=309253)

dynamic_DebugFuncPtr :: (HasCallStack, MonadIO m) => FunPtr C_DebugFuncPtr -> m () Source #

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_DebugFuncPtr :: C_DebugFuncPtr -> IO (FunPtr C_DebugFuncPtr) Source #

Generate a function pointer callable from C code, from a C_DebugFuncPtr.

ElementCallAsyncFunc

type C_ElementCallAsyncFunc = Ptr Element -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type ElementCallAsyncFunc Source #

Arguments

 = Element

element: The Element this function has been called against

-> IO () 

Callback prototype used in gst_element_call_async

type ElementCallAsyncFunc_WithClosures Source #

Arguments

 = Element

element: The Element this function has been called against

-> Ptr ()

userData: Data passed in the function where that callback has been passed

-> IO () 

Callback prototype used in gst_element_call_async

dynamic_ElementCallAsyncFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsElement a) 
=> FunPtr C_ElementCallAsyncFunc 
-> a

element: The Element this function has been called against

-> Ptr ()

userData: Data passed in the function where that callback has been passed

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ElementCallAsyncFunc :: C_ElementCallAsyncFunc -> IO (FunPtr C_ElementCallAsyncFunc) Source #

Generate a function pointer callable from C code, from a C_ElementCallAsyncFunc.

ElementForeachPadFunc

type C_ElementForeachPadFunc = Ptr Element -> Ptr Pad -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type ElementForeachPadFunc Source #

Arguments

 = Element

element: the Element

-> Pad

pad: a Pad

-> IO Bool

Returns: False to stop iterating pads, True to continue

Function called for each pad when using elementForeachSinkPad, elementForeachSrcPad, or elementForeachPad.

Since: 1.14

type ElementForeachPadFunc_WithClosures Source #

Arguments

 = Element

element: the Element

-> Pad

pad: a Pad

-> Ptr ()

userData: user data passed to the foreach function

-> IO Bool

Returns: False to stop iterating pads, True to continue

Function called for each pad when using elementForeachSinkPad, elementForeachSrcPad, or elementForeachPad.

Since: 1.14

dynamic_ElementForeachPadFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsElement a, IsPad b) 
=> FunPtr C_ElementForeachPadFunc 
-> a

element: the Element

-> b

pad: a Pad

-> Ptr ()

userData: user data passed to the foreach function

-> m Bool

Returns: False to stop iterating pads, True to continue

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ElementForeachPadFunc :: C_ElementForeachPadFunc -> IO (FunPtr C_ElementForeachPadFunc) Source #

Generate a function pointer callable from C code, from a C_ElementForeachPadFunc.

IteratorCopyFunction

type C_IteratorCopyFunction = Ptr Iterator -> Ptr Iterator -> IO () Source #

Type for the callback on the (unwrapped) C side.

type IteratorCopyFunction Source #

Arguments

 = Iterator

it: The original iterator

-> Iterator

copy: The copied iterator

-> IO () 

This function will be called when creating a copy of it and should create a copy of all custom iterator fields or increase their reference counts.

dynamic_IteratorCopyFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorCopyFunction 
-> Iterator

it: The original iterator

-> Iterator

copy: The copied iterator

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_IteratorCopyFunction :: C_IteratorCopyFunction -> IO (FunPtr C_IteratorCopyFunction) Source #

Generate a function pointer callable from C code, from a C_IteratorCopyFunction.

IteratorFoldFunction

type C_IteratorFoldFunction = Ptr GValue -> Ptr GValue -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type IteratorFoldFunction Source #

Arguments

 = GValue

item: the item to fold

-> GValue

ret: a Value collecting the result

-> IO Bool

Returns: True if the fold should continue, False if it should stop.

A function to be passed to iteratorFold.

type IteratorFoldFunction_WithClosures Source #

Arguments

 = GValue

item: the item to fold

-> GValue

ret: a Value collecting the result

-> Ptr ()

userData: data passed to iteratorFold

-> IO Bool

Returns: True if the fold should continue, False if it should stop.

A function to be passed to iteratorFold.

dynamic_IteratorFoldFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorFoldFunction 
-> GValue

item: the item to fold

-> GValue

ret: a Value collecting the result

-> Ptr ()

userData: data passed to iteratorFold

-> m Bool

Returns: True if the fold should continue, False if it should stop.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_IteratorFoldFunction :: C_IteratorFoldFunction -> IO (FunPtr C_IteratorFoldFunction) Source #

Generate a function pointer callable from C code, from a C_IteratorFoldFunction.

IteratorForeachFunction

type C_IteratorForeachFunction = Ptr GValue -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type IteratorForeachFunction Source #

Arguments

 = GValue

item: The item

-> IO () 

A function that is called by iteratorForeach for every element.

type IteratorForeachFunction_WithClosures Source #

Arguments

 = GValue

item: The item

-> Ptr ()

userData: User data

-> IO () 

A function that is called by iteratorForeach for every element.

dynamic_IteratorForeachFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorForeachFunction 
-> GValue

item: The item

-> Ptr ()

userData: User data

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

IteratorFreeFunction

type C_IteratorFreeFunction = Ptr Iterator -> IO () Source #

Type for the callback on the (unwrapped) C side.

type IteratorFreeFunction Source #

Arguments

 = Iterator

it: the iterator

-> IO () 

This function will be called when the iterator is freed.

Implementors of a Iterator should implement this function and pass it to the constructor of the custom iterator. The function will be called with the iterator lock held.

dynamic_IteratorFreeFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorFreeFunction 
-> Iterator

it: the iterator

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_IteratorFreeFunction :: C_IteratorFreeFunction -> IO (FunPtr C_IteratorFreeFunction) Source #

Generate a function pointer callable from C code, from a C_IteratorFreeFunction.

IteratorItemFunction

type C_IteratorItemFunction = Ptr Iterator -> Ptr GValue -> IO CUInt Source #

Type for the callback on the (unwrapped) C side.

type IteratorItemFunction Source #

Arguments

 = Iterator

it: the iterator

-> GValue

item: the item being retrieved.

-> IO IteratorItem

Returns: the result of the operation.

The function that will be called after the next item of the iterator has been retrieved. This function can be used to skip items or stop the iterator.

The function will be called with the iterator lock held.

dynamic_IteratorItemFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorItemFunction 
-> Iterator

it: the iterator

-> GValue

item: the item being retrieved.

-> m IteratorItem

Returns: the result of the operation.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_IteratorItemFunction :: C_IteratorItemFunction -> IO (FunPtr C_IteratorItemFunction) Source #

Generate a function pointer callable from C code, from a C_IteratorItemFunction.

IteratorNextFunction

type C_IteratorNextFunction = Ptr Iterator -> Ptr GValue -> IO CUInt Source #

Type for the callback on the (unwrapped) C side.

type IteratorNextFunction Source #

Arguments

 = Iterator

it: the iterator

-> GValue

result: a pointer to hold the next item

-> IO IteratorResult

Returns: the result of the operation.

The function that will be called when the next element of the iterator should be retrieved.

Implementors of a Iterator should implement this function and pass it to the constructor of the custom iterator. The function will be called with the iterator lock held.

dynamic_IteratorNextFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorNextFunction 
-> Iterator

it: the iterator

-> GValue

result: a pointer to hold the next item

-> m IteratorResult

Returns: the result of the operation.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_IteratorNextFunction :: C_IteratorNextFunction -> IO (FunPtr C_IteratorNextFunction) Source #

Generate a function pointer callable from C code, from a C_IteratorNextFunction.

IteratorResyncFunction

type C_IteratorResyncFunction = Ptr Iterator -> IO () Source #

Type for the callback on the (unwrapped) C side.

type IteratorResyncFunction Source #

Arguments

 = Iterator

it: the iterator

-> IO () 

This function will be called whenever a concurrent update happened to the iterated datastructure. The implementor of the iterator should restart the iterator from the beginning and clean up any state it might have.

Implementors of a Iterator should implement this function and pass it to the constructor of the custom iterator. The function will be called with the iterator lock held.

dynamic_IteratorResyncFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_IteratorResyncFunction 
-> Iterator

it: the iterator

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

LogFunction

type C_LogFunction = Ptr DebugCategory -> CUInt -> CString -> CString -> Int32 -> Ptr Object -> Ptr DebugMessage -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type LogFunction Source #

Arguments

 = DebugCategory

category: a DebugCategory

-> DebugLevel

level: a DebugLevel

-> Text

file: file name

-> Text

function: function name

-> Int32

line: line number

-> Object

object: a Object

-> DebugMessage

message: the message

-> IO () 

Function prototype for a logging function that can be registered with debugAddLogFunction. Use G_GNUC_NO_INSTRUMENT on that function.

type LogFunction_WithClosures Source #

Arguments

 = DebugCategory

category: a DebugCategory

-> DebugLevel

level: a DebugLevel

-> Text

file: file name

-> Text

function: function name

-> Int32

line: line number

-> Object

object: a Object

-> DebugMessage

message: the message

-> Ptr ()

userData: user data for the log function

-> IO () 

Function prototype for a logging function that can be registered with debugAddLogFunction. Use G_GNUC_NO_INSTRUMENT on that function.

drop_closures_LogFunction :: LogFunction -> LogFunction_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_LogFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsObject a) 
=> FunPtr C_LogFunction 
-> DebugCategory

category: a DebugCategory

-> DebugLevel

level: a DebugLevel

-> Text

file: file name

-> Text

function: function name

-> Int32

line: line number

-> a

object: a Object

-> DebugMessage

message: the message

-> Ptr ()

userData: user data for the log function

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_LogFunction :: C_LogFunction -> IO (FunPtr C_LogFunction) Source #

Generate a function pointer callable from C code, from a C_LogFunction.

MemoryCopyFunction

type C_MemoryCopyFunction = Ptr Memory -> Int64 -> Int64 -> IO (Ptr Memory) Source #

Type for the callback on the (unwrapped) C side.

type MemoryCopyFunction Source #

Arguments

 = Memory

mem: a Memory

-> Int64

offset: an offset

-> Int64

size: a size or -1

-> IO Memory

Returns: a new Memory object wrapping a copy of the requested region in mem.

Copy size bytes from mem starting at offset and return them wrapped in a new GstMemory object. If size is set to -1, all bytes starting at offset are copied.

dynamic_MemoryCopyFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryCopyFunction 
-> Memory

mem: a Memory

-> Int64

offset: an offset

-> Int64

size: a size or -1

-> m Memory

Returns: a new Memory object wrapping a copy of the requested region in mem.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MemoryCopyFunction :: C_MemoryCopyFunction -> IO (FunPtr C_MemoryCopyFunction) Source #

Generate a function pointer callable from C code, from a C_MemoryCopyFunction.

MemoryIsSpanFunction

type C_MemoryIsSpanFunction = Ptr Memory -> Ptr Memory -> Word64 -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type MemoryIsSpanFunction Source #

Arguments

 = Memory

mem1: a Memory

-> Memory

mem2: a Memory

-> Word64

offset: a result offset

-> IO Bool

Returns: True if mem1 and mem2 are in contiguous memory.

Check if mem1 and mem2 occupy contiguous memory and return the offset of mem1 in the parent buffer in offset.

dynamic_MemoryIsSpanFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryIsSpanFunction 
-> Memory

mem1: a Memory

-> Memory

mem2: a Memory

-> Word64

offset: a result offset

-> m Bool

Returns: True if mem1 and mem2 are in contiguous memory.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MemoryIsSpanFunction :: C_MemoryIsSpanFunction -> IO (FunPtr C_MemoryIsSpanFunction) Source #

Generate a function pointer callable from C code, from a C_MemoryIsSpanFunction.

MemoryMapFullFunction

type C_MemoryMapFullFunction = Ptr Memory -> Ptr MapInfo -> Word64 -> IO (Ptr ()) Source #

Type for the callback on the (unwrapped) C side.

type MemoryMapFullFunction Source #

Arguments

 = Memory

mem: a Memory

-> MapInfo

info: the MapInfo to map with

-> Word64

maxsize: size to map

-> IO (Ptr ())

Returns: a pointer to memory of which at least maxsize bytes can be accessed according to the access pattern in info's flags.

Get the memory of mem that can be accessed according to the mode specified in info's flags. The function should return a pointer that contains at least maxsize bytes.

dynamic_MemoryMapFullFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryMapFullFunction 
-> Memory

mem: a Memory

-> MapInfo

info: the MapInfo to map with

-> Word64

maxsize: size to map

-> m (Ptr ())

Returns: a pointer to memory of which at least maxsize bytes can be accessed according to the access pattern in info's flags.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MemoryMapFullFunction :: C_MemoryMapFullFunction -> IO (FunPtr C_MemoryMapFullFunction) Source #

Generate a function pointer callable from C code, from a C_MemoryMapFullFunction.

MemoryMapFunction

type C_MemoryMapFunction = Ptr Memory -> Word64 -> CUInt -> IO (Ptr ()) Source #

Type for the callback on the (unwrapped) C side.

type MemoryMapFunction Source #

Arguments

 = Memory

mem: a Memory

-> Word64

maxsize: size to map

-> [MapFlags]

flags: access mode for the memory

-> IO (Ptr ())

Returns: a pointer to memory of which at least maxsize bytes can be accessed according to the access pattern in flags.

Get the memory of mem that can be accessed according to the mode specified in flags. The function should return a pointer that contains at least maxsize bytes.

dynamic_MemoryMapFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryMapFunction 
-> Memory

mem: a Memory

-> Word64

maxsize: size to map

-> [MapFlags]

flags: access mode for the memory

-> m (Ptr ())

Returns: a pointer to memory of which at least maxsize bytes can be accessed according to the access pattern in flags.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MemoryMapFunction :: C_MemoryMapFunction -> IO (FunPtr C_MemoryMapFunction) Source #

Generate a function pointer callable from C code, from a C_MemoryMapFunction.

MemoryShareFunction

type C_MemoryShareFunction = Ptr Memory -> Int64 -> Int64 -> IO (Ptr Memory) Source #

Type for the callback on the (unwrapped) C side.

type MemoryShareFunction Source #

Arguments

 = Memory

mem: a Memory

-> Int64

offset: an offset

-> Int64

size: a size or -1

-> IO Memory

Returns: a new Memory object sharing the requested region in mem.

Share size bytes from mem starting at offset and return them wrapped in a new GstMemory object. If size is set to -1, all bytes starting at offset are shared. This function does not make a copy of the bytes in mem.

dynamic_MemoryShareFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryShareFunction 
-> Memory

mem: a Memory

-> Int64

offset: an offset

-> Int64

size: a size or -1

-> m Memory

Returns: a new Memory object sharing the requested region in mem.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MemoryShareFunction :: C_MemoryShareFunction -> IO (FunPtr C_MemoryShareFunction) Source #

Generate a function pointer callable from C code, from a C_MemoryShareFunction.

MemoryUnmapFullFunction

type C_MemoryUnmapFullFunction = Ptr Memory -> Ptr MapInfo -> IO () Source #

Type for the callback on the (unwrapped) C side.

type MemoryUnmapFullFunction Source #

Arguments

 = Memory

mem: a Memory

-> MapInfo

info: a MapInfo

-> IO () 

Release the pointer previously retrieved with memoryMap with info.

dynamic_MemoryUnmapFullFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryUnmapFullFunction 
-> Memory

mem: a Memory

-> MapInfo

info: a MapInfo

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

MemoryUnmapFunction

type C_MemoryUnmapFunction = Ptr Memory -> IO () Source #

Type for the callback on the (unwrapped) C side.

type MemoryUnmapFunction Source #

Arguments

 = Memory

mem: a Memory

-> IO () 

Release the pointer previously retrieved with memoryMap.

dynamic_MemoryUnmapFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MemoryUnmapFunction 
-> Memory

mem: a Memory

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MemoryUnmapFunction :: C_MemoryUnmapFunction -> IO (FunPtr C_MemoryUnmapFunction) Source #

Generate a function pointer callable from C code, from a C_MemoryUnmapFunction.

MetaFreeFunction

type C_MetaFreeFunction = Ptr Meta -> Ptr Buffer -> IO () Source #

Type for the callback on the (unwrapped) C side.

type MetaFreeFunction Source #

Arguments

 = Meta

meta: a Meta

-> Buffer

buffer: a Buffer

-> IO () 

Function called when meta is freed in buffer.

dynamic_MetaFreeFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MetaFreeFunction 
-> Meta

meta: a Meta

-> Buffer

buffer: a Buffer

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MetaFreeFunction :: C_MetaFreeFunction -> IO (FunPtr C_MetaFreeFunction) Source #

Generate a function pointer callable from C code, from a C_MetaFreeFunction.

MetaInitFunction

type C_MetaInitFunction = Ptr Meta -> Ptr () -> Ptr Buffer -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type MetaInitFunction Source #

Arguments

 = Meta

meta: a Meta

-> Ptr ()

params: parameters passed to the init function

-> Buffer

buffer: a Buffer

-> IO Bool 

Function called when meta is initialized in buffer.

dynamic_MetaInitFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MetaInitFunction 
-> Meta

meta: a Meta

-> Ptr ()

params: parameters passed to the init function

-> Buffer

buffer: a Buffer

-> m Bool 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MetaInitFunction :: C_MetaInitFunction -> IO (FunPtr C_MetaInitFunction) Source #

Generate a function pointer callable from C code, from a C_MetaInitFunction.

MetaTransformFunction

type C_MetaTransformFunction = Ptr Buffer -> Ptr Meta -> Ptr Buffer -> Word32 -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type MetaTransformFunction Source #

Arguments

 = Buffer

transbuf: a Buffer

-> Meta

meta: a Meta

-> Buffer

buffer: a Buffer

-> Word32

type: the transform type

-> Ptr ()

data: transform specific data.

-> IO Bool

Returns: True if the transform could be performed

Function called for each meta in buffer as a result of performing a transformation on transbuf. Additional type specific transform data is passed to the function as data.

Implementations should check the type of the transform and parse additional type specific fields in data that should be used to update the metadata on transbuf.

dynamic_MetaTransformFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MetaTransformFunction 
-> Buffer

transbuf: a Buffer

-> Meta

meta: a Meta

-> Buffer

buffer: a Buffer

-> Word32

type: the transform type

-> Ptr ()

data: transform specific data.

-> m Bool

Returns: True if the transform could be performed

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MetaTransformFunction :: C_MetaTransformFunction -> IO (FunPtr C_MetaTransformFunction) Source #

Generate a function pointer callable from C code, from a C_MetaTransformFunction.

MiniObjectCopyFunction

type C_MiniObjectCopyFunction = Ptr MiniObject -> IO (Ptr MiniObject) Source #

Type for the callback on the (unwrapped) C side.

type MiniObjectCopyFunction Source #

Arguments

 = MiniObject

obj: MiniObject to copy

-> IO MiniObject

Returns: reference to cloned instance.

Function prototype for methods to create copies of instances.

dynamic_MiniObjectCopyFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MiniObjectCopyFunction 
-> MiniObject

obj: MiniObject to copy

-> m MiniObject

Returns: reference to cloned instance.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

MiniObjectDisposeFunction

type C_MiniObjectDisposeFunction = Ptr MiniObject -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type MiniObjectDisposeFunction Source #

Arguments

 = MiniObject

obj: MiniObject to dispose

-> IO Bool

Returns: True if the object should be cleaned up.

Function prototype for when a miniobject has lost its last refcount. Implementation of the mini object are allowed to revive the passed object by doing a gst_mini_object_ref(). If the object is not revived after the dispose function, the function should return True and the memory associated with the object is freed.

dynamic_MiniObjectDisposeFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MiniObjectDisposeFunction 
-> MiniObject

obj: MiniObject to dispose

-> m Bool

Returns: True if the object should be cleaned up.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

MiniObjectFreeFunction

type C_MiniObjectFreeFunction = Ptr MiniObject -> IO () Source #

Type for the callback on the (unwrapped) C side.

type MiniObjectFreeFunction Source #

Arguments

 = MiniObject

obj: MiniObject to free

-> IO () 

Virtual function prototype for methods to free resources used by mini-objects.

dynamic_MiniObjectFreeFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MiniObjectFreeFunction 
-> MiniObject

obj: MiniObject to free

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

MiniObjectNotify

type C_MiniObjectNotify = Ptr () -> Ptr MiniObject -> IO () Source #

Type for the callback on the (unwrapped) C side.

type MiniObjectNotify Source #

Arguments

 = MiniObject

obj: the mini object

-> IO () 

A MiniObjectNotify function can be added to a mini object as a callback that gets triggered when gst_mini_object_unref() drops the last ref and obj is about to be freed.

type MiniObjectNotify_WithClosures Source #

Arguments

 = Ptr ()

userData: data that was provided when the notify was added

-> MiniObject

obj: the mini object

-> IO () 

A MiniObjectNotify function can be added to a mini object as a callback that gets triggered when gst_mini_object_unref() drops the last ref and obj is about to be freed.

drop_closures_MiniObjectNotify :: MiniObjectNotify -> MiniObjectNotify_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_MiniObjectNotify Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_MiniObjectNotify 
-> Ptr ()

userData: data that was provided when the notify was added

-> MiniObject

obj: the mini object

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_MiniObjectNotify :: C_MiniObjectNotify -> IO (FunPtr C_MiniObjectNotify) Source #

Generate a function pointer callable from C code, from a C_MiniObjectNotify.

PadActivateFunction

type C_PadActivateFunction = Ptr Pad -> Ptr Object -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadActivateFunction Source #

Arguments

 = Pad

pad: a Pad

-> Object

parent: the parent of pad

-> IO Bool

Returns: True if the pad could be activated.

This function is called when the pad is activated during the element READY to PAUSED state change. By default this function will call the activate function that puts the pad in push mode but elements can override this function to activate the pad in pull mode if they wish.

dynamic_PadActivateFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadActivateFunction 
-> a

pad: a Pad

-> b

parent: the parent of pad

-> m Bool

Returns: True if the pad could be activated.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadActivateFunction :: C_PadActivateFunction -> IO (FunPtr C_PadActivateFunction) Source #

Generate a function pointer callable from C code, from a C_PadActivateFunction.

PadActivateModeFunction

type C_PadActivateModeFunction = Ptr Pad -> Ptr Object -> CUInt -> CInt -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadActivateModeFunction Source #

Arguments

 = Pad

pad: a Pad

-> Object

parent: the parent of pad

-> PadMode

mode: the requested activation mode of pad

-> Bool

active: activate or deactivate the pad.

-> IO Bool

Returns: True if the pad could be activated or deactivated.

The prototype of the push and pull activate functions.

dynamic_PadActivateModeFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadActivateModeFunction 
-> a

pad: a Pad

-> b

parent: the parent of pad

-> PadMode

mode: the requested activation mode of pad

-> Bool

active: activate or deactivate the pad.

-> m Bool

Returns: True if the pad could be activated or deactivated.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

PadChainFunction

type C_PadChainFunction = Ptr Pad -> Ptr Object -> Ptr Buffer -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadChainFunction Source #

Arguments

 = Pad

pad: the sink Pad that performed the chain.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Buffer

buffer: the Buffer that is chained, not Nothing.

-> IO FlowReturn

Returns: GST_FLOW_OK for success

A function that will be called on sinkpads when chaining buffers. The function typically processes the data contained in the buffer and either consumes the data or passes it on to the internally linked pad(s).

The implementer of this function receives a refcount to buffer and should gst_buffer_unref() when the buffer is no longer needed.

When a chain function detects an error in the data stream, it must post an error on the bus and return an appropriate FlowReturn value.

dynamic_PadChainFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadChainFunction 
-> a

pad: the sink Pad that performed the chain.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Buffer

buffer: the Buffer that is chained, not Nothing.

-> m FlowReturn

Returns: GST_FLOW_OK for success

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadChainFunction :: C_PadChainFunction -> IO (FunPtr C_PadChainFunction) Source #

Generate a function pointer callable from C code, from a C_PadChainFunction.

PadChainListFunction

type C_PadChainListFunction = Ptr Pad -> Ptr Object -> Ptr BufferList -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadChainListFunction Source #

Arguments

 = Pad

pad: the sink Pad that performed the chain.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> BufferList

list: the BufferList that is chained, not Nothing.

-> IO FlowReturn

Returns: GST_FLOW_OK for success

A function that will be called on sinkpads when chaining buffer lists. The function typically processes the data contained in the buffer list and either consumes the data or passes it on to the internally linked pad(s).

The implementer of this function receives a refcount to list and should gst_buffer_list_unref() when the list is no longer needed.

When a chainlist function detects an error in the data stream, it must post an error on the bus and return an appropriate FlowReturn value.

dynamic_PadChainListFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadChainListFunction 
-> a

pad: the sink Pad that performed the chain.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> BufferList

list: the BufferList that is chained, not Nothing.

-> m FlowReturn

Returns: GST_FLOW_OK for success

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadChainListFunction :: C_PadChainListFunction -> IO (FunPtr C_PadChainListFunction) Source #

Generate a function pointer callable from C code, from a C_PadChainListFunction.

PadEventFullFunction

type C_PadEventFullFunction = Ptr Pad -> Ptr Object -> Ptr Event -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadEventFullFunction Source #

Arguments

 = Pad

pad: the Pad to handle the event.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Event

event: the Event to handle.

-> IO FlowReturn

Returns: FlowReturnOk if the event was handled properly, or any other FlowReturn dependent on downstream state.

Function signature to handle an event for the pad.

This variant is for specific elements that will take into account the last downstream flow return (from a pad push), in which case they can return it.

Since: 1.8

dynamic_PadEventFullFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadEventFullFunction 
-> a

pad: the Pad to handle the event.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Event

event: the Event to handle.

-> m FlowReturn

Returns: FlowReturnOk if the event was handled properly, or any other FlowReturn dependent on downstream state.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadEventFullFunction :: C_PadEventFullFunction -> IO (FunPtr C_PadEventFullFunction) Source #

Generate a function pointer callable from C code, from a C_PadEventFullFunction.

PadEventFunction

type C_PadEventFunction = Ptr Pad -> Ptr Object -> Ptr Event -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadEventFunction Source #

Arguments

 = Pad

pad: the Pad to handle the event.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Event

event: the Event to handle.

-> IO Bool

Returns: True if the pad could handle the event.

Function signature to handle an event for the pad.

dynamic_PadEventFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadEventFunction 
-> a

pad: the Pad to handle the event.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Event

event: the Event to handle.

-> m Bool

Returns: True if the pad could handle the event.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadEventFunction :: C_PadEventFunction -> IO (FunPtr C_PadEventFunction) Source #

Generate a function pointer callable from C code, from a C_PadEventFunction.

PadForwardFunction

type C_PadForwardFunction = Ptr Pad -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadForwardFunction Source #

Arguments

 = Pad

pad: the Pad that is forwarded.

-> IO Bool

Returns: True if the dispatching procedure has to be stopped.

A forward function is called for all internally linked pads, see padForward.

type PadForwardFunction_WithClosures Source #

Arguments

 = Pad

pad: the Pad that is forwarded.

-> Ptr ()

userData: the gpointer to optional user data.

-> IO Bool

Returns: True if the dispatching procedure has to be stopped.

A forward function is called for all internally linked pads, see padForward.

drop_closures_PadForwardFunction :: PadForwardFunction -> PadForwardFunction_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_PadForwardFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a) 
=> FunPtr C_PadForwardFunction 
-> a

pad: the Pad that is forwarded.

-> Ptr ()

userData: the gpointer to optional user data.

-> m Bool

Returns: True if the dispatching procedure has to be stopped.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadForwardFunction :: C_PadForwardFunction -> IO (FunPtr C_PadForwardFunction) Source #

Generate a function pointer callable from C code, from a C_PadForwardFunction.

PadGetRangeFunction

type C_PadGetRangeFunction = Ptr Pad -> Ptr Object -> Word64 -> Word32 -> Ptr Buffer -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadGetRangeFunction Source #

Arguments

 = Pad

pad: the src Pad to perform the getrange on.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Word64

offset: the offset of the range

-> Word32

length: the length of the range

-> Buffer

buffer: a memory location to hold the result buffer, cannot be Nothing.

-> IO FlowReturn

Returns: GST_FLOW_OK for success and a valid buffer in buffer. Any other return value leaves buffer undefined.

This function will be called on source pads when a peer element request a buffer at the specified offset and length. If this function returns GST_FLOW_OK, the result buffer will be stored in buffer. The contents of buffer is invalid for any other return value.

This function is installed on a source pad with gst_pad_set_getrange_function() and can only be called on source pads after they are successfully activated with padActivateMode with the GST_PAD_MODE_PULL.

offset and length are always given in byte units. offset must normally be a value between 0 and the length in bytes of the data available on pad. The length (duration in bytes) can be retrieved with a GST_QUERY_DURATION or with a GST_QUERY_SEEKING.

Any offset larger or equal than the length will make the function return GST_FLOW_EOS, which corresponds to EOS. In this case buffer does not contain a valid buffer.

The buffer size of buffer will only be smaller than length when offset is near the end of the stream. In all other cases, the size of buffer must be exactly the requested size.

It is allowed to call this function with a 0 length and valid offset, in which case buffer will contain a 0-sized buffer and the function returns GST_FLOW_OK.

When this function is called with a -1 offset, the sequentially next buffer of length length in the stream is returned.

When this function is called with a -1 length, a buffer with a default optimal length is returned in buffer. The length might depend on the value of offset.

dynamic_PadGetRangeFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadGetRangeFunction 
-> a

pad: the src Pad to perform the getrange on.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Word64

offset: the offset of the range

-> Word32

length: the length of the range

-> Buffer

buffer: a memory location to hold the result buffer, cannot be Nothing.

-> m FlowReturn

Returns: GST_FLOW_OK for success and a valid buffer in buffer. Any other return value leaves buffer undefined.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadGetRangeFunction :: C_PadGetRangeFunction -> IO (FunPtr C_PadGetRangeFunction) Source #

Generate a function pointer callable from C code, from a C_PadGetRangeFunction.

PadIterIntLinkFunction

type C_PadIterIntLinkFunction = Ptr Pad -> Ptr Object -> IO (Ptr Iterator) Source #

Type for the callback on the (unwrapped) C side.

type PadIterIntLinkFunction Source #

Arguments

 = Pad

pad: The Pad to query.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> IO Iterator

Returns: a new Iterator that will iterate over all pads that are linked to the given pad on the inside of the parent element.

the caller must call iteratorFree after usage.

The signature of the internal pad link iterator function.

dynamic_PadIterIntLinkFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadIterIntLinkFunction 
-> a

pad: The Pad to query.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> m Iterator

Returns: a new Iterator that will iterate over all pads that are linked to the given pad on the inside of the parent element.

the caller must call iteratorFree after usage.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

PadLinkFunction

type C_PadLinkFunction = Ptr Pad -> Ptr Object -> Ptr Pad -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadLinkFunction Source #

Arguments

 = Pad

pad: the Pad that is linked.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Pad

peer: the peer Pad of the link

-> IO PadLinkReturn

Returns: the result of the link with the specified peer.

Function signature to handle a new link on the pad.

dynamic_PadLinkFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b, IsPad c) 
=> FunPtr C_PadLinkFunction 
-> a

pad: the Pad that is linked.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> c

peer: the peer Pad of the link

-> m PadLinkReturn

Returns: the result of the link with the specified peer.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadLinkFunction :: C_PadLinkFunction -> IO (FunPtr C_PadLinkFunction) Source #

Generate a function pointer callable from C code, from a C_PadLinkFunction.

PadProbeCallback

type C_PadProbeCallback = Ptr Pad -> Ptr PadProbeInfo -> Ptr () -> IO CUInt Source #

Type for the callback on the (unwrapped) C side.

type PadProbeCallback Source #

Arguments

 = Pad

pad: the Pad that is blocked

-> PadProbeInfo

info: PadProbeInfo

-> IO PadProbeReturn

Returns: a PadProbeReturn

Callback used by padAddProbe. Gets called to notify about the current blocking type.

The callback is allowed to modify the data pointer in info.

type PadProbeCallback_WithClosures Source #

Arguments

 = Pad

pad: the Pad that is blocked

-> PadProbeInfo

info: PadProbeInfo

-> Ptr ()

userData: the gpointer to optional user data.

-> IO PadProbeReturn

Returns: a PadProbeReturn

Callback used by padAddProbe. Gets called to notify about the current blocking type.

The callback is allowed to modify the data pointer in info.

drop_closures_PadProbeCallback :: PadProbeCallback -> PadProbeCallback_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_PadProbeCallback Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a) 
=> FunPtr C_PadProbeCallback 
-> a

pad: the Pad that is blocked

-> PadProbeInfo

info: PadProbeInfo

-> Ptr ()

userData: the gpointer to optional user data.

-> m PadProbeReturn

Returns: a PadProbeReturn

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadProbeCallback :: C_PadProbeCallback -> IO (FunPtr C_PadProbeCallback) Source #

Generate a function pointer callable from C code, from a C_PadProbeCallback.

PadQueryFunction

type C_PadQueryFunction = Ptr Pad -> Ptr Object -> Ptr Query -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadQueryFunction Source #

Arguments

 = Pad

pad: the Pad to query.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Query

query: the Query object to execute

-> IO Bool

Returns: True if the query could be performed.

The signature of the query function.

dynamic_PadQueryFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadQueryFunction 
-> a

pad: the Pad to query.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> Query

query: the Query object to execute

-> m Bool

Returns: True if the query could be performed.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadQueryFunction :: C_PadQueryFunction -> IO (FunPtr C_PadQueryFunction) Source #

Generate a function pointer callable from C code, from a C_PadQueryFunction.

PadStickyEventsForeachFunction

type C_PadStickyEventsForeachFunction = Ptr Pad -> Ptr Event -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PadStickyEventsForeachFunction Source #

Arguments

 = Pad

pad: the Pad.

-> Maybe Event

event: a sticky Event.

-> IO Bool

Returns: True if the iteration should continue

Callback used by padStickyEventsForeach.

When this function returns True, the next event will be returned. When False is returned, padStickyEventsForeach will return.

When event is set to Nothing, the item will be removed from the list of sticky events. event can be replaced by assigning a new reference to it. This function is responsible for unreffing the old event when removing or modifying.

type PadStickyEventsForeachFunction_WithClosures Source #

Arguments

 = Pad

pad: the Pad.

-> Maybe Event

event: a sticky Event.

-> Ptr ()

userData: the gpointer to optional user data.

-> IO Bool

Returns: True if the iteration should continue

Callback used by padStickyEventsForeach.

When this function returns True, the next event will be returned. When False is returned, padStickyEventsForeach will return.

When event is set to Nothing, the item will be removed from the list of sticky events. event can be replaced by assigning a new reference to it. This function is responsible for unreffing the old event when removing or modifying.

dynamic_PadStickyEventsForeachFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a) 
=> FunPtr C_PadStickyEventsForeachFunction 
-> a

pad: the Pad.

-> Maybe Event

event: a sticky Event.

-> Ptr ()

userData: the gpointer to optional user data.

-> m Bool

Returns: True if the iteration should continue

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

PadUnlinkFunction

type C_PadUnlinkFunction = Ptr Pad -> Ptr Object -> IO () Source #

Type for the callback on the (unwrapped) C side.

type PadUnlinkFunction Source #

Arguments

 = Pad

pad: the Pad that is linked.

-> Maybe Object

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> IO () 

Function signature to handle a unlinking the pad prom its peer.

The pad's lock is already held when the unlink function is called, so most pad functions cannot be called from within the callback.

dynamic_PadUnlinkFunction Source #

Arguments

:: (HasCallStack, MonadIO m, IsPad a, IsObject b) 
=> FunPtr C_PadUnlinkFunction 
-> a

pad: the Pad that is linked.

-> Maybe b

parent: the parent of pad. If the GST_PAD_FLAG_NEED_PARENT flag is set, parent is guaranteed to be not-Nothing and remain valid during the execution of this function.

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PadUnlinkFunction :: C_PadUnlinkFunction -> IO (FunPtr C_PadUnlinkFunction) Source #

Generate a function pointer callable from C code, from a C_PadUnlinkFunction.

PluginFeatureFilter

type C_PluginFeatureFilter = Ptr PluginFeature -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PluginFeatureFilter Source #

Arguments

 = PluginFeature

feature: the pluginfeature to check

-> IO Bool

Returns: True for a positive match, False otherwise

A function that can be used with e.g. registryFeatureFilter to get a list of pluginfeature that match certain criteria.

type PluginFeatureFilter_WithClosures Source #

Arguments

 = PluginFeature

feature: the pluginfeature to check

-> Ptr ()

userData: the user_data that has been passed on e.g. registryFeatureFilter

-> IO Bool

Returns: True for a positive match, False otherwise

A function that can be used with e.g. registryFeatureFilter to get a list of pluginfeature that match certain criteria.

drop_closures_PluginFeatureFilter :: PluginFeatureFilter -> PluginFeatureFilter_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_PluginFeatureFilter Source #

Arguments

:: (HasCallStack, MonadIO m, IsPluginFeature a) 
=> FunPtr C_PluginFeatureFilter 
-> a

feature: the pluginfeature to check

-> Ptr ()

userData: the user_data that has been passed on e.g. registryFeatureFilter

-> m Bool

Returns: True for a positive match, False otherwise

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PluginFeatureFilter :: C_PluginFeatureFilter -> IO (FunPtr C_PluginFeatureFilter) Source #

Generate a function pointer callable from C code, from a C_PluginFeatureFilter.

PluginFilter

type C_PluginFilter = Ptr Plugin -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PluginFilter Source #

Arguments

 = Plugin

plugin: the plugin to check

-> IO Bool

Returns: True for a positive match, False otherwise

A function that can be used with e.g. registryPluginFilter to get a list of plugins that match certain criteria.

type PluginFilter_WithClosures Source #

Arguments

 = Plugin

plugin: the plugin to check

-> Ptr ()

userData: the user_data that has been passed on e.g. registryPluginFilter

-> IO Bool

Returns: True for a positive match, False otherwise

A function that can be used with e.g. registryPluginFilter to get a list of plugins that match certain criteria.

drop_closures_PluginFilter :: PluginFilter -> PluginFilter_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_PluginFilter Source #

Arguments

:: (HasCallStack, MonadIO m, IsPlugin a) 
=> FunPtr C_PluginFilter 
-> a

plugin: the plugin to check

-> Ptr ()

userData: the user_data that has been passed on e.g. registryPluginFilter

-> m Bool

Returns: True for a positive match, False otherwise

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PluginFilter :: C_PluginFilter -> IO (FunPtr C_PluginFilter) Source #

Generate a function pointer callable from C code, from a C_PluginFilter.

PluginInitFullFunc

type C_PluginInitFullFunc = Ptr Plugin -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PluginInitFullFunc Source #

Arguments

 = Plugin

plugin: The plugin object

-> IO Bool

Returns: True if plugin initialised successfully

A plugin should provide a pointer to a function of either PluginInitFunc or this type in the plugin_desc struct. The function will be called by the loader at startup. One would then register each PluginFeature. This version allows user data to be passed to init function (useful for bindings).

type PluginInitFullFunc_WithClosures Source #

Arguments

 = Plugin

plugin: The plugin object

-> Ptr ()

userData: extra data

-> IO Bool

Returns: True if plugin initialised successfully

A plugin should provide a pointer to a function of either PluginInitFunc or this type in the plugin_desc struct. The function will be called by the loader at startup. One would then register each PluginFeature. This version allows user data to be passed to init function (useful for bindings).

drop_closures_PluginInitFullFunc :: PluginInitFullFunc -> PluginInitFullFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_PluginInitFullFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsPlugin a) 
=> FunPtr C_PluginInitFullFunc 
-> a

plugin: The plugin object

-> Ptr ()

userData: extra data

-> m Bool

Returns: True if plugin initialised successfully

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PluginInitFullFunc :: C_PluginInitFullFunc -> IO (FunPtr C_PluginInitFullFunc) Source #

Generate a function pointer callable from C code, from a C_PluginInitFullFunc.

PluginInitFunc

type C_PluginInitFunc = Ptr Plugin -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type PluginInitFunc Source #

Arguments

 = Plugin

plugin: The plugin object

-> IO Bool

Returns: True if plugin initialised successfully

A plugin should provide a pointer to a function of this type in the plugin_desc struct. This function will be called by the loader at startup. One would then register each PluginFeature.

dynamic_PluginInitFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsPlugin a) 
=> FunPtr C_PluginInitFunc 
-> a

plugin: The plugin object

-> m Bool

Returns: True if plugin initialised successfully

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PluginInitFunc :: C_PluginInitFunc -> IO (FunPtr C_PluginInitFunc) Source #

Generate a function pointer callable from C code, from a C_PluginInitFunc.

PromiseChangeFunc

type C_PromiseChangeFunc = Ptr Promise -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type PromiseChangeFunc Source #

Arguments

 = Promise

promise: a Promise

-> IO () 

No description available in the introspection data.

Since: 1.14

type PromiseChangeFunc_WithClosures Source #

Arguments

 = Promise

promise: a Promise

-> Ptr ()

userData: user data

-> IO () 

No description available in the introspection data.

Since: 1.14

drop_closures_PromiseChangeFunc :: PromiseChangeFunc -> PromiseChangeFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_PromiseChangeFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_PromiseChangeFunc 
-> Promise

promise: a Promise

-> Ptr ()

userData: user data

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_PromiseChangeFunc :: C_PromiseChangeFunc -> IO (FunPtr C_PromiseChangeFunc) Source #

Generate a function pointer callable from C code, from a C_PromiseChangeFunc.

StructureFilterMapFunc

type C_StructureFilterMapFunc = Word32 -> Ptr GValue -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type StructureFilterMapFunc Source #

Arguments

 = Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> IO Bool

Returns: True if the field should be preserved, False if it should be removed.

A function that will be called in structureFilterAndMapInPlace. The function may modify value, and the value will be removed from the structure if False is returned.

type StructureFilterMapFunc_WithClosures Source #

Arguments

 = Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> Ptr ()

userData: user data

-> IO Bool

Returns: True if the field should be preserved, False if it should be removed.

A function that will be called in structureFilterAndMapInPlace. The function may modify value, and the value will be removed from the structure if False is returned.

dynamic_StructureFilterMapFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_StructureFilterMapFunc 
-> Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> Ptr ()

userData: user data

-> m Bool

Returns: True if the field should be preserved, False if it should be removed.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

StructureForeachFunc

type C_StructureForeachFunc = Word32 -> Ptr GValue -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type StructureForeachFunc Source #

Arguments

 = Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> IO Bool

Returns: True if the foreach operation should continue, False if the foreach operation should stop with False.

A function that will be called in structureForeach. The function may not modify value.

type StructureForeachFunc_WithClosures Source #

Arguments

 = Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> Ptr ()

userData: user data

-> IO Bool

Returns: True if the foreach operation should continue, False if the foreach operation should stop with False.

A function that will be called in structureForeach. The function may not modify value.

dynamic_StructureForeachFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_StructureForeachFunc 
-> Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> Ptr ()

userData: user data

-> m Bool

Returns: True if the foreach operation should continue, False if the foreach operation should stop with False.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_StructureForeachFunc :: C_StructureForeachFunc -> IO (FunPtr C_StructureForeachFunc) Source #

Generate a function pointer callable from C code, from a C_StructureForeachFunc.

StructureMapFunc

type C_StructureMapFunc = Word32 -> Ptr GValue -> Ptr () -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type StructureMapFunc Source #

Arguments

 = Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> IO Bool

Returns: True if the map operation should continue, False if the map operation should stop with False.

A function that will be called in structureMapInPlace. The function may modify value.

type StructureMapFunc_WithClosures Source #

Arguments

 = Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> Ptr ()

userData: user data

-> IO Bool

Returns: True if the map operation should continue, False if the map operation should stop with False.

A function that will be called in structureMapInPlace. The function may modify value.

drop_closures_StructureMapFunc :: StructureMapFunc -> StructureMapFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_StructureMapFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_StructureMapFunc 
-> Word32

fieldId: the GQuark of the field name

-> GValue

value: the Value of the field

-> Ptr ()

userData: user data

-> m Bool

Returns: True if the map operation should continue, False if the map operation should stop with False.

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_StructureMapFunc :: C_StructureMapFunc -> IO (FunPtr C_StructureMapFunc) Source #

Generate a function pointer callable from C code, from a C_StructureMapFunc.

TagForeachFunc

type C_TagForeachFunc = Ptr TagList -> CString -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TagForeachFunc Source #

Arguments

 = TagList

list: the TagList

-> Text

tag: a name of a tag in list

-> IO () 

A function that will be called in tagListForeach. The function may not modify the tag list.

type TagForeachFunc_WithClosures Source #

Arguments

 = TagList

list: the TagList

-> Text

tag: a name of a tag in list

-> Ptr ()

userData: user data

-> IO () 

A function that will be called in tagListForeach. The function may not modify the tag list.

drop_closures_TagForeachFunc :: TagForeachFunc -> TagForeachFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_TagForeachFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_TagForeachFunc 
-> TagList

list: the TagList

-> Text

tag: a name of a tag in list

-> Ptr ()

userData: user data

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_TagForeachFunc :: C_TagForeachFunc -> IO (FunPtr C_TagForeachFunc) Source #

Generate a function pointer callable from C code, from a C_TagForeachFunc.

TagMergeFunc

type C_TagMergeFunc = Ptr GValue -> Ptr GValue -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TagMergeFunc Source #

Arguments

 = GValue

dest: the destination Value

-> GValue

src: the source Value

-> IO () 

A function for merging multiple values of a tag used when registering tags.

dynamic_TagMergeFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_TagMergeFunc 
-> GValue

dest: the destination Value

-> GValue

src: the source Value

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_TagMergeFunc :: C_TagMergeFunc -> IO (FunPtr C_TagMergeFunc) Source #

Generate a function pointer callable from C code, from a C_TagMergeFunc.

TaskFunction

type C_TaskFunction = Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TaskFunction = IO () Source #

A function that will repeatedly be called in the thread created by a Task.

type TaskFunction_WithClosures Source #

Arguments

 = Ptr ()

userData: user data passed to the function

-> IO () 

A function that will repeatedly be called in the thread created by a Task.

drop_closures_TaskFunction :: TaskFunction -> TaskFunction_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_TaskFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_TaskFunction 
-> Ptr ()

userData: user data passed to the function

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_TaskFunction :: C_TaskFunction -> IO (FunPtr C_TaskFunction) Source #

Generate a function pointer callable from C code, from a C_TaskFunction.

TaskPoolFunction

type C_TaskPoolFunction = Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TaskPoolFunction = IO () Source #

Task function, see taskPoolPush.

type TaskPoolFunction_WithClosures Source #

Arguments

 = Ptr ()

userData: user data for the task function

-> IO () 

Task function, see taskPoolPush.

drop_closures_TaskPoolFunction :: TaskPoolFunction -> TaskPoolFunction_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_TaskPoolFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_TaskPoolFunction 
-> Ptr ()

userData: user data for the task function

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_TaskPoolFunction :: C_TaskPoolFunction -> IO (FunPtr C_TaskPoolFunction) Source #

Generate a function pointer callable from C code, from a C_TaskPoolFunction.

TaskThreadFunc

type C_TaskThreadFunc = Ptr Task -> Ptr Thread -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TaskThreadFunc Source #

Arguments

 = Task

task: The Task

-> Thread

thread: The Thread

-> IO () 

Custom GstTask thread callback functions that can be installed.

type TaskThreadFunc_WithClosures Source #

Arguments

 = Task

task: The Task

-> Thread

thread: The Thread

-> Ptr ()

userData: user data

-> IO () 

Custom GstTask thread callback functions that can be installed.

drop_closures_TaskThreadFunc :: TaskThreadFunc -> TaskThreadFunc_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_TaskThreadFunc Source #

Arguments

:: (HasCallStack, MonadIO m, IsTask a) 
=> FunPtr C_TaskThreadFunc 
-> a

task: The Task

-> Thread

thread: The Thread

-> Ptr ()

userData: user data

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_TaskThreadFunc :: C_TaskThreadFunc -> IO (FunPtr C_TaskThreadFunc) Source #

Generate a function pointer callable from C code, from a C_TaskThreadFunc.

TypeFindFunction

type C_TypeFindFunction = Ptr TypeFind -> Ptr () -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TypeFindFunction Source #

Arguments

 = TypeFind

find: A TypeFind structure

-> IO () 

A function that will be called by typefinding.

type TypeFindFunction_WithClosures Source #

Arguments

 = TypeFind

find: A TypeFind structure

-> Ptr ()

userData: optional data to pass to the function

-> IO () 

A function that will be called by typefinding.

drop_closures_TypeFindFunction :: TypeFindFunction -> TypeFindFunction_WithClosures Source #

A simple wrapper that ignores the closure arguments.

dynamic_TypeFindFunction Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_TypeFindFunction 
-> TypeFind

find: A TypeFind structure

-> Ptr ()

userData: optional data to pass to the function

-> m () 

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_TypeFindFunction :: C_TypeFindFunction -> IO (FunPtr C_TypeFindFunction) Source #

Generate a function pointer callable from C code, from a C_TypeFindFunction.

TypeFindGetLengthFieldCallback

type C_TypeFindGetLengthFieldCallback = Ptr () -> IO Word64 Source #

Type for the callback on the (unwrapped) C side.

type TypeFindGetLengthFieldCallback = Ptr () -> IO Word64 Source #

No description available in the introspection data.

dynamic_TypeFindGetLengthFieldCallback :: (HasCallStack, MonadIO m) => FunPtr C_TypeFindGetLengthFieldCallback -> Ptr () -> m Word64 Source #

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

TypeFindPeekFieldCallback

type C_TypeFindPeekFieldCallback = Ptr () -> Int64 -> Word32 -> IO Word8 Source #

Type for the callback on the (unwrapped) C side.

type TypeFindPeekFieldCallback = Ptr () -> Int64 -> Word32 -> IO Word8 Source #

No description available in the introspection data.

dynamic_TypeFindPeekFieldCallback :: (HasCallStack, MonadIO m) => FunPtr C_TypeFindPeekFieldCallback -> Ptr () -> Int64 -> Word32 -> m Word8 Source #

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

TypeFindSuggestFieldCallback

type C_TypeFindSuggestFieldCallback = Ptr () -> Word32 -> Ptr Caps -> IO () Source #

Type for the callback on the (unwrapped) C side.

type TypeFindSuggestFieldCallback = Ptr () -> Word32 -> Caps -> IO () Source #

No description available in the introspection data.

dynamic_TypeFindSuggestFieldCallback :: (HasCallStack, MonadIO m) => FunPtr C_TypeFindSuggestFieldCallback -> Ptr () -> Word32 -> Caps -> m () Source #

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

ValueCompareFunc

type C_ValueCompareFunc = Ptr GValue -> Ptr GValue -> IO Int32 Source #

Type for the callback on the (unwrapped) C side.

type ValueCompareFunc Source #

Arguments

 = GValue

value1: first value for comparison

-> GValue

value2: second value for comparison

-> IO Int32

Returns: one of GST_VALUE_LESS_THAN, GST_VALUE_EQUAL, GST_VALUE_GREATER_THAN or GST_VALUE_UNORDERED

Used together with valueCompare to compare Value items.

dynamic_ValueCompareFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_ValueCompareFunc 
-> GValue

value1: first value for comparison

-> GValue

value2: second value for comparison

-> m Int32

Returns: one of GST_VALUE_LESS_THAN, GST_VALUE_EQUAL, GST_VALUE_GREATER_THAN or GST_VALUE_UNORDERED

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ValueCompareFunc :: C_ValueCompareFunc -> IO (FunPtr C_ValueCompareFunc) Source #

Generate a function pointer callable from C code, from a C_ValueCompareFunc.

ValueDeserializeFunc

type C_ValueDeserializeFunc = Ptr GValue -> CString -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type ValueDeserializeFunc Source #

Arguments

 = GValue

dest: a Value

-> Text

s: a string

-> IO Bool

Returns: True for success

Used by valueDeserialize to parse a non-binary form into the Value.

dynamic_ValueDeserializeFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_ValueDeserializeFunc 
-> GValue

dest: a Value

-> Text

s: a string

-> m Bool

Returns: True for success

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ValueDeserializeFunc :: C_ValueDeserializeFunc -> IO (FunPtr C_ValueDeserializeFunc) Source #

Generate a function pointer callable from C code, from a C_ValueDeserializeFunc.

ValueDeserializeWithPSpecFunc

type C_ValueDeserializeWithPSpecFunc = Ptr GValue -> CString -> Ptr GParamSpec -> IO CInt Source #

Type for the callback on the (unwrapped) C side.

type ValueDeserializeWithPSpecFunc Source #

Arguments

 = GValue

dest: a Value

-> Text

s: a string

-> GParamSpec

pspec: a ParamSpec describing the expected value

-> IO Bool

Returns: True for success

Used by valueDeserializeWithPspec to parse a non-binary form into the Value.

Since: 1.20

dynamic_ValueDeserializeWithPSpecFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_ValueDeserializeWithPSpecFunc 
-> GValue

dest: a Value

-> Text

s: a string

-> GParamSpec

pspec: a ParamSpec describing the expected value

-> m Bool

Returns: True for success

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

ValueSerializeFunc

type C_ValueSerializeFunc = Ptr GValue -> IO CString Source #

Type for the callback on the (unwrapped) C side.

type ValueSerializeFunc Source #

Arguments

 = GValue

value1: a Value

-> IO Text

Returns: the string representation of the value

Used by valueSerialize to obtain a non-binary form of the Value.

Free-function: g_free

dynamic_ValueSerializeFunc Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> FunPtr C_ValueSerializeFunc 
-> GValue

value1: a Value

-> m Text

Returns: the string representation of the value

Given a pointer to a foreign C function, wrap it into a function callable from Haskell.

mk_ValueSerializeFunc :: C_ValueSerializeFunc -> IO (FunPtr C_ValueSerializeFunc) Source #

Generate a function pointer callable from C code, from a C_ValueSerializeFunc.