From 23efaabee6bf75bfb57a9e7739b2beb83cb93942 Mon Sep 17 00:00:00 2001 From: Yury Date: Thu, 19 Dec 2024 08:53:16 +0300 Subject: [PATCH] cleanup --- cidre/examples/vn-thumbnail-generator/main.rs | 2 +- cidre/src/av/capture/video_data_output.rs | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/cidre/examples/vn-thumbnail-generator/main.rs b/cidre/examples/vn-thumbnail-generator/main.rs index 7c9a85a7..b5be85fe 100644 --- a/cidre/examples/vn-thumbnail-generator/main.rs +++ b/cidre/examples/vn-thumbnail-generator/main.rs @@ -71,7 +71,7 @@ fn calc_top_frames<'ear>( let distance = feature_print.distance_to(&frame.observation)?; if distance < SIMILARITY_THRESHOLD { // Replace the frame if the new frame has a higher score. - if &new_frame.score > &frame.score { + if new_frame.score > frame.score { frames[i] = new_frame.clone(); } is_similar = true; diff --git a/cidre/src/av/capture/video_data_output.rs b/cidre/src/av/capture/video_data_output.rs index bfef4acb..f0d32e6e 100644 --- a/cidre/src/av/capture/video_data_output.rs +++ b/cidre/src/av/capture/video_data_output.rs @@ -23,7 +23,10 @@ pub trait VideoDataOutputSampleBufDelegate: objc::Obj { ); } -define_obj_type!(pub VideoDataOutput(Output), AV_CAPTURE_VIDEO_DATA_OUTPUT); +define_obj_type!( + #[doc(alias = "AVCaptureVideoDataOuput")] + pub VideoDataOutput(Output), AV_CAPTURE_VIDEO_DATA_OUTPUT +); impl VideoDataOutput { #[objc::msg_send(setSampleBufferDelegate:queue:)]