Viewpoint Developer Central    Viewpoint Forums    Viewpoint Forums  Hop To Forum Categories  Viewpoint Tips, Tricks & Hacks    how to build my own vet Mouse cursor shape?

Moderators: e_phoenix13
Go
New
Find
Notify
Tools
Reply
  
-star Rating Rate It!  Login/Join 
<cgkuake>
Posted
As we know that we can use MTSAssignProperty to set the Mouse cursor shape in vet scene!
I want to know how to create my own shape and use in vet scene?Smile
 
Reply With QuoteEdit or Delete MessageReport This Post
Member
Picture of Admin
Posted Hide Post
Hello,

You need a cursor-building program (such as Axialis AX Cursors www.axialis.com) that exports hexadecimal code in xml format. You can then use that hexadecimal code in VET as such:

<MTSCursor Name="view_cursor" >
<Mask AND = "0xf9, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0xff, 0xf0, 0x3f, 0xff, 0xff, 0xf0, 0x7, 0xff, 0xff, 0xf0, 0x1, 0xff, 0xff, 0xf0, 0x0, 0xff, 0xff, 0x10, 0x0, 0x7f, 0xff, 0x0, 0x0, 0x40, 0xff, 0x0, 0x0, 0x0, 0x1f, 0x80, 0x0, 0x0, 0xf, 0xc0, 0x0, 0x0, 0x7, 0xc0, 0x0, 0x0, 0x3, 0xe0, 0x0, 0x0, 0x1, 0xe0, 0x0, 0x0, 0x1, 0xf0, 0x0, 0x0, 0x1, 0xf0, 0x0, 0x0, 0x0, 0xf8, 0x0, 0x0, 0x0, 0xf8, 0x0, 0x0, 0x0, 0xf8, 0x0, 0x0, 0x0, 0xff, 0xc0, 0x0, 0x0, 0xff, 0xc0, 0x0, 0x0, 0xff, 0xe0, 0x0, 0x1, 0xff, 0xe0, 0x0, 0x1, 0xff, 0xe0, 0x0, 0x1, 0xff, 0xf0, 0x0, 0x3, 0xff, 0xf8, 0x0, 0x7, 0xff, 0xfc, 0x0, 0xf, 0xff, 0xfe, 0x0, 0x1f, 0xff, 0xff, 0xc0, 0xff" />
<Mask XOR = "0x0, 0x0, 0x0, 0x0, 0x6, 0x0, 0x0, 0x0, 0x6, 0x0, 0x0, 0x0, 0x6, 0x0, 0x0, 0x0, 0x6, 0x0, 0x0, 0x0, 0x6, 0x0, 0x0, 0x0, 0x6, 0xc0, 0x0, 0x0, 0x6, 0xd8, 0x0, 0x0, 0x6, 0xda, 0x0, 0x0, 0x6, 0xdb, 0x0, 0x0, 0x67, 0xfb, 0x0, 0x0, 0x77, 0xfe, 0x0, 0x0, 0x37, 0xfc, 0x0, 0x0, 0x17, 0xf8, 0x0, 0x0, 0x1f, 0xf0, 0x0, 0x0, 0xf, 0xe0, 0x7f, 0xc0, 0xf, 0xe1, 0xff, 0xf0, 0x7, 0xe3, 0xe1, 0xf8, 0x7, 0xc7, 0x0, 0x1c, 0x3, 0xc4, 0x0, 0xc, 0x3, 0xc8, 0x2, 0x4, 0x0, 0x0, 0x6, 0x0, 0x0, 0x1, 0xe, 0x10, 0x0, 0x1, 0x80, 0x30, 0x0, 0x0, 0xfb, 0xe0, 0x0, 0x0, 0x7f, 0x80, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0" />
<HotSpot x="6" y="0"/>
</MTSCursor>

You then need to switch the default scene cursor to your custom cursor with an action as such:

<MTSInteractor Name="my_Interactor" >
<Target Name="my_Instance" />
<MTSHandle Event="MouseMove" Action="MTSAssignProperty" Target="MTSScene::crsr" Value="MTSCursor::view_cursor" />
</MTSInteractor>

To switch the cursor back to the default scene cursor you would do the same as above, but instead of setting Value="MTSCursor::view_cursor" you would set Value="0" as such:

<MTSInteractor Name="my_Interactor" >
<Target Name="my_Instance" />
<MTSHandle Event="MouseExit" Action="MTSAssignProperty" Target="MTSScene::crsr" Value="0" />
</MTSInteractor>

Regards,
Viewpoint Support
 
Posts: 1188 | Registered: January 08, 2003Reply With QuoteEdit or Delete MessageReport This Post
Member
Posted Hide Post
Hi!

I know this topic is a bit old, but I would like to make a simple custom cursor aswell. An eyedropper cursor for a colorpicker funtion.

I have downloaded the cursor-building program you posted above, but It not seems to export to xml or any text format, only supports .cur and .ani and .bmp exports.
I searched the net for image/cursor exporters, creators, builders but none of them seems to able to export to xml/hex.

Can someone give me a link to a working converter?

thanks
s
 
Posts: 14 | Registered: May 15, 2006Reply With QuoteEdit or Delete MessageReport This Post
Member
Picture of Admin
Posted Hide Post
Actually,

A better way to do custom cursors than what I posted above, is to pin a 2d layer ( <LayerData/> ) to the location of the mouse, and make the default cursor transparent. To make the cursor transparent, use the hex code below:

<MTSCursor Name="clear_cursor" >
<Mask AND = "0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff" />
<Mask XOR = "0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0" />
<HotSpot x="0" y="0"/>
</MTSCursor>

And activate it with an action like so:

<MTSInteractor Name="cursor_change" NeverHandle="1" IgnoreHandled="1" >
<MTSHandle Event="MouseEnter" Action="MTSAssignProperty" Target="MTSScene.crsr" Value="MTSCursor::clear_cursor" />
</MTSInteractor>


Then follow the attached example to pin a 2d layer to the positoin of the mouse ... put any swf animation you want inside the 2d layer.

Cheers!

Zip/GZ archive2dlayer_follow_mouse.zip (8 KB, 21 downloads)
 
Posts: 1188 | Registered: January 08, 2003Reply With QuoteEdit or Delete MessageReport This Post
Member
Posted Hide Post
thanks!
It's working good. And I can build cursor with much better look Smile
 
Posts: 14 | Registered: May 15, 2006Reply With QuoteEdit or Delete MessageReport This Post
Member
Picture of Admin
Posted Hide Post
I'm glad it worked for you! Yes, you can put any kind of swf animation or even video in the 2d layer to create some pretty awesome effects. Enjoy!
 
Posts: 1188 | Registered: January 08, 2003Reply With QuoteEdit or Delete MessageReport This Post
  Powered by Eve Community  
 

Viewpoint Developer Central    Viewpoint Forums    Viewpoint Forums  Hop To Forum Categories  Viewpoint Tips, Tricks & Hacks    how to build my own vet Mouse cursor shape?