VideoGraph.Factory


public interface VideoGraph.Factory


A factory for VideoGraph instances.

Summary

Public methods

abstract VideoGraph
create(
    Context context,
    ColorInfo outputColorInfo,
    DebugViewProvider debugViewProvider,
    VideoGraph.Listener listener,
    Executor listenerExecutor,
    VideoCompositorSettings videoCompositorSettings,
    List<Effect> compositionEffects,
    long initialTimestampOffsetUs,
    boolean renderFramesAutomatically
)

Creates a new VideoGraph instance.

abstract boolean

Returns whether the createdVideoGraph supports multiple video inputs.

Public methods

create

abstract VideoGraph create(
    Context context,
    ColorInfo outputColorInfo,
    DebugViewProvider debugViewProvider,
    VideoGraph.Listener listener,
    Executor listenerExecutor,
    VideoCompositorSettings videoCompositorSettings,
    List<Effect> compositionEffects,
    long initialTimestampOffsetUs,
    boolean renderFramesAutomatically
)

Creates a new VideoGraph instance.

Parameters
Context context

A Context.

ColorInfo outputColorInfo

The ColorInfo for the output frames.

DebugViewProvider debugViewProvider

A DebugViewProvider.

VideoGraph.Listener listener

A Listener.

Executor listenerExecutor

The Executor on which the listener is invoked.

VideoCompositorSettings videoCompositorSettings

The VideoCompositorSettings to apply to the composition.

List<Effect> compositionEffects

A list of effects to apply to the composition.

long initialTimestampOffsetUs

The timestamp offset for the first frame, in microseconds.

boolean renderFramesAutomatically

If true, the instance will render output frames to the output surface automatically as the instance is done processing them. If false, the instance will block until VideoGraph#renderOutputFrameWithMediaPresentationTime() is called, to render the frame.

Returns
VideoGraph

A new instance.

supportsMultipleInputs

abstract boolean supportsMultipleInputs()

Returns whether the createdVideoGraph supports multiple video inputs.