init mediapipe & tensorflow
This commit is contained in:
parent
8e8d317da3
commit
dc7e39f6d3
|
@ -58,11 +58,13 @@ const Home = () => {
|
|||
|
||||
if (videoRef.current) {
|
||||
videoRef.current.srcObject = stream;
|
||||
mediapipeHelper = new MediapipeHelper(videoRef);
|
||||
detectionHelper = new DetectionHelper();
|
||||
|
||||
console.log("Camera access granted and helpers initialized.");
|
||||
}
|
||||
|
||||
mediapipeHelper = new MediapipeHelper(videoRef);
|
||||
detectionHelper = new DetectionHelper();
|
||||
|
||||
setLoadCamera(true);
|
||||
onHandDetected();
|
||||
} catch (error) {
|
||||
|
@ -79,9 +81,7 @@ const Home = () => {
|
|||
|
||||
startWebcam();
|
||||
|
||||
return () => {
|
||||
|
||||
};
|
||||
return () => {};
|
||||
}, []);
|
||||
|
||||
return (
|
||||
|
|
Loading…
Reference in New Issue