Flip
Top  Previous  Next

Description

Returns or sets the horizontal and vertical flipping of the image. The values from 0 to 3 correspond to the following flipping conditions:

0 - None  
No image flipping is performed.  
1 - Horizontal  
The image is flipped horizontally.  
2 - Vertical  
The image is flipped vertically.  
3 - Both  
The image is flipped horizontally and vertically.  
 
Syntax

[VB]
objActiveDcam.Flip [= Value]


[C/C++]
HRESULT get_Flip( long *pFlip );
HRESULT put_Flip( long Flip );



Data Type
[VB]

Long


Parameters
[C/C++]

pFlip [out,retval]  
Pointer to the ordinal number of the currently selected flipping condition.  
Palette [in]  
The flipping condition to be set.  


Return Values


S_OK  
Success  
E_FAIL  
Failure.  
E_INVALIDARG  
Invalid property value.  
 

Example


This VB example demonstrates the use of a combo box for flipping the live video:

Private Sub Form_Load()  
ActiveDcam1.Acquire = True  
Combo1.AddItem ("None")  
Combo1.AddItem ("Horizontal")  
Combo1.AddItem ("Vertical")  
Combo1.AddItem ("Diagonal")  
Combo1.ListIndex = 0  
End Sub  
 
Private Sub Combo1_Click()  
ActiveDcam1.Flip = Combo1.ListIndex  
End Sub  

Remarks


Flipping affects the way the video is displayed in the control window as well as actual order of pixels in the image frame. If you apply one of the flipping options, the data returned by GetImageData and other data access methods will be flipped as well.

Note that the flip operation has precedence over Rotate. If both Flip and Rotate properties are non-zero, the frame will be flipped first and the resulting image rotated.