pub trait GESPipelineExt: IsA<Pipeline> + Sealed + 'static {
Show 26 methods // Provided methods fn mode(&self) -> PipelineFlags { ... } fn thumbnail(&self, caps: &Caps) -> Option<Sample> { ... } fn thumbnail_rgb24(&self, width: i32, height: i32) -> Option<Sample> { ... } fn preview_get_audio_sink(&self) -> Option<Element> { ... } fn preview_get_video_sink(&self) -> Option<Element> { ... } fn preview_set_audio_sink(&self, sink: Option<&impl IsA<Element>>) { ... } fn preview_set_video_sink(&self, sink: Option<&impl IsA<Element>>) { ... } fn save_thumbnail( &self, width: i32, height: i32, format: &str, location: &str ) -> Result<(), Error> { ... } fn set_mode(&self, mode: PipelineFlags) -> Result<(), BoolError> { ... } fn set_render_settings( &self, output_uri: &str, profile: &impl IsA<EncodingProfile> ) -> Result<(), BoolError> { ... } fn set_timeline( &self, timeline: &impl IsA<Timeline> ) -> Result<(), BoolError> { ... } fn audio_filter(&self) -> Option<Element> { ... } fn set_audio_filter<P: IsA<Element>>(&self, audio_filter: Option<&P>) { ... } fn audio_sink(&self) -> Option<Element> { ... } fn set_audio_sink<P: IsA<Element>>(&self, audio_sink: Option<&P>) { ... } fn timeline(&self) -> Option<Timeline> { ... } fn video_filter(&self) -> Option<Element> { ... } fn set_video_filter<P: IsA<Element>>(&self, video_filter: Option<&P>) { ... } fn video_sink(&self) -> Option<Element> { ... } fn set_video_sink<P: IsA<Element>>(&self, video_sink: Option<&P>) { ... } fn connect_audio_filter_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_audio_sink_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_mode_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_timeline_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_video_filter_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... } fn connect_video_sink_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId { ... }
}
Expand description

Trait containing all Pipeline methods.

§Implementors

Pipeline

Provided Methods§

source

fn mode(&self) -> PipelineFlags

Gets the mode of the pipeline.

§Returns

The current mode of self.

source

fn thumbnail(&self, caps: &Caps) -> Option<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 gst_sample_get_caps().

§caps

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

§Returns

A sample of self’s current image preview in the format given by caps, or None if an error prevented fetching the sample.

source

fn thumbnail_rgb24(&self, width: i32, height: i32) -> Option<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 thumbnail().

§width

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

§height

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

§Returns

A sample of self’s current image preview in the “RGB” format, scaled to width and height, or None if an error prevented fetching the sample.

source

fn preview_get_audio_sink(&self) -> Option<Element>

Gets the audio-sink of the pipeline.

§Returns

The audio sink used by self for preview.

source

fn preview_get_video_sink(&self) -> Option<Element>

Gets the video-sink of the pipeline.

§Returns

The video sink used by self for preview.

source

fn preview_set_audio_sink(&self, sink: Option<&impl IsA<Element>>)

Sets the audio-sink of the pipeline.

§sink

A audio sink for self to use for preview

source

fn preview_set_video_sink(&self, sink: Option<&impl IsA<Element>>)

Sets the video-sink of the pipeline.

§sink

A video sink for self to use for preview

source

fn save_thumbnail( &self, width: i32, height: i32, format: &str, location: &str ) -> Result<(), Error>

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

§width

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

§height

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

§format

The desired mime type (for example, “image/jpeg”)

§location

The path to save the thumbnail to

§Returns

true if self’s current image preview was successfully saved to location using the given format, height and width.

source

fn set_mode(&self, mode: PipelineFlags) -> Result<(), BoolError>

Sets the 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: Rendering settings need to be set before setting mode to PipelineFlags::RENDER or PipelineFlags::SMART_RENDER, the call to this method will fail otherwise.

§mode

The mode to set for self

§Returns

true if the mode of self was successfully set to mode.

source

fn set_render_settings( &self, output_uri: &str, profile: &impl IsA<EncodingProfile> ) -> Result<(), BoolError>

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

This method must be called before setting the pipeline mode to PipelineFlags::RENDER.

§output_uri

The URI to save the timeline rendering result to

§profile

The encoding to use for rendering the timeline

§Returns

true if the settings were successfully set on self.

source

fn set_timeline(&self, timeline: &impl IsA<Timeline>) -> Result<(), BoolError>

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

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

§timeline

The timeline to set for self

§Returns

true if timeline was successfully given to self.

source

fn audio_filter(&self) -> Option<Element>

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

source

fn set_audio_filter<P: IsA<Element>>(&self, audio_filter: Option<&P>)

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

source

fn audio_sink(&self) -> Option<Element>

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

source

fn set_audio_sink<P: IsA<Element>>(&self, audio_sink: Option<&P>)

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

source

fn timeline(&self) -> Option<Timeline>

The timeline used by this pipeline, whose content it will play and render, or None 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.

source

fn video_filter(&self) -> Option<Element>

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

source

fn set_video_filter<P: IsA<Element>>(&self, video_filter: Option<&P>)

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

source

fn video_sink(&self) -> Option<Element>

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

source

fn set_video_sink<P: IsA<Element>>(&self, video_sink: Option<&P>)

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

source

fn connect_audio_filter_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_audio_sink_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_mode_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId

source

fn connect_timeline_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_video_filter_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

source

fn connect_video_sink_notify<F: Fn(&Self) + 'static>( &self, f: F ) -> SignalHandlerId

Object Safety§

This trait is not object safe.

Implementors§