gi-ges-1.0.4: libges bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.GES.Objects.Pipeline

Description

A Pipeline can take an audio-video Timeline and conveniently link its Track-s to an internal playsink element, for preview/playback, and an internal encodebin element, for rendering. You can switch between these modes using pipelineSetMode.

You can choose the specific audio and video sinks used for previewing the timeline by setting the Pipeline:audioSink and Pipeline:videoSink properties.

You can set the encoding and save location used in rendering by calling pipelineSetRenderSettings.

Synopsis

Exported types

newtype Pipeline Source #

Memory-managed wrapper type.

Constructors

Pipeline (ManagedPtr Pipeline) 

Instances

Instances details
Eq Pipeline Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

GObject Pipeline Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

ManagedPtrNewtype Pipeline Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

Methods

toManagedPtr :: Pipeline -> ManagedPtr Pipeline

TypedObject Pipeline Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

Methods

glibType :: IO GType

HasParentTypes Pipeline Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

IsGValue (Maybe Pipeline) Source #

Convert Pipeline to and from GValue. See toGValue and fromGValue.

Instance details

Defined in GI.GES.Objects.Pipeline

Methods

gvalueGType_ :: IO GType

gvalueSet_ :: Ptr GValue -> Maybe Pipeline -> IO ()

gvalueGet_ :: Ptr GValue -> IO (Maybe Pipeline)

type ParentTypes Pipeline Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

type ParentTypes Pipeline = '[Pipeline, Bin, Element, Object, Object, ChildProxy, VideoOverlay]

class (GObject o, IsDescendantOf Pipeline o) => IsPipeline o Source #

Type class for types which can be safely cast to Pipeline, for instance with toPipeline.

Instances

Instances details
(GObject o, IsDescendantOf Pipeline o) => IsPipeline o Source # 
Instance details

Defined in GI.GES.Objects.Pipeline

toPipeline :: (MonadIO m, IsPipeline o) => o -> m Pipeline Source #

Cast to Pipeline, for types for which this is known to be safe. For general casts, use castTo.

Methods

Click to display all available methods, including inherited ones

Expand

Methods

abortState, add, addControlBinding, addPad, addPropertyDeepNotifyWatch, addPropertyNotifyWatch, autoClock, bindProperty, bindPropertyFull, callAsync, changeState, childAdded, childRemoved, continueState, createAllPads, defaultError, expose, findUnlinkedPad, forceFloating, foreachPad, foreachSinkPad, foreachSrcPad, freezeNotify, getv, gotWindowHandle, handleEvents, hasActiveControlBindings, hasAncestor, hasAsAncestor, hasAsParent, isFloating, isLockedState, iterateAllByElementFactoryName, iterateAllByInterface, iterateElements, iteratePads, iterateRecurse, iterateSinkPads, iterateSinks, iterateSorted, iterateSources, iterateSrcPads, link, linkFiltered, linkPads, linkPadsFiltered, linkPadsFull, lookup, lostState, messageFull, messageFullWithDetails, noMorePads, notify, notifyByPspec, postMessage, prepareWindowHandle, previewGetAudioSink, previewGetVideoSink, previewSetAudioSink, previewSetVideoSink, provideClock, query, queryConvert, queryDuration, queryPosition, recalculateLatency, ref, refSink, releaseRequestPad, remove, removeControlBinding, removePad, removePropertyNotifyWatch, requestPad, requestPadSimple, runDispose, saveThumbnail, seek, seekSimple, sendEvent, stealData, stealQdata, suggestNextSync, syncChildrenStates, syncStateWithParent, syncValues, thawNotify, unlink, unlinkPads, unparent, unref, useClock, watchClosure.

Getters

getAutoFlushBus, getBaseTime, getBus, getByInterface, getByName, getByNameRecurseUp, getChildByIndex, getChildByName, getChildByNameRecurse, getChildrenCount, getClock, getCompatiblePad, getCompatiblePadTemplate, getContext, getContextUnlocked, getContexts, getControlBinding, getControlRate, getCurrentClockTime, getCurrentRunningTime, getData, getDelay, getFactory, getGValueArray, getLatency, getMetadata, getMode, getName, getPadTemplate, getPadTemplateList, getParent, getPathString, getPipelineClock, getProperty, getQdata, getRequestPad, getStartTime, getState, getStaticPad, getSuppressedFlags, getThumbnail, getThumbnailRgb24, getValue.

Setters

setAutoFlushBus, setBaseTime, setBus, setClock, setContext, setControlBindingDisabled, setControlBindingsDisabled, setControlRate, setData, setDataFull, setDelay, setLatency, setLockedState, setMode, setName, setParent, setProperty, setRenderRectangle, setRenderSettings, setStartTime, setState, setSuppressedFlags, setTimeline, setWindowHandle.

getMode

pipelineGetMode Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

pipeline: A Pipeline

-> m [PipelineFlags]

Returns: The current mode of pipeline.

Gets the Pipeline:mode of the pipeline.

getThumbnail

pipelineGetThumbnail Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

self: A Pipeline in GST_STATE_PLAYING or GST_STATE_PAUSED

-> Caps

