View Full Version : HUD Question
Haider of Sweden 05-19-2005, 02:54 PM The kind dude Frank helped me with this script
http://www.cgtalk.com/showpost.php?p=2291307&postcount=5
The question I have is, if it is possible to implent a HUD into that code, so that when the code loads through the script node in the expression editor, it also adds a HUD eg. centered up.
The HUD could show for example "StartInProject: Active"
|
|
silent_soul
05-19-2005, 03:09 PM
Don't know if this will help. But I used a script a that was embedded in a rig called Generi, it had nice HUD and operational. Going to try to attach a text version of it. Perhaps you can take it apart and use it accordingly.
o--= S|S =--o
But after looking at your question again.. do you just want a simple text HUD? If so.. the file might not help. Who knows, take from it what you will.
Haider of Sweden
05-19-2005, 03:17 PM
Hmm... what do you mean with simple text? Can a HUD be more complex than just text? Could be interesting to hear what you've to say.
Edit: You might have misunderstood me. The script does a totally different thing - however, its cool, I was looking for something like this :)
Now, show me some HUD
silent_soul
05-19-2005, 04:57 PM
By simple text I mean, if you go in to Maya and select Display / Heads Up Display / make a choice.
Here's the link to what I ws talking about. If you have any MEL questions, let me know. I can can take a look. Not too good myself, yet, though.
http://andrewsilke.com/generi_rig/generi_rig.html
This page has all the information and a picture of HUD potential.
Haider of Sweden
05-19-2005, 05:16 PM
Hmm, that link was very cool. I had some ideas myself, or rather speculations only, if the triggerscript can be used for such kind of rig.
But they arent regular HUD's, unless its not difficult to build something in MEL, and apply them when a file is being opened.
Ok, I am not clear enough.
The HUD idea I had was, that when using Franks script (link seen above), a HUD should be visible, to tell, that this project file has a script-node for that StartInProject thingo.
The HUD code should be implented together with the StartInProject script-node, so that the HUD appears everytime you open the file.
Why? To indicate, that this one has a script-node.
So, if we would use the unclear sentence above.
If it would be easy to build advanced HUDs with mel (eg. nurbs curves or whatever), and have them doing stuff, like activating/deactivating StartInProject - all this, implented in the script-node.
That would be awesome. HUDs are usually very limited (what I know). I dont know if they can be made clickable or such things.
About MEL questions, the script you showed me was nice, so I had some ideas about it which I discuss here:
http://www.cgtalk.com/showthread.php?t=241715
Haider of Sweden
05-31-2005, 07:44 PM
I've done some experiments, and I tell you below how far I have come.
First, the HUDs (I dont know if I should have two or one - its a matter of design)
headsUpDisplay
-section 2
-block 0
-label "StartInProject Status:"
-ba "center"
HUD_StartInProject;
headsUpDisplay
-s 2
-b 1
-l "Active"
-lfs "large"
-ba "center"
HUD_StartInProjectStatus;
Then, I have these codes, which I was to built into the headsup, but it didnt work. The command should be linked to the event
-command "headsUpDisplay -rem HUD_StartInProject;"
-event "NewSceneOpened"
I think NewSceneOpened is the right choice, because I want the HUD removed when making a new scene, or exiting this current scene.
Or, should I maybe add a ScriptNode that runs the command above during on-exit?
Then comes the final part - maybe its not a good idea, give me your suggestions and feedback. Befor you can know what feedback I am talking about, you have to read further.
It is a visibility issue for those HUDs
headsUpDisplay -e -vis 1 HUD_StartInProject
headsUpDisplay -e -vis 1 HUD_StartInProjectStatus
headsUpDisplay -e -vis 0 HUD_StartInProject
headsUpDisplay -e -vis 0 HUD_StartInProjectStatus
(Acutally, it would be ok, just deleting the HUD, by checking if it exist or not using:)
headsUpDisplay -ex HUD_StartInProject
However, I didnt manage to find a way to toggle between 1 and 0. There doesnt seem to be any -q here...
Why do I want the toggle?
Its because I wanted to add a submenu in the Heads Up Display menu.
But this is maybe a bad idea, since 1) You cant delete a menu afterwards (can you?), eg. when you exit the scene or anything, and the menuItem is still there, with no effect.
Maybe I should just not care about the visibility issue?
CGTalk Moderation
05-31-2005, 07:44 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2013, Jelsoft Enterprises Ltd.