TVIVideoFrame Class Reference
| Inherits from | NSObject |
|---|---|
| Declared in | TVIVideoFrame.h |
Overview
A video frame which has been captured or decoded.
TVIVideoFrame represents a CoreVideo buffer, along with metadata important for rendering and encoding.
– init
Developers shouldn’t use this initializer.
- (null_unspecified instancetype)initDiscussion
Create using initWithTimestamp:buffer:orientation: instead.
Declared In
TVIVideoFrame.h
– initWithTimestamp:buffer:orientation:
Initialize a video frame that has been captured.
- (nullable instancetype)initWithTimestamp:(CMTime)timestamp buffer:(nonnull CVImageBufferRef)imageBuffer orientation:(TVIVideoOrientation)orientationParameters
timestamp |
A CMTime struct which represents the time at which this frame was captured. |
|---|---|
imageBuffer |
A |
orientation |
The orientation at which this frame was captured. |
Discussion
Use this initializer if you already have a CMTime representation of your capture timestamp. Please note
that this timestamp may be internally translated after being delivered to the TVIVideoSink and before
being raised to your renderer(s).
See Also
Declared In
TVIVideoFrame.h
– initWithTimeInterval:buffer:orientation:
Initialize a video frame that has been captured.
- (nullable instancetype)initWithTimeInterval:(CFTimeInterval)timeInterval buffer:(nonnull CVImageBufferRef)imageBuffer orientation:(TVIVideoOrientation)orientationParameters
timeInterval |
A CFTimeInterval which represents the time when this frame was captured. |
|---|---|
imageBuffer |
A |
orientation |
The orientation at which this frame was captured. |
Discussion
This convenience initializer will convert a CFTimeInterval into a CMTime using a timescale appropriate for the underlying media engine.
See Also
Declared In
TVIVideoFrame.h
timestamp
The timestamp at which this frame was captured, or should be rendered.
@property (nonatomic, assign, readonly) CMTime timestampDiscussion
For decoded frames this is the display time measured using the system monotonic clock. For captured frames this should be the capture time measured using the timebase of the capturer.
Declared In
TVIVideoFrame.h
width
A convenience getter which returns the width of imageBuffer.
@property (nonatomic, assign, readonly) size_t widthDeclared In
TVIVideoFrame.h
height
A convenience getter which returns the height of imageBuffer.
@property (nonatomic, assign, readonly) size_t heightDeclared In
TVIVideoFrame.h
imageBuffer
A CVImageBuffer which contains the image data for the frame.
@property (nonatomic, assign, readonly, nonnull) CVImageBufferRef imageBufferDeclared In
TVIVideoFrame.h
orientation
The orientation metadata for the frame.
@property (nonatomic, assign, readonly) TVIVideoOrientation orientationDeclared In
TVIVideoFrame.h