FrameProcessor


@ExperimentalApi
public interface FrameProcessor extends AutoCloseable

Known direct subclasses
DefaultGlFrameProcessor

A FrameProcessor implementation that executes a chain of GlTextureFrameConsumers.

FakeFrameProcessor

A no-op FrameProcessor that holds a reference to all queued frames for testing.

PacketConsumerToFrameProcessorAdapter

Adapts a RenderingPacketConsumer to the FrameProcessor interface.


Consumes frames, and outputs to a FrameWriter.

Summary

Nested types

public interface FrameProcessor.Factory

Factory for FrameProcessor instances.

public interface FrameProcessor.Listener

Listener for FrameProcessor events.

Public methods

abstract void

Blocks until all resources are released.

abstract boolean

Attempts to queue a List of frames for processing.

abstract void

Notifies this processor that the current stream has ended.

Public methods

close

abstract void close()

Blocks until all resources are released.

queue

abstract boolean queue(List<AsyncFrame> frames)

Attempts to queue a List of frames for processing.

All frames provided in a single invocation of this method represent the exact same point in time.

If this consumer is at capacity, this method returns false and the onWakeup will be invoked when capacity becomes available.

If this method returns true, onFrameProcessed must be called once with every input frame instance queued, once the FrameProcessor has finished processing the frames.

Parameters
List<AsyncFrame> frames

The frames to queue.

Returns
boolean

true if the frames were queued, false if the consumer is at capacity.

signalEndOfStream

abstract void signalEndOfStream()

Notifies this processor that the current stream has ended.

More frames may be queued after calling this method, if the current stream changes.