getThreadCount method

int getThreadCount()

Gets the number of threads to be used for face detection and tracking. Hint: Default value is 1. Allocating more than one thread can increase the speed of the process.

return Number of threads to be used for face detection and tracking. throws FaceException An error has occurred during Face Library execution.

Implementation

int getThreadCount() {
  Pointer<Int> pThreadCount = calloc();
  try {
    var err = faceSDK.id3FaceTracker_GetThreadCount(_pHandle.value, pThreadCount);
    if (err != FaceError.success.value) {
      throw FaceException(err);
    }
    final vThreadCount = pThreadCount.value;
    return vThreadCount;
  } finally {
    calloc.free(pThreadCount);
  }
}