caps: Some caps to specifying the desired format, or GST_CAPS_ANY to use the native format

-> m (Maybe Sample)

Returns: A sample of self's current image preview in the format given by caps, or Nothing if an error prevented fetching the sample.

Gets a sample from the pipeline of the currently displayed image in preview, in the specified format.

Note that if you use "ANY" caps for caps, then the current format of the image is used. You can retrieve these caps from the returned sample with sampleGetCaps.

getThumbnailRgb24

pipelineGetThumbnailRgb24 Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

self: A Pipeline in StatePlaying or StatePaused

-> Int32

width: The requested pixel width of the image, or -1 to use the native size

-> Int32

height: The requested pixel height of the image, or -1 to use the native size

-> m (Maybe Sample)

Returns: A sample of self's current image preview in the "RGB" format, scaled to width and height, or Nothing if an error prevented fetching the sample.

Gets a sample from the pipeline of the currently displayed image in preview, in the 24-bit "RGB" format and of the desired width and height.

See pipelineGetThumbnail.

new

pipelineNew Source #

Arguments

:: (HasCallStack, MonadIO m) 
=> m Pipeline

Returns: The newly created pipeline.

Creates a new pipeline.

previewGetAudioSink

pipelinePreviewGetAudioSink Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

self: A Pipeline

-> m (Maybe Element)

Returns: The audio sink used by self for preview.

Gets the Pipeline:audioSink of the pipeline.

previewGetVideoSink

pipelinePreviewGetVideoSink Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

self: A Pipeline

-> m (Maybe Element)

Returns: The video sink used by self for preview.

Gets the Pipeline:videoSink of the pipeline.

previewSetAudioSink

pipelinePreviewSetAudioSink Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a, IsElement b) 
=> a

self: A Pipeline in GST_STATE_NULL

-> Maybe b

sink: A audio sink for self to use for preview

-> m () 

Sets the Pipeline:audioSink of the pipeline.

previewSetVideoSink

pipelinePreviewSetVideoSink Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a, IsElement b) 
=> a

self: A Pipeline in GST_STATE_NULL

-> Maybe b

sink: A video sink for self to use for preview

-> m () 

Sets the Pipeline:videoSink of the pipeline.

saveThumbnail

pipelineSaveThumbnail Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

self: A Pipeline in StatePlaying or StatePaused

-> Int32

width: The requested pixel width of the image, or -1 to use the native size

-> Int32

height: The requested pixel height of the image, or -1 to use the native size

-> Text

format: The desired mime type (for example, "image/jpeg")

-> Text

location: The path to save the thumbnail to

-> m ()

(Can throw GError)

Saves the currently displayed image of the pipeline in preview to the given location, in the specified dimensions and format.

setMode

pipelineSetMode Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a) 
=> a

pipeline: A Pipeline

-> [PipelineFlags]

mode: The mode to set for pipeline

-> m Bool

Returns: True if the mode of pipeline was successfully set to mode.

Sets the Pipeline:mode of the pipeline.

Note that the pipeline will be set to GST_STATE_NULL during this call to perform the necessary changes. You will need to set the state again yourself after calling this.

**NOTE**: <http://developer.gnome.org/ges/stable/ges_pipeline_set_render_settings Rendering settings> need to be
set before setting /@mode@/ to @/GES_PIPELINE_MODE_RENDER/@ or
@/GES_PIPELINE_MODE_SMART_RENDER/@, the call to this method will fail
otherwise.

setRenderSettings

pipelineSetRenderSettings Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a, IsEncodingProfile b) 
=> a

pipeline: A Pipeline

-> Text

outputUri: The URI to save the Pipeline:timeline rendering result to

-> b

profile: The encoding to use for rendering the Pipeline:timeline

-> m Bool

Returns: True if the settings were successfully set on pipeline.

Specifies encoding setting to be used by the pipeline to render its Pipeline:timeline, and where the result should be written to.

This method **must** be called before setting the pipeline mode to GES_PIPELINE_MODE_RENDER.

setTimeline

pipelineSetTimeline Source #

Arguments

:: (HasCallStack, MonadIO m, IsPipeline a, IsTimeline b) 
=> a

pipeline: A Pipeline

-> b

timeline: The timeline to set for pipeline

-> m Bool

Returns: True if timeline was successfully given to pipeline.

Takes the given timeline and sets it as the Pipeline:timeline for the pipeline.

Note that you should only call this method once on a given pipeline because a pipeline can not have its Pipeline:timeline changed after it has been set.

Properties

audioFilter

The audio filter(s) to apply during playback in preview mode, immediately before the Pipeline:audioSink. This exposes the playsink:audio-filter property of the internal playsink.

Since: 1.6.0

clearPipelineAudioFilter :: (MonadIO m, IsPipeline o) => o -> m () Source #

Set the value of the “audio-filter” property to Nothing. When overloading is enabled, this is equivalent to

clear #audioFilter

