Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotfix/issue_183/memory leakage #210

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions screenpipe-server/src/video.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ use tokio::process::{Child, ChildStdin, Command};
use tokio::sync::mpsc::{channel, Receiver, Sender};

const MAX_FPS: f64 = 30.0; // Adjust based on your needs
const MAX_QUEUE_SIZE: usize = 100;
const MAX_QUEUE_SIZE: usize = 10;

pub struct VideoCapture {
#[allow(unused)]
Expand Down Expand Up @@ -88,11 +88,11 @@ impl VideoCapture {

let result = Arc::new(result);

let frame_pushed = push_to_queue(&capture_frame_queue, &result, "Frame");
// let frame_pushed = push_to_queue(&capture_frame_queue, &result, "Frame");
let video_pushed = push_to_queue(&capture_video_frame_queue, &result, "Video");
let ocr_pushed = push_to_queue(&capture_ocr_frame_queue, &result, "OCR");

if !frame_pushed || !video_pushed || !ocr_pushed {
if !video_pushed || !ocr_pushed {
error!(
"Failed to push frame {} to one or more queues",
frame_number
Expand Down
Loading