VideoGraph.Factory


interface VideoGraph.Factory


A factory for VideoGraph instances.

Summary

Public functions

VideoGraph!
create(
    context: Context!,
    outputColorInfo: ColorInfo!,
    debugViewProvider: DebugViewProvider!,
    listener: VideoGraph.Listener!,
    listenerExecutor: Executor!,
    videoCompositorSettings: VideoCompositorSettings!,
    compositionEffects: (Mutable)List<Effect!>!,
    initialTimestampOffsetUs: Long,
    renderFramesAutomatically: Boolean
)

Creates a new VideoGraph instance.

Boolean

Returns whether the createdVideoGraph supports multiple video inputs.

Public functions

create

fun create(
    context: Context!,
    outputColorInfo: ColorInfo!,
    debugViewProvider: DebugViewProvider!,
    listener: VideoGraph.Listener!,
    listenerExecutor: Executor!,
    videoCompositorSettings: VideoCompositorSettings!,
    compositionEffects: (Mutable)List<Effect!>!,
    initialTimestampOffsetUs: Long,
    renderFramesAutomatically: Boolean
): VideoGraph!

Creates a new VideoGraph instance.

Parameters
context: Context!

A Context.

outputColorInfo: ColorInfo!

The ColorInfo for the output frames.

debugViewProvider: DebugViewProvider!

A DebugViewProvider.

listener: VideoGraph.Listener!

A Listener.

listenerExecutor: Executor!

The Executor on which the listener is invoked.

videoCompositorSettings: VideoCompositorSettings!

The VideoCompositorSettings to apply to the composition.

compositionEffects: (Mutable)List<Effect!>!

A list of effects to apply to the composition.

initialTimestampOffsetUs: Long

The timestamp offset for the first frame, in microseconds.

renderFramesAutomatically: Boolean

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

fun supportsMultipleInputs(): Boolean

Returns whether the createdVideoGraph supports multiple video inputs.