Class KinesisVideoFrame


  • @Immutable
    @ThreadSafe
    public class KinesisVideoFrame
    extends Object
    Kinesis Video frame representation.

    NOTE: This class must match the Frame declaration in native code in /mkvgen/Include.h

    See Also:
    PIC's MKVGEN
    • Field Detail

      • FRAME_CURRENT_VERSION

        public static final int FRAME_CURRENT_VERSION
        Current version for the structure as defined in the native code
        See Also:
        Constant Field Values
    • Constructor Detail

      • KinesisVideoFrame

        public KinesisVideoFrame​(int index,
                                 int flags,
                                 long decodingTs,
                                 long presentationTs,
                                 long duration,
                                 @Nonnull
                                 ByteBuffer data,
                                 long trackId)
        Creates a V0 struct version of a KinesisVideoFrame. Submit these frames to a Stream using KinesisVideoProducerStream.putFrame(KinesisVideoFrame)
        Parameters:
        index - ID for this frame.
        flags - Flags associated with this frame. They should be bitwise OR'ed together when specifying more than 1. See FrameFlags.
        decodingTs - DTS of this frame in hundreds of nanosecond units. Should be monotonically increasing.
        presentationTs - PTS of this frame in hundreds of nanosecond units. Should be monotonically increasing.
        duration - Duration of this frame in hundreds of nanosecond units. Can be 0.
        data - The frame contents.
        trackId - The track number this frame belongs to.
        Throws:
        OutOfMemoryError - if not enough memory to create a copy of the data.