Rotate Image Angle

This function block rotates an incoming image by a user-defined angle. You can control the angle via the on-block slider or feed an external numeric value into its input socket. You may also choose the interpolation method and optionally crop resulting background areas.

πŸ“₯ Inputs (sockets)

Image Any Provide the source image to be rotated.

(You may optionally provide a numeric angle via the angle socket if available on your canvas to override the on-block slider.)

πŸ“€ Outputs (sockets)

Image Any The rotated (and optionally cropped) output image.

Angle The numeric rotation angle applied (degrees).

πŸ•ΉοΈ Controls

Angle Use the slider to set the desired rotation in degrees. The slider also accepts an external numeric input if you prefer programmatic control.

Interpolation Method Choose how pixels are interpolated during rotation. Options typically include nearest and linear methods; pick the one that balances quality and speed for your case.

Crop Background Toggle this to remove black/empty regions introduced by rotation. When enabled, the block crops the rotated image to the largest central area without background artifacts.

🎨 Features

  • Live angle control via an adjustable slider or external numeric input.

  • Selectable interpolation for visual quality vs. speed trade-offs.

  • Optional automatic cropping to remove background areas created by rotation.

  • Outputs both the processed image and the applied angle value for downstream use.

πŸ“ How it runs

  1. Provide an image to the Image Any input socket or feed an image-producing block (for example, Camera USB or Load Image From Path).

  2. Set the angle using the Angle slider or connect a numeric source to the angle input.

  3. Choose the preferred Interpolation Method.

  4. Toggle Crop Background on if you want the output trimmed to avoid black corners.

  5. Run the flow β€” the block outputs the rotated image and the final angle value.

πŸ’‘ Tips and Tricks

  • For live camera feeds, combine with Camera USB, Camera IP, or Stream Reader as your image source and preview results with Show Image.

  • To focus rotation on a specific area, crop first with Image ROI Select and then rotate the cropped region.

  • To avoid visible artifacts on noisy images, try Denoising before rotation.

  • Save processed images using Image Logger or Image Write for record keeping.

πŸ› οΈ Troubleshooting

  • If you see black corners after rotation, enable Crop Background to remove them.

  • If rotated images look blocky or contain interpolation artifacts, switch the Interpolation Method to a higher-quality option (for example, from nearest to linear).

  • If processing is slow or uses too much memory, reduce input size with Image Resizer before rotating.

  • When providing angle via an external source, ensure the value is a valid numeric degree amount; otherwise the visual result may be unexpected.

Last updated

Was this helpful?