View Full Version : Full Screen
March 15, 2005, 19:59:09
I need help, howcan i set the live video to full screen,
For example, i have a video source with 720x576 and i want swicht to full PC screen resolution the current live video. I know that i will have a " pixel" quality becouse i'm using the max resolution for PAL.
I try with the LiveDisplayZoomFactor property but i can.
March 16, 2005, 08:36:12
Please follow the following steps to create a full screen video. It creates a really full screen video ;-)
Create a Visual Basic standard exe project. Add IC Imaging Control control to the project's form. Also add a timer to the form. In the Form_load sub, the device selection dialog should be displayed, so the user can select a video capture device:
Private Sub Form_Load()
Timer1.Enabled = False ' Needed for program termination on mouse click
' Check whether a valid video capture device has been selected.
If ICImagingControl1.DeviceValid Then
ICImagingControl1.LiveDisplayDefault = False
' No device has been selected. display a message
' and terminate the application.
MsgBox "No video capture device selected." + Chr(13) + _
"Please select a video capture device in the Properties window first!"
Now edit the form properties in Visual Basic's properties window. Set “BorderStyle” to “0-None”. Set “MinButton” and “MaxButton” to false. At least set “WindowState” to “2-Maximized”. The last settings causes the program to call the form's “Form_Resize” sub. In the “Form_Resize” sub, the form and IC Imaging Control's are maximized. The size of the live video display is also resized to the size of the form:
Private Sub Form_Resize()
' Resize the ImagingControl window
ICImagingControl1.Width = ScaleWidth
ICImagingControl1.Height = ScaleHeight
'Resize the displaywindow in the ImagingControl window
ICImagingControl1.LiveDisplayWidth = ScaleX(Width, vbTwips, vbPixels)
ICImagingControl1.LiveDisplayHeight = ScaleY(Height, vbTwips, vbPixels)
The program shall be terminated, if the left mouse button is clicked on the form. This can only be done with a timer event. Thus, the ICImagingControl1_MouseUp event handler sub is implemented as follows:
Private Sub ICImagingControl1_MouseUp(ByVal Button As Long, ByVal Shift As Long, ByVal XPos As Integer, ByVal YPos As Integer)
Timer1.Enabled = True ' Start the timer for program termination on mouse click
This makes sure, that the program has left any handler sub of IC Imaging Control, so the program can be terminated. The timer even sub terminates the program. It 's implementation see below:
' Terminate the program in the timer event sub.
Private Sub Timer1_Timer()
Timer1.Enabled = False
March 16, 2005, 08:38:10
This is the VB 6 sample project.
March 16, 2005, 10:36:04
Thanks a lot for the help.
Now i have this point clear.
Best regards and thanks again.
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.