PreviewingVideoGraph.Factory


public interface PreviewingVideoGraph.Factory


A factory for creating a PreviewingVideoGraph.

Summary

Public methods

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

Creates a new PreviewingVideoGraph instance.

Public methods

create

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

Creates a new PreviewingVideoGraph 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.

List<Effect> compositionEffects

A list of effects to apply to the composition.

long initialTimestampOffsetUs

The timestamp offset for the first frame, in microseconds.

Returns
PreviewingVideoGraph

A new instance.

Throws
androidx.media3.common.VideoFrameProcessingException

If a problem occurs while creating the .