Image Manipulator

From OpenMBD
< HANtune
Revision as of 09:00, 27 June 2019 by Michiel (talk | contribs) (Adding an Image)
Jump to: navigation, search

The Image Manipulator is a viewer that can be used to transform an image based on the value of a signal. It allows you to either move, rotate, scale and/or transparentize an image using so called manipulations. By combining images, signals and manipulations a user is able to create new viewers to be used in a layout.

Manipulations

Move Manipulation

A move manipulation can be used to change an images X and Y position using pixels.

Move Manipulation

A static image of a cylinder overlayed by an Image Manipulator with a move manipulation manipulating an image of a piston in the Y direction.

Rotate Manipulation

A rotate manipulation can be used to change the angle of an image using degrees.

Move Manipulation

A static image of a compass overlayed by an Image Manipulator with a rotate manipulation manipulating an image of a pointer.

Scale Manipulation

A scale manipulation can be used to change the width and height of an image using pixels.

Move Manipulation

A scale manipulation manipulating the width and height of a square.

Transparentize Manipulation

A transparentize manipulation can be used to change the opacity of an image using percentages.

Move Manipulation

A static image of an LED that is off overlayed by an Image Manipulator with a transparentize manipulation manipulating the opacity of an image of LED that is on.

Using the Image Manipulator

Adding a new Image Manipulator to your layout

To add a new Image Manipulator to your layout either right click the layout or drag a signal from the sidepanel and the following menu will appear.

Adding an image manipulator

Adding a Signal

After adding the Image Manipulator to your layout it will appear empty. First a signal needs to be added which can be done by clicking the 'Add Signal' button seen in the image below or by dragging a signal from the sidepanel to the Image Manipulator.

Note: If the Image Manipulator was added to the layout by dragging a signal from the sidepanel, the 'Add Signal' button will not appear. To add more signals you can either drag them from the sidepanel or right click the Image Manipulator and add a signal through the context menu.

Adding a signal

Adding an Image

In addition to a signal, the Image Manipulator also needs an image to manipulate. An image can be added by clicking the 'Add Image' button as seen in the image below.

Adding an image

When both a signal and an image have been added the Image Manipulator will appear showing only the image.

For this step an image of a cylinder is used.

An image of a cylinder

Placing the Image Manipulator

A selected viewer with an image of a piston


Move to front dialog option

Managing Manipulations

Manage Manipulations

Managing Manipulations

Edit Manipulation

Editting Manipulations

Order of Manipulations

The order of your manipulions matter. Have a look at the following examples.


If a square is first rotated and then scaled, the end result will be a diamond.

Manipulation order: first rotated and then scaled


If a square is first scaled and then rotated, the end result will be a rotated rectangle.

Manipulation order: first rotated and then scaled

Demo Project

HANtune_IM_Demo.zip