源代码如下:
`const hands = new Hands({locateFile: (file) => {
return https://cdn.jsdelivr.net/npm/@mediapipe/hands/${file}
;
}});`
源于https://google.github.io/medi...
现在通过npm install ,本地已经下好了 @mediapipe/hands 这个包,我希望调用他 demo中的hands.setOptions
方法
如何改为通过import等方式调用本地下好的包
另外
const camera = new Camera(videoElement, {
onFrame: async () => {
await hands.send({image: videoElement});
},
width: 1280,
height: 720
});
是否需要同样进行修改呢,如果需要 怎么修改