Open source Loom alternative. Beautiful, shareable screen recordings.
Rust appcapcossloommacnextjsnextjs15open-sourceossreactrecordrustscreen-capturescreen-recorderscreenshotsolidjstauritauri-apptypescriptvite
fix: Update frame stride calculation + camera bg overlay radius
Richie McIlroyc91a3ba59f50
diff --git a/apps/desktop/src-tauri/src/media.rs b/apps/desktop/src-tauri/src/media.rsindex d86df7387..4d64b2e78 100644--- a/apps/desktop/src-tauri/src/media.rs+++ b/apps/desktop/src-tauri/src/media.rs@@ -293,7 +293,7 @@ impl MediaRecorder {let frame_clone = frame.to_vec();std::thread::spawn(move || {let mut frame_data = Vec::with_capacity(capture_size);- let stride = frame_clone[..capture_size].len() / adjusted_height;+ let stride = w_cloned * 4;let rt = tokio::runtime::Runtime::new().unwrap();for row in 0..h {@@ -338,7 +338,7 @@ impl MediaRecorder {match capturer.frame() {Ok(frame) => {- let stride = frame[..capture_size].len() / adjusted_height;+ let stride = w * 4;for row in 0..adjusted_height {let start = row * stride;let end = start + stride;diff --git a/apps/desktop/src/components/windows/Camera.tsx b/apps/desktop/src/components/windows/Camera.tsxindex 530e72e37..2b0d02298 100644--- a/apps/desktop/src/components/windows/Camera.tsx+++ b/apps/desktop/src/components/windows/Camera.tsx@@ -86,7 +86,7 @@ export const Camera = () => {return (<divdata-tauri-drag-region- className="group w-full h-full bg-gray-200 rounded-full m-0 p-0 relative overflow-hidden flex items-center justify-center border-none outline-none focus:outline-none"+ className="group w-full h-full bg-gray-200 rounded-full m-0 p-0 relative overflow-hidden flex items-center justify-center border-none outline-none focus:outline-none rounded-full">{isLoading && (<div className="w-full h-full absolute top-0 left-0 bg-gray-200 z-10 flex items-center justify-center">