Skip to content

Free Motion Capture for Everyone πŸ’€βœ¨

TypeScript

adding setup and preview

Endurance Idehen45745ad06761
diff --git a/freemocap-ui/src/layout/routing/router.tsx b/freemocap-ui/src/layout/routing/router.tsx
index cd57faf2..88f46a0f 100644
--- a/freemocap-ui/src/layout/routing/router.tsx
+++ b/freemocap-ui/src/layout/routing/router.tsx
@@ -6,7 +6,7 @@ import {WebcamJonTest} from "../../views/WebcamJonTest";
import {PythonToJsTest} from "../../views/PythonToJsTest";
import {BoardDetection} from "../../views/BoardDetection";
import {SkeletonDetection} from "../../views/SkeletonDetection";
-import {SetupAndPreview} from "../../views/prod/SetupAndPreview";
+import {SetupAndPreview} from "../../views/prod/SetupAndPreviewCamera";
export const Router = () => {
return (
diff --git a/freemocap-ui/src/views/prod/ConfigForm.tsx b/freemocap-ui/src/views/prod/ConfigForm.tsx
new file mode 100644
index 00000000..3ab183a0
--- /dev/null
+++ b/freemocap-ui/src/views/prod/ConfigForm.tsx
@@ -0,0 +1,14 @@
+import { Typography } from "@mui/material"
+import {Box} from "@mui/system";
+
+
+export const ConfigForm = () => {
+ return (
+ <Box>
+
+ <Typography>Exposure</Typography>
+
+
+ </Box>
+ )
+}
\ No newline at end of file
diff --git a/freemocap-ui/src/views/prod/SetupAndPreview.tsx b/freemocap-ui/src/views/prod/SetupAndPreviewCamera.tsx
similarity index 81%
rename from freemocap-ui/src/views/prod/SetupAndPreview.tsx
rename to freemocap-ui/src/views/prod/SetupAndPreviewCamera.tsx
index 1ad45119..09c59420 100644
--- a/freemocap-ui/src/views/prod/SetupAndPreview.tsx
+++ b/freemocap-ui/src/views/prod/SetupAndPreviewCamera.tsx
@@ -13,8 +13,12 @@ import React from "react";
// Finally, We'll include form inputs so that users can select configuration on screen, and submit their results
// for freemocap (api) to save (prolly to disk).
-export const SetupAndPreview = () => {
- const [frameCapture, data] = useFrameCapture("0", CaptureType.Preview);
+interface Props {
+ camId: string
+}
+
+export const SetupAndPreviewCamera = (props: Props) => {
+ const [frameCapture, data] = useFrameCapture(camId, CaptureType.Preview);
if (!data) {
return null;
}
diff --git a/src/cameras/capture/opencv_camera/opencv_camera.py b/src/cameras/capture/opencv_camera/opencv_camera.py
index 7e1c56ea..802df284 100644
--- a/src/cameras/capture/opencv_camera/opencv_camera.py
+++ b/src/cameras/capture/opencv_camera/opencv_camera.py
@@ -44,10 +44,6 @@ class OpenCVCamera:
def webcam_id_as_str(self):
return str(self._config.webcam_id)
- @property
- def current_fps(self):
- return self._running_thread.average_fps
-
@property
def is_capturing_frames(self):
if not self._running_thread:
@@ -55,10 +51,6 @@ class OpenCVCamera:
return False
return self._running_thread.is_capturing_frames
- @property
- def current_fps_short(self) -> str:
- return "{:.2f}".format(self._running_thread.average_fps)
-
@property
def latest_frame(self):
self._new_frame_ready = False
diff --git a/src/experiments/pyuvc_experiment.py b/src/experiments/pyuvc_experiment.py
new file mode 100644
index 00000000..e69de29b