Jump to content

Rotateable image.


photo

Recommended Posts

Posted

Searched docs and couldn't find anything to draw image on screen with rotation and alpha mask.

Suggestions?

Posted

Use WidgetSprite GUI object functionality setImage()/setTransform(). See documentation Programming\Unigine Script Library\GUI-Related Classes\WidgetSprite for details. Also have a look into sample widgets_xx (relevant code in folder data\samples\widgets\sprite_00/01.cpp)

Posted

I miss setTransform somehow, thx.

But there is no rotation in that tutorials and I can't make it work using rotateZ.

I make

setTransform(rotateZ(10*engine.game.getTime()));

and instead of normal rotating it's like image wants rotating in 3d(?!).

post-150-0-98226000-1292179138_thumb.jpg

  • 2 weeks later...
Posted

Thx for rotating.

 

What with alhpa mask? I want to make image only visible inside a designated circle.

Posted

a WidgetSprite can have multiple layer, each layer can have it's own transform.

×
×
  • Create New...