constructPipelineAudioFilter :: (IsPipeline o, MonadIO m, IsElement a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “audio-filter” property. This is rarely needed directly, but it is used by new.

getPipelineAudioFilter :: (MonadIO m, IsPipeline o) => o -> m (Maybe Element) Source #

Get the value of the “audio-filter” property. When overloading is enabled, this is equivalent to

get pipeline #audioFilter

setPipelineAudioFilter :: (MonadIO m, IsPipeline o, IsElement a) => o -> a -> m () Source #

Set the value of the “audio-filter” property. When overloading is enabled, this is equivalent to

set pipeline [ #audioFilter := value ]

audioSink

The audio sink used for preview. This exposes the playsink:audio-sink property of the internal playsink.

clearPipelineAudioSink :: (MonadIO m, IsPipeline o) => o -> m () Source #

Set the value of the “audio-sink” property to Nothing. When overloading is enabled, this is equivalent to

clear #audioSink

constructPipelineAudioSink :: (IsPipeline o, MonadIO m, IsElement a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “audio-sink” property. This is rarely needed directly, but it is used by new.

getPipelineAudioSink :: (MonadIO m, IsPipeline o) => o -> m (Maybe Element) Source #

Get the value of the “audio-sink” property. When overloading is enabled, this is equivalent to

get pipeline #audioSink

setPipelineAudioSink :: (MonadIO m, IsPipeline o, IsElement a) => o -> a -> m () Source #

Set the value of the “audio-sink” property. When overloading is enabled, this is equivalent to

set pipeline [ #audioSink := value ]

mode

The pipeline's mode. In preview mode (for audio or video, or both) the pipeline can display the timeline's content to an end user. In rendering mode the pipeline can encode the timeline's content and save it to a file.

constructPipelineMode :: (IsPipeline o, MonadIO m) => [PipelineFlags] -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “mode” property. This is rarely needed directly, but it is used by new.

getPipelineMode :: (MonadIO m, IsPipeline o) => o -> m [PipelineFlags] Source #

Get the value of the “mode” property. When overloading is enabled, this is equivalent to

get pipeline #mode

setPipelineMode :: (MonadIO m, IsPipeline o) => o -> [PipelineFlags] -> m () Source #

Set the value of the “mode” property. When overloading is enabled, this is equivalent to

set pipeline [ #mode := value ]

timeline

The timeline used by this pipeline, whose content it will play and render, or Nothing if the pipeline does not yet have a timeline.

Note that after you set the timeline for the first time, subsequent calls to change the timeline will fail.

clearPipelineTimeline :: (MonadIO m, IsPipeline o) => o -> m () Source #

Set the value of the “timeline” property to Nothing. When overloading is enabled, this is equivalent to

clear #timeline

constructPipelineTimeline :: (IsPipeline o, MonadIO m, IsTimeline a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “timeline” property. This is rarely needed directly, but it is used by new.

getPipelineTimeline :: (MonadIO m, IsPipeline o) => o -> m (Maybe Timeline) Source #

Get the value of the “timeline” property. When overloading is enabled, this is equivalent to

get pipeline #timeline

setPipelineTimeline :: (MonadIO m, IsPipeline o, IsTimeline a) => o -> a -> m () Source #

Set the value of the “timeline” property. When overloading is enabled, this is equivalent to

set pipeline [ #timeline := value ]

videoFilter

The video filter(s) to apply during playback in preview mode, immediately before the Pipeline:videoSink. This exposes the playsink:video-filter property of the internal playsink.

Since: 1.6.0

clearPipelineVideoFilter :: (MonadIO m, IsPipeline o) => o -> m () Source #

Set the value of the “video-filter” property to Nothing. When overloading is enabled, this is equivalent to

clear #videoFilter

constructPipelineVideoFilter :: (IsPipeline o, MonadIO m, IsElement a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “video-filter” property. This is rarely needed directly, but it is used by new.

getPipelineVideoFilter :: (MonadIO m, IsPipeline o) => o -> m (Maybe Element) Source #

Get the value of the “video-filter” property. When overloading is enabled, this is equivalent to

get pipeline #videoFilter

setPipelineVideoFilter :: (MonadIO m, IsPipeline o, IsElement a) => o -> a -> m () Source #

Set the value of the “video-filter” property. When overloading is enabled, this is equivalent to

set pipeline [ #videoFilter := value ]

videoSink

The video sink used for preview. This exposes the playsink:video-sink property of the internal playsink.

clearPipelineVideoSink :: (MonadIO m, IsPipeline o) => o -> m () Source #

Set the value of the “video-sink” property to Nothing. When overloading is enabled, this is equivalent to

clear #videoSink

constructPipelineVideoSink :: (IsPipeline o, MonadIO m, IsElement a) => a -> m (GValueConstruct o) Source #

Construct a GValueConstruct with valid value for the “video-sink” property. This is rarely needed directly, but it is used by new.

getPipelineVideoSink :: (MonadIO m, IsPipeline o) => o -> m (Maybe Element) Source #

Get the value of the “video-sink” property. When overloading is enabled, this is equivalent to

get pipeline #videoSink

setPipelineVideoSink :: (MonadIO m, IsPipeline o, IsElement a) => o -> a -> m () Source #

Set the value of the “video-sink” property. When overloading is enabled, this is equivalent to

set pipeline [ #videoSink := value ]