loading
 
How to rotate compass image?
Petr from Czech Republic  [13 posts]
5 years
Hi STeven,

I’d like to display compass graphics on screen. Compass image should rotate accordingly with compass sensor in my ROV. I’d like to rotate the picture below by a variable in 360 steps. I will calculate this variable online from sensor data. Is possible to add rotation of image driven by variable in “Display_Image” module?

My compass image has circle shape, so there shouldn’t be problem with masking this rotating image. But what can I do, if I like to rotate just rosette with transparent surroundings? I thing I cannot do it with masking image, or I have to preload 360x2 pictures in all rotating positions.

Is possible to also add ability to display directly transparent gif (or png) as transparent without using image masking?

Petr


 
Steven Gentner from United States  [1371 posts] 5 years
Petr,

You can type in something like

[rotation]

into the Rotation textbox and RR will understand you instead mean to use the value of the variable 'rotation' as the degrees to use. In most text boxes you can use this expression ... see

http://www.roborealm.com/help/Expressions.php

for what is possible.

This will rotate the image AFTER applying the mask. So your mask should just be in the orientation of the original image. Thus you should only need one mask. I assume that meets your need?

See attached ...

STeven.

compass.zip

This forum thread has been closed due to inactivity (more than 4 months) or number of replies (more than 50 messages). Please start a New Post and enter a new forum thread with the appropriate title.

 New Post   Forum Index