Rotate an image

If you are using one of our VIN drivers, you can simply rotate the image by changing a value in the INI-file for the VIN.

Those INI-Files contain the parameter RotateImage which may take the values

0: Rotate 0 degrees
1: Rotate 90 degrees
2: Rotate 180 degrees
3: Rotate 270 degrees

For further information take a look at the specific CVB Driver User Guide for the image acquisition device you use.


That said, this approach changes the rotation for the whole acquisition process. If you only want to rotate a single image, you can also use general functions in CVB for rotating images like CreateMatrixTransformedImage, CreateMatrixTransformedImageEx and RotateImage. But those functions take “a long time” to perform. So, if you would do it for every image acquired it might slow down your whole acquisition where the image rotation via the VIN takes virtual no time at all. :slight_smile: