| 283 | } |
| 284 | |
| 285 | Status Worker::FrocessFrame(cv::Mat &frame, cv::Mat &frame_paint) { |
| 286 | fps_counter_->Begin("frame"); |
| 287 | |
| 288 | cv::Rect roi; |
| 289 | RETURN_ON_NEQ(GetROI(frame, roi), TNN_OK); |
| 290 | cv::Mat frame_croped = frame(roi).clone(); |
| 291 | cv::Mat frame_paint_croped = frame_paint(roi); |
| 292 | |
| 293 | RETURN_ON_NEQ(FaceDetectWithPaint(frame, frame_paint), TNN_OK); |
| 294 | // RETURN_ON_NEQ(BlazeFaceDetectWithPaint(frame_croped, frame_paint_croped), TNN_OK); |
| 295 | RETURN_ON_NEQ(AlignWithPaint(frame_croped, frame_paint_croped), TNN_OK); |
| 296 | |
| 297 | fps_counter_->End("frame"); |
| 298 | RETURN_ON_NEQ(DrawUI(frame_paint), TNN_OK); |
| 299 | return TNN_OK; |
| 300 | } |