mirror of
https://github.com/esimov/pigo.git
synced 2025-10-07 09:00:51 +08:00
18 lines
238 B
Go
18 lines
238 B
Go
// +build js,wasm
|
|
|
|
package main
|
|
|
|
import (
|
|
"github.com/esimov/pigo/wasm/canvas"
|
|
)
|
|
|
|
func main() {
|
|
c := canvas.NewCanvas()
|
|
webcam, err := c.StartWebcam()
|
|
if err != nil {
|
|
c.Alert("Webcam not detected!")
|
|
} else {
|
|
webcam.Render()
|
|
}
|
|
}
|