| Gtk2Hs | Contents | Index

Media.Streaming.GStreamer.Core.Format

Maintainer | gtk2hs-devel@lists.sourceforge.net Stability : alpha Portability : portable (depends on GHC)

Contents

Types
Format Operations

Description
Synopsis

data Format

= FormatUndefined
| FormatDefault
| FormatBytes
| FormatTime
| FormatBuffers
| FormatPercent
| FormatUser FormatId

data FormatDefinition = FormatDefinition {

formatValue :: FormatId
formatNick :: String
formatDescription :: String
formatQuark :: Quark

}

data FormatId
formatPercentMax :: Int64
formatPercentScale :: Int64
formatGetName :: Format -> IO String
formatToQuark :: Format -> IO Quark
formatRegister :: String -> String -> IO Format
formatGetByNick :: String -> IO Format
formatGetDetails :: Format -> IO (Maybe FormatDefinition)
formatIterateDefinitions :: IO (Iterator FormatDefinition)

Types
data Format

An enumeration of standard predefined formats.
Constructors

FormatUndefined | no format
FormatDefault | the default format of the pad or element; this can be, e.g., samples for raw audio
FormatBytes | bytes
FormatTime | time in nanoseconds
FormatBuffers | buffers
FormatPercent | percentage of stream
FormatUser FormatId | a user defined format

Instances

Eq Format
Ord Format
Show Format

data FormatDefinition

A format definition.
Constructors

FormatDefinition |

formatValue :: FormatId | the unique id of this format
formatNick :: String | a short nickname for the format
formatDescription :: String | a longer description of the format
formatQuark :: Quark | a quark for the nickname

Instances

Eq FormatDefinition
Show FormatDefinition
Storable FormatDefinition
Iterable FormatDefinition

data FormatId

A format identifier.
Instances

Eq FormatId
Ord FormatId
Show FormatId

Format Operations
formatPercentMax :: Int64
The format value for `FormatPercent` is between 0 and this value.
formatPercentScale :: Int64
The value used to scale down the reported `FormatPercent` format value to its real value.
formatGetName

:: Format | `format` - a format
-> IO String | the name of the format
Get a printable name for the given format.

formatToQuark

:: Format | `format` - a format
-> IO Quark | the unique quark for the format
Get the unique quark for the given format.

formatRegister

:: String | `nick` - the nickname for the format
-> String | `description` - the description for the format
-> IO Format | the format with the given nickname
Create a new format based on the given nickname, or register a new format with that nickname.

formatGetByNick

:: String | `nick` - the nickname for the format
-> IO Format | the format with the given nickname, or `FormatUndefined` if it was not found
Get the format with the given nickname, or `FormatUndefined` if no format by that nickname was found.

formatGetDetails

:: Format | `format` - a format
-> IO (Maybe FormatDefinition) | the definition for the given format, or `Nothing` if the format was not found
Get the given format's definition.

formatIterateDefinitions :: IO (Iterator FormatDefinition)
Get an Iterator over all registered formats.
Produced by Haddock version 2.4.2