Video SDK for Linux API Reference
Loading...
Searching...
No Matches
IFaceROIInfo Class Referenceabstract

Per-frame face ROI metadata accessor. More...

#include <zoom_sdk_raw_data_def.h>

Public Member Functions

virtual unsigned int GetFaceCount ()=0
 Number of valid face ROIs available for the current frame.
virtual const FaceROIGetFaceROIByIndex (unsigned int index)=0
 Get a face ROI by zero-based index.
virtual ~IFaceROIInfo ()

Detailed Description

Per-frame face ROI metadata accessor.

Face ROI data is generated on the sender's device and embedded in the video stream. The receiver SDK only surfaces what the sender provides; no face detection is performed locally. As a result, individual participants may deliver frames with zero detected faces — for example, when their device does not support face detection or when detection is not currently active on their end.

The lifetime of an IFaceROIInfo instance is bound to its host YUVRawDataI420 object - callers must NOT use it after the host frame is released. To use ROI data asynchronously, call AddRef() on the host YUVRawDataI420 object first.

Implementations always return a valid (non-null) object from YUVRawDataI420::GetFaceROIInfo(); inspect GetFaceCount() to determine whether any face data was included.

Note
Face ROI is only supported on video streams (RAW_DATA_TYPE_VIDEO).

Definition at line 101 of file zoom_sdk_raw_data_def.h.

Constructor & Destructor Documentation

◆ ~IFaceROIInfo()

virtual IFaceROIInfo::~IFaceROIInfo ( )
inlinevirtual

Definition at line 130 of file zoom_sdk_raw_data_def.h.

130{}

Member Function Documentation

◆ GetFaceCount()

virtual unsigned int IFaceROIInfo::GetFaceCount ( )
pure virtual

Number of valid face ROIs available for the current frame.

When multiple faces are present, the ROIs are ordered by the area of the detected region in descending order — index 0 corresponds to the largest (typically closest or most prominent) face.

Returns
The face count, in the range [0, 50]. Zero indicates that no face was detected, the sender has not enabled detection, or face metadata was not delivered for this frame.

◆ GetFaceROIByIndex()

virtual const FaceROI * IFaceROIInfo::GetFaceROIByIndex ( unsigned int index)
pure virtual

Get a face ROI by zero-based index.

Faces are sorted by detected region area in descending order; index 0 is always the largest face in the frame.

Parameters
indexThe zero-based index, must be < GetFaceCount().
Returns
Pointer to the FaceROI for the given index, or nullptr if index is out of range. The returned pointer is valid for the lifetime of this IFaceROIInfo object.