To download NI software, including the products shown below, visit ni.com/downloads.
Overview
Coding that exemplifies how to rotate a 2D array.
Description
This subVI utilizes the Transpose 2D Array.vi and the Reverse 1D Array.vi (with an auto-indexed for loop) to rotate a 2D array clockwise or counterclockwise respectively.
Requirements
LabVIEW 2012 (or compatible)
Steps to Implement or Execute Code
1. Enter the desired input array into the Array control, or use the default values.
2. Select the direction on the Rotation Orientation toggle and the magnitude on the Rotation enum.
3. Run the VI and observe the rotation.
Additional Information or References
Front Panel:
Block Diagram:
Clockwise:
Counterclockwise:
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.