This is our new all in one marking menu. It hosts a wide variety of contextual possibilities. Currently it is divided between two modes – anim and td. It is designed to be a replacement for the ‘s’ key when working and default Maya ‘s’ key functionality is maintained. We used to have multipl marking menus for multiple things. It made more sense to have them housed in one marking menu and just compartmentalizing it to keep load speeds snappy.

Current modes:

There are also several menu options that are applicable to multiple sections.

General Concepts

  • Where the menu works — Any standard panel will let the marking menu bind to it – any 3d view, graph editor, outliner etc. If you try it over a tool settings window for example, it won’t work.
  • RayCasting — Something we started playing with for casting curves for rig building. Turns out casting rays in scenes can be used for lots of useful things.
    • Cast — Each time the screen is clicked, a ray is cast and the specified post actions occur
    • Drag — While the left click is held down, rays are continuously cast
    • Cast Targets — If no targets are in the buffer or the mode is not set to xyzPlane, all visible mesh or nurbs shapes in the scene are eligible targets.
    • Dropping — The default hotkey for dropping a tool is ‘q’. For certain functions, final actions won’t happen until the tool is dropped.
    • Repeat — The default repeat function ‘g’ key works fine with most processes.
    • Locators — Locators created while casting will store special information on them. A message link to the mesh hit which generate that loc and a json dictionary attribute with the shape normal of that hit as well as a hit index for the cast factory to use for other purposes. This is most typically used for finalization creation processes.
  • Options – As it can be tedious to change options via the marking menu, you can access options via a gui as well.
    • Top Menu>CGM>snap>{Options}
    • MarkingMenu>Options>Option UI
  • Buffers – These are optionVar derived object lists that may be maintained between maya sessions. There are controled via the cgmMeta.OptionVar metaclass.
  • Quick press functions — Some menus have functions that happen when the hot key is pressed quickly and released under a certain time. Anim is an example of this.
  • Hidden Menus — We found that just not building menu options where possible is much faster than enabling/disabling options. So for example, in the td menu if you have more than one thing selected, you will have more options in the sections below.
  • Context – What context functions happen based on selection. For example if you have scene wide context and set joint axis to on. All joints in scene will have their joint axis turned on
    • ‘*’ in menu item name — This means this menu item is contextual. It works off the context mode you have the marking menu in.

Compass – Shared

  • Snap (N) —  Snapping marking menu. The last object selected is the snapTo object unless used in rayCast mode in which all selected objects will be snapped.
    • Point — point matching a from/to selection format
    • Parent — point and orient matching a from/to selection format
    • Orient –orient matching a from/to selection format
    • Match — If an object is tagged to a cgmMatchTarget, will match the object to it’s match target. If it is an updatable object (Locinator locator), it will update
    • Aim — Currently uses object defaults from Menu. Will take into account object tagging in future. If three or more objects are selected, splits to subMenu:
      • All To Last — All items aim at the last
      • Selection Order — Each object aims to the next
      • First to Midpoint — first object aims at the midpoint of the rest of the selection
    • RayCast — utilizes the rayCast options to detect a point in space
    • AimCast — utilizes rayCasting to aim selected objects in real time at a point of intersection
  • Reset (S) — Reset the current object. Honors reset settings mode

Lower Section – Shared

These option lines are shared between modes. Remember you can edit them easily via the option ui. See General Concepts above.

  • Obj Defaults — What information is to be assumed on selected objects should no object specific information be self stored.
    • Obj Aim
    • Obj Up
    • Obj Out
  • Reset Mode – How the reset button should funtion. The core function uses one of Morgan Loomis’ calls. If you have certain attributes selected in the channel box only those will be reset.
    • Default – reset
    • Tranform attrs — Only reset transform attributes and not others
  • Raycast Options – These options affect both ray snapping and creation.
    • Cast
      • Surface — First hit per surface
      • Midpoint — Mid point of nearest and furthest hits detected
      • Far — Furthest hit
      • Pierce — All intersections
      • xPlane — Plane is generated to cast upon
      • yPlane — ” “
      • zPlane — ” “
    • Offset
      • None
      • Distance — Object is offset by a given distance along the vector of the mesh hit
      • SnapCast — Object is offset by a detected offset amount based on the objects ‘down’ axis first intersection. This is only until we find a better way to detect a better offset amount.
    • Set offset — brings up a ui prompt to change the offset value to use with offset distance mode.
    • Orient
      • None
      • Normal — Orient target with the assumed axis information relative to the normal of the mesh hit. The orient mode is still being refined.
    • Cast Buffer
      • Define
      • Add selected
      • Remove selected
      • Select members
      • Clear
    • Aim Tolerance — Tolerance for aim
  • Menu Mode — how the mode of the marking menu is changed.
    • Anim
    • TD
  • Reset — Clears option vars to ‘reset’ the marking menu
  • Report — Logs the data that is stored to the marking menu. Mainly for dev purposes but may be helpful for others.