working with marking menus in maya · you have the ability to modify the default maya marking...

6
North South/East Edges Marking Menus Edges Marking Menus > Merges/Collapse Edges subMenus WORKING WITH MARKING MENUS IN MAYA Laurent “Nzo” Herveic 1 - What are Marking Menus 2 - What are Context Marking Menus 3 - Existing Marking Menus commonly used 4 - Create your own Marking Menus 5 - Working with strokes 6 - Customize default Maya Marking Menus 1 - WHAT ARE MARKING MENUS Marking Menus allow you to improve your workflow in Maya, to manipulate objet with context menus or to execute command quickly. It’s very powerful tool and an alternative of hotkeys. The Marking Menus are built with the different axis (North, North/East, East, East/South, South, ect...) You can display Marking Menus by two different ways. Around the Hotbox or by Hotkeys. There are Sub Marking Menus, it’s like Marking Menus inside an other Marking Menus. It gives you more commands by simple click.

Upload: others

Post on 02-Sep-2020

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: WORKING WITH MARKING MENUS IN MAYA · You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking

North South/East

Edges Marking Menus Edges Marking Menus > Merges/Collapse Edges subMenus

WORKING WITH MARKING MENUS IN MAYA

Laurent “Nzo” Herveic

1 - What are Marking Menus 2 - What are Context Marking Menus 3 - Existing Marking Menus commonly used 4 - Create your own Marking Menus 5 - Working with strokes 6 - Customize default Maya Marking Menus

1 - WHAT ARE MARKING MENUS

Marking Menus allow you to improve your workflow in Maya, to manipulate objet with context menus or to execute command quickly. It’s very powerful tool and an alternative of hotkeys.

The Marking Menus are built with the different axis (North, North/East, East, East/South, South, ect...)

You can display Marking Menus by two different ways. Around the Hotbox or by Hotkeys.

There are Sub Marking Menus, it’s like Marking Menus inside an other Marking Menus. It gives you more commands by simple click.

Page 2: WORKING WITH MARKING MENUS IN MAYA · You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking

Mesh Vertex Edges Faces

Ctrl + Shift + LMB W + LMB E + LMB R + LMB

Q + LMB Center Hotbox + LMB RMB Shift + RMB

2 - WHAT ARE CONTEXT MARKING MENUS

Marking Menus can be used by context. By default in Maya, the Marking Menus are different regarding if you are using vertex, edges, faces, mesh or nothing with the same shorcut.It’s an optimal way to show you all the commands you can do from what you are doing.The context Marking Menus is more oriented modelling, but can be use in many way.

The most common context Marking Menu is the: - Shift > Right Mouse Button (RMB)

As you can see, some commands are post in same direction, Extrude in South, Merge in North, Split on West, ect...

3 - EXISTING MARKING MENUS COMMONLY USED

By default in Maya, there are many others Marking Menus. Here are some examples:

Page 3: WORKING WITH MARKING MENUS IN MAYA · You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking

4 - CREATE YOUR OWN MARKING MENUS

The basic way to create Marking Menus inside Maya: - Window > Settings/Preferences > Marking Menus Editor

- Choose “Create Marking Menus”

Where your personal Marking Menus will be save:WIN 64 - C:\Documents and Settings\YourName\My Documents\maya\2011-x64\prefs\markingMenusLINUX - /usr/autodesk/userconfig/maya/2011/prefs/markingMenusOSX - In your Home folder, under Library/Preferences/Autodesk/maya/2011/prefs/markingMenus

Now, you can drag and drop all the commands you want from the shelf editor with the MMB.

or

- RMB on empty command - Edit Menu Item ...

You can write your commands directly in the window.It can be more than one command. You can use the mel syntax (loop, condition, ect...)

Option box allows you to put an alternative command, like the settings window of your main command

The Popup Submenu create an other Marking Menu instead of a button. You can create an infi-nite of Submenu.

Page 4: WORKING WITH MARKING MENUS IN MAYA · You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking

(a) (b)

5 - WORKING WITH STROKES

