Rotate Method
Syntax
CWIMAQVision.Rotate SourceImage, DestImage, Angle [, FillValue = 0.0] [, InterpolateMethod = cwimaqInterpolateZeroOrder]
Return Type
On success, this method returns 0. On failure, this method returns a negative number.
Purpose
Obsolete—Use Rotate2 instead. Rotates an image counterclockwise.
Remarks
Use this method with U8, I16, SGL, and RGB32 images.
Parameters
SourceImage As CWIMAQImage
The image to rotate.
DestImage As CWIMAQImage
The resulting image.
Angle As Single
The angle, in degrees, to rotate the image.
FillValue As Variant
[Optional] The value with which the method fills the image pixels not covered by the rotated image.
This parameter has a default value of 0.0.
InterpolateMethod As Variant
[Optional] The method of interpolation. Valid interpolation methods for rotation are cwimaqInterpolateZeroOrder and cwimaqInterpolateBiLinear.
This parameter has a default value of cwimaqInterpolateZeroOrder.
Example
Private Sub Run_Click() Dim i As New CWIMAQImage ' Rotate the image in Viewer1 by 45 degrees. ' Store the result in i. CWIMAQVision1.Rotate CWIMAQViewer1.Image, i, 45, 128, _ cwimaqInterpolateBiLinear CWIMAQViewer2.Attach i End Sub