vb.net Emgu.CV 旋转摄像头视频


Imports Emgu.CV
Imports Emgu.CV.Structure
Imports Emgu.CV.Util

Public Class Form1

Dim capturez As Capture = New Capture
Dim imagez1 As Image(Of Bgr, Byte)
Dim imagez2 As Image(Of Bgr, Byte)
Dim rotation As Integer

Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick

imagez1 = capturez.RetrieveBgrFrame
imagez2 = imagez1.Rotate(rotation, New Bgr(255, 255, 255))

rotation = rotation + 2
If rotation = 360 Then
rotation = 0
End If

PictureBox1.Image = imagez2.ToBitmap
End Sub
End Class


原文地址:https://www.cnblogs.com/bbsno1/p/3260665.html