Teeny cleanup

This commit is contained in:
Martyn 2021-12-12 12:11:42 +01:00
parent 169b73033d
commit 6c20cfe2b6
2 changed files with 1 additions and 5 deletions

View File

@ -40,6 +40,7 @@ func main() {
layout := layouts.NewFloatingControlsLayout()
layout.FloatingControlsLocation = layouts.FloatingControlsCenter
webcamID = 0
webcamWidget.UpdateFPS = 50
webcamLabel = widget.NewLabel("Webcam: 0")
buttons := container.NewHBox(webcamLabel, widget.NewButton("-", decWebCamID), widget.NewButton("+", incWebCamID))

View File

@ -52,11 +52,6 @@ type webcamRenderer struct {
goCVVideoCapture *gocv.VideoCapture
}
func renderframe(w, h int) image.Image {
frameImage := image.NewRGBA(image.Rect(0, 0, w, h))
return frameImage
}
func (r *webcamRenderer) actualrenderframe(w, h int) image.Image {
webcam, _ := gocv.VideoCaptureDevice(int(r.webcam.WebcamID))
img := gocv.NewMat()