Page 1 of 1
How to apply the animation of gif pic in the MouseCursor?
Posted: Thu Mar 24, 2011 05:45
by ogre2012
I have made the animation true from the gif picture.
the specific procedure as following:
http://www.cegui.org.uk/phpBB2/viewtopic.php?f=2&t=5102#p26202 Now, I meet two questions.
1. But I don't know how to use it in the system MouseCursor.Because in Cegui the MouseCursor is not a Window.
2. How to expediently use the animation with a Tag. Like the following
Code: Select all
CEGUI::Window* textComponent;
.......
textComponent->setText("\n[colour='FF842B00'] Hello [font='Arial-Bold-10'] ABC123 [font='Arial-Italic-10'] ABC123 [font='Arial-BoldItalic-10'] ABC123 [font='Arial-10'] ABC123 ");
Somebody help me about it.
Thank you very much!
Re: How to apply the animation of gif pic in the MouseCursor
Posted: Thu Mar 24, 2011 16:40
by Kulik
MouseCursor is sadly not a PropertySet (maybe in 0.

so you can't animate it easily. I think you will need to use custom code for that.
I don't understand the second question, could you please provide further description of what you want to achieve?
Re: How to apply the animation of gif pic in the MouseCursor
Posted: Thu Mar 24, 2011 17:36
by Jamarr
ogre2012 wrote:1. But I don't know how to use it in the system MouseCursor.
Because in Cegui the MouseCursor is not a Window.
One way to work around this would be to hide the default mouse cursor and manually move a window around with the cursor. Note that you should still continue to inject mouse movement so that hover and other effects still work.
2. How to expediently use the animation with a Tag. Like the following
Code: Select all
CEGUI::Window* textComponent;
.......
textComponent->setText("\n[colour='FF842B00'] Hello [font='Arial-Bold-10'] ABC123 [font='Arial-Italic-10'] ABC123 [font='Arial-BoldItalic-10'] ABC123 [font='Arial-10'] ABC123 ");
I think he wants to setup an animation where the text color and font changes?
Re: How to apply the animation of gif pic in the MouseCursor
Posted: Sat Mar 26, 2011 20:23
by Kulik
Doing the text animation via string interpolator with discrete progression will be slow I think. But perhaps it's usable for short text.
We have to add some code to 0.8 if we want to make this work faster and more convenient.
Re: How to apply the animation of gif pic in the MouseCursor
Posted: Mon Mar 28, 2011 03:34
by spracle
You can use window's cursor instead of CEGUI' cursor.
A picture of .ani (or .cur) can be animated
Re: How to apply the animation of gif pic in the MouseCursor
Posted: Mon Mar 28, 2011 10:30
by ogre2012
spracle wrote:You can use window's cursor instead of CEGUI' cursor.
A picture of .ani (or .cur) can be animated
if I use the window's cursor, I can't get the events when the window's cursor goes through
the cegui's window or other conditions. That is to say the cegui's window wil be disabled.
Re: How to apply the animation of gif pic in the MouseCursor
Posted: Mon Mar 28, 2011 15:24
by spracle
if I use the window's cursor, I can't get the events when the window's cursor goes through
the cegui's window or other conditions. That is to say the cegui's window wil be disabled.
No,You just hide CEGUI's cursor(don't render it),so you can still get events,
