Package com.orbbec.obsensor

## Class FrameHelper

- java.lang.Object
- - com.orbbec.obsensor.FrameHelper

    public class FrameHelper
    extends java.lang.Object

### Constructor Summary

Constructors
`FrameHelper()`

### Method Summary

All Methods Static Methods Concrete Methods
`static Frame` `createFrameFromBuffer​(Format format, int width, int height, byte[] buffer)` Create a frame object based on an externally created Buffer
`static FrameSet` `createFrameSet()` Creates an empty frame collection object
`static void` `pushFrame​(Frame frameSet, FrameType frameType, Frame frame)` Populate the frame collection with frames of the corresponding type
`static void` `setFrameDeviceTimestamp​(Frame frame, long deviceTimestamp)` Set the device timestamp of the frame
`static void` `setFrameDeviceTimestampUs​(Frame frame, long deviceTimestampUs)` Set the device timestamp of the frame
`static void` `setFrameSystemTimestamp​(Frame frame, long systemTimestamp)` Set the system timestamp of the frame

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### FrameHelper

    public FrameHelper()

### Method Detail

#### createFrameFromBuffer

    public static Frame createFrameFromBuffer​(Format format,
                                              int width,
                                              int height,
                                              byte[] buffer)

Create a frame object based on an externally created Buffer

Parameters:
  `format` - frame object format
  `width` - frame object width
  `height` - frame object height
  `buffer` - frame object buffer
Returns:
  frame object

#### createFrameSet

    public static FrameSet createFrameSet()

Creates an empty frame collection object

Returns:
  frameset object

#### pushFrame

    public static void pushFrame​(Frame frameSet,
                                 FrameType frameType,
                                 Frame frame)

Populate the frame collection with frames of the corresponding type

Parameters:
  `frameSet` - frameset object
  `frameType` - the type of frame filled in
  `frame` - the object that fills the frame

#### setFrameSystemTimestamp

    public static void setFrameSystemTimestamp​(Frame frame,
                                               long systemTimestamp)

Set the system timestamp of the frame

Parameters:
  `frame` - object for frame settings
  `systemTimestamp` - set by systemTimestamp

#### setFrameDeviceTimestamp

    public static void setFrameDeviceTimestamp​(Frame frame,
                                               long deviceTimestamp)

Set the device timestamp of the frame

Parameters:
  `frame` - object for frame settings
  `deviceTimestamp` - set by deviceTimestamp

#### setFrameDeviceTimestampUs

    public static void setFrameDeviceTimestampUs​(Frame frame,
                                                 long deviceTimestampUs)

Set the device timestamp of the frame

Parameters:
  `frame` - object for frame settings
  `deviceTimestampUs` - the device timestamp set(Us)