initCamera method
override
Initializes the camera and starts streaming.
Implementation
@override
void initCamera() {
if (!camera.init()) {
final details = CameraDetails(status: CameraStatus.CAMERA_DISCONNECTED);
updateDetails(details);
return sendLog(LogLevel.warning, "Could not open RealSense");
}
sendLog(LogLevel.debug, "RealSense connected");
final name = camera.getName();
sendLog(LogLevel.trace, "RealSense model: $name");
if (!camera.startStream()) {
final details = CameraDetails(status: CameraStatus.CAMERA_NOT_RESPONDING);
updateDetails(details);
return sendLog(LogLevel.warning, "Could not start RealSense");
}
sendLog(LogLevel.debug, "Started streaming from RealSense");
}