首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > VB >

qq视频聊天时摄像头窗口的全屏功能,该怎么解决

2012-01-31 
qq视频聊天时摄像头窗口的全屏功能qq视频聊天时,双击摄像头窗口,这个窗口会自动全屏或者改变成原来的2倍大

qq视频聊天时摄像头窗口的全屏功能
qq视频聊天时,双击摄像头窗口,这个窗口会自动全屏或者改变成原来的2倍大小,当然画质会变得不好,这个全屏功能具体是如何实现的呢?vb中可以实现么?这样问应该更直接一下吧。

[解决办法]
用现成的语音视频开发包:AnyChat Platform Core SDK就可以实现,支持多方语音、视频交互,流媒体数据P2P网络传输,减少服务器的带宽占用,有Demo程序源代码可下载的。
[解决办法]
可以使用MoveWindow来修改窗口尺寸
[解决办法]
MoveWindow只是修改显示的大小,要想清晰度不受影响,应该修改采集时的分辨率参数。
[解决办法]
Dim mouseX As Integer
Dim mouseY As Integer
Dim moveX As Integer
Dim moveY As Integer
Dim down As Boolean

Private Sub Form_DblClick()
frmvedio.WindowState = 2
End Sub

Private Sub Form_KeyPress(KeyAscii As Integer)
If KeyAscii = 27 Then
 Me.WindowState = 0
End If
End Sub

Private Sub Form_Load()
Me.Top = 0
Me.Left = 0
frmsgirl.Top = Me.Height
frmsgirl.Left = (Screen.Width - frmsgirl.Width) / 2
Image3.Width = frmvedio.Width
Image3.Height = frmvedio.Height
End Sub

Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 1 Then
down = True
mouseX = X
mouseY = Y
ElseIf Button = 2 Then
Me.Hide
Else
End If
End Sub

Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
If down = True And frmvedio.WindowState = 0 Then
moveX = Me.Left - mouseX + X
moveY = Me.Top - mouseY + Y
Me.Move moveX, moveY
End If
End Sub

Private Sub Form_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
down = False
End Sub

Private Sub image3_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 1 Then
down = True
mouseX = X
mouseY = Y
ElseIf Button = 2 Then
Me.Hide
Else
End If
End Sub

Private Sub image3_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)

If down = True And frmvedio.WindowState = 0 Then
moveX = Me.Left - mouseX + X
moveY = Me.Top - mouseY + Y
Me.Move moveX, moveY
End If
End Sub

Private Sub image3_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
down = False

End Sub

Private Sub Form_Resize()
Image3.Width = frmvedio.Width - 2
Image3.Height = frmvedio.Height - 2
End Sub



Private Sub Image3_DblClick()
frmvedio.WindowState = 2
End Sub

Private Sub vediotimer_Timer()
Image3.Picture = frmsgirl.Image2.Picture
End Sub


[解决办法]
有全屏的API接口的,查一下DirectShow的相关文档就行了。

热点排行