The strokes is the faster way to use Marking Menus. You don’t even see the Marking Menu popup. Before seeing it, you just gesture where the command is supposed to popup. To demonstrate that, I’ll show you a quick exemple. Let’s pretend you want to extrude an edge. We will use the context Marking Menus of the edges.

- Select your model and switch to Edges mask (F3). - Shift + RMB on your model. The context Marking Menu popup. Go down (South). This is the normal way.

You can see a stroke representes the direction (North, North/East, East, ect...) and highlight the command of your Mark-ing Menu you want to call, in our case Extrude Edge command is in the South of our Marking Menu.

For working with strokes, you should move the mouse just before the Marking Menu appear in south direction and release the button before stopping to move the mouse. Sound a little bit complicated. But it’s just a timing trick.

Let’s do an exercise, still in Egdes mask (F3): - Shit + move your mouse anywhere + RMB. Don’t stop moving your mouse and holding the RMB in same time.

As you must see, if you keep going moving your mouse and holding RMB. The Marking Menu never popup. You can only see the stroke, which is look like a curly stroke (a), once you stop moving your mouse, the Marking Menu popup (b).

Page 5: WORKING WITH MARKING MENUS IN MAYA · You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking

Normal way Only with the stroke Result

You can use trace for sub Marking Menus as well. You have to keep going your gesture.Now, let’s pretend we want to use the Collapse Egde command by Marking Menu. - Shift > Right click button. And the gesture is Move up than right (North than East for Marking Menu)

6 - CUSTOMIZE DEFAULT MARKING MENUS

You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking Menu is.Open your Script Editor: - Window > General > Script Editor...

Inside the Script Editor. Switch on the “Echo All Commands” option. - History > Echo All Commands

Now you can vizualize all the next commands you will execute.For instance, we will modify one not very important, I don’t even know why is existing. Maybe one vestige.Nothing should be selected in your scene: - Right click in empty space of the viewport:

And this ligne should be printed in the Script Editor: buildObjectMenuItemsNow “MayaWindow|mayaMainWindowForm|formLayout3.....”;

That’s mean, the command is buildObjectMenuItemsNow and the second part MayaWindow|mayaMainWindowForm|formLayout3.....” is where is suppose to pop-up in the interface.

We don’t need the second part, it’s just some interfacing information. But the first part is our command.

Page 6: WORKING WITH MARKING MENUS IN MAYA · You have the ability to modify the default Maya Marking Menus. First you have to localize what is the name of the command and where the Marking

And know we want to know where this script is located. We will use the “what is (whatIs)” command. Still in the Script Editor, tape: - whatIs buildObjectMenuItemsNow;

Here is the Result:// Result: Mel procedure found in: C:/Program Files/Autodesk/Maya2011/scripts/others/build-ObjectMenuItemsNow.mel //

Now, you can load the script in you Script Editor: - File > Load Script...

Look only the menuItem command. It’s what you need to modify, remove or add. In this script go downand try to find this part: menuItem -label (uiRes(“m_buildObjectMenuItemsNow.kSelectAll”)) -radialPosition “S” -command (“SelectAll”);

menuItem -label (uiRes(“m_buildObjectMenuItemsNow.kCompleteTool”)) -radialPosition “N” -command (“CompleteCurrentTool”);

In the script editor, replace only this part. Here is an exemple: menuItem -label “sphere“ -radialPosition “S” -command (“polySphere”);

menuItem -label “render View“ -radialPosition “N” -command (“RenderViewWindow”);

menuItem -label “myCommand“ -radialPosition “E” -command (“nzoPersonnalCommand”);

In the Script Editor. Execute the script (Highlight all the text, CTRL + Enter). You should see that when you use the RMB like before.

Next time you run Maya. It will be the default Marking Menu. If you want override this Marking Menu for next time. You should save it, with the appropriate name “buildObjectMenuItemsNow.mel”, in the appropriate folder,

Here is where you should put your new Marking Menu for override the default one:WIN 64 - C:\Documents and Settings\User\My Documents\maya\2011-x64\scriptsLINUX - /usr/autodesk/userconfig/maya/2011/scriptsOSX - In your Home folder, under Library/Preferences/Autodesk/maya/2011/scripts

You can do that for override every scripts you want, not only Marking Menus.