Form and Space

creating CG 3D since 2001

  • Connect @
  • Linked in
  • Vimeo
  • Twitter

Maya 2016 Preferences Post-recording

This version of my Maya 2016 Preferences were created after the completed recording of Introduction to 3D Modeling in Maya, 2nd Edition. The file paths, recent files, recent projects, should all default to your own directories. Please talk to me, mattstoehr@gmail.com, if you have ANY problems with the preferences. The keyboard shortcut changes are the following: Ctrl + d uses my Universal Duplicate, read more about that here. 8 opens the Outliner. [ uses the Modeling Toolkit – Connect. shift + [ uses the Cut Faces Tool. ] uses the Modeling Toolkit – Quad Draw. Shift + ] uses the…

Subdivision Surface Management

Mar. 30, 2016 ver. 0.1 This is useful when importing or referencing a lot of content into a single file, like what I teach in Chapter 9 of Intrduction to 3D Modeling in Maya, 2nd Edition. This will change the subdivision surface attributes for all selected objects. The Attribute Editor doesn’t allow attribute changes for all objects selected, and the Spreadsheet Editor doesn’t list the Smooth Mesh and OpenSubdiv attributes. The solution is a tool that can simply walk though each item in the selection. I’ll refine this more, and add a UI in due time. Edit: The UI is…

MEL: Branch and Branch Clusters

They are yours to use as you wish. The first tool creates a branch-like object based on the length of the curve. Simply draw curves and run the mls_branch MELscript. The second tool is to help speed up the modeling process of the lattice created by the mls_branch script. The instructions are at the top of each bit of code, and are very simple to use.

Maya 2015 Preferences Updated

If you are currently in one of my courses at American River College, or you have bought “3D Character Modeling Volume 1”, then this message is very important. I’ve made a major update to my Maya 2015 preferences to reflect the various tweaks that have been made throughout this semester’s courses. Most of the changes are related to how custom scripts are called into Maya. Each script can now be used an a global script, and you are welcome to continue developing the scripts. You can find the scripts in the /2015-x64/scripts folder. I’ve also included the symmetry and live…

A Tool to Assist With Relaxing A Mesh

This is an excellent addition to my modeling tools. Written by student Chris Talbott. Enjoy! Use this when your modeling organic characters, and you don’t already have a high-res mesh to live model against. I used this technique in class, and Chris compressed the steps into a single click! /********************** Duplicate and make Live Version .03 Author: Chris W.A. Talbott Chris7Talbott@gmail.com Instructions: Select a object you wish to make duplicate and make live run the script. Process: Object will duplicate and rename. New mesh will be made live and hidden in the outliner, Reselects the original mesh you chose to…

A Smarter Symmetrize Mesh Tool

This tool is a “must have” addition to your tools. It’s written by one of my students, Chris Talbott. Enjoy. /*************************************************** Cut a Mesh in half Version .01 Author: Chris W.A. Talbott Chris7Talbott@gmail.com Designed with character and creature modeling as the target use in symmetry. Instructions: Define a target edge loop to define as center and run script. Process: Center will be set on absolute X-value of pivot. The mesh will be cut into 2 pieces along the edge loop chosen. The more -X half will be deleted while +X half will be kept. The remaining half will be mirrored…

Create Named Layers

I needed this today to make a lot of layers from a selection. Select objects and run this global script, and get layers for each selection. If the selection has children, they are added to the parents layer. See the comments for more info. global proc mls_makeNamedLayer() { string $sel[] = `ls -sl`; int $cnt = size($sel); if($cnt < 1) { error "Select object(s) first."; } for($i=0; $i

Modeling Script

This script combines objects into one mesh, merges all vertices within 0.001 tolerance, and softens the vertex normals. It’s useful when cutting apart objects often, like when symmetry modeling. /********************** Symmetrize Mesh Version .01 Author: Matthew L. Stoehr mattstoehr@gmail.com Symmetrizes a mesh that has already been cut in half on the X axis. Designed with character modeling as the target use. ***********************/ global proc mls_symmetrizeMesh() { string $object[] = `ls -sl`; int $cnt = size($object); if($cnt > 1) { error “Select only one polymesh objects.”; } string $inst[] = `instance -n $object`; xform -ws -scale -1 1 1 $inst[0]; polyUnite…

MEL: Replace Add Randomize

Honorable Mention:  http://lesterbanks.com/2013/11/maya-randomly-replace-and-add-objects-in-mel/ Updated May 1, 2014 This script now matches pivot location. In other words, if you move the pivot point of the source object and/or the pivot point of the target, this script will match source pivot point to target pivot point. This should make it even easier for the artist to craft complex scenes with the pivot points as their constant value. This is included with my Maya 2015 preferences. Updated March 24, 2014. Now you can download them as global mel scripts, and add them to your scripts folder in your preferences. Also, add it as…

Mirror Instance On X

Here’s a very simple yet handy tool. I was tired of digging in the menus to simply mirror an object as an instance, so I wrote this little thing. I’ll share more of what I’m making as I get closer to completion. For now you can enjoy the back side of the character. I have hair guides, clothing, jewelery, and other bits and pieces to create that requires mirror each time. This tool speeds up the process, and took a mere two minutes to write. /********************** Mirror Instance On X Version .01 Author: Matthew L. Stoehr mattstoehr@gmail.com Mirrors an object…

MEL: Path Constraint v.0.7 with Looping

Path Constraint version 0.7 is here already! This version came a little early, but it’s too good not to share. It was only a few days ago, March 7th, when I released the version 0.6 of the Path Constraint tool. I shared it on the Maya forums at CGSociety.org when a user named Farcue asked me to add looping functions for complex curves. Farcue asks: If I had a complex path ––say, a helical path bent in a circle and made periodic–– how would I go about animating objects attached to it via your script so that they moved around…

MEL: Path Constraint ver.0.6

This is my third public release of the Path Constraint tool I’ve been developing for a little over a year. It has gone through a number of revisions, and is now at ver. 0.6. The former tool can be found here, and you can see significant changes have been made to the path constraint. The biggest change is the use of more expressions to drive the offset, start, end, scale, taper, and twist of the objects along the path. Also, there is an up axis for all objects and uniform rotation for all objects. When you run the tool you’ll…

MEL: Booleans

Like I’ve said in class, booleans are rarely taught for a few reasons, and there’s even a piece of literature in my library about digital modeling with a chapter titled, “Booleans Are Evil”. Well, for a long time, I thought that too, but not because I couldn’t use them, or that other artists shouldn’t use them, but because it’s difficult to explain there use. There are problems that arise when using booleans, but with a little foresight, edge loop planning, the boolean can be very powerful and assist with very complex geometric problems. Traditionally a boolean modeling operation is between…

Maya MEL: Find Surface Point

This covers how to collect the UV data in MELscript by selecting a surface point of a NURBS surface. Monday night I was inspired to add a feature to the way I create “hair” or hair guides; widely known as strands. After demonstrating the most recent version of my strand tool, Jeremiah asked me if it’s possible to find a point on a surface, and generate a strand from that point. He explained it would give a more sculptural, artists, approach to designing hair or other complex organic structures. Basically, where I click is where my strand appears. My approach…

Maya: Neutral Pose Revisited

I’ve been working on improvements of this. Previously, I attempted to make a tool that would create a neutral pose. It wasn’t very good. What I want to do is set the current selections transformations to 0,0,0 0,0,0 1,1,1 for translation, rotation, and scale. Why do this? Well, it makes it easier to reset an object to it’s default pose when animating. All I need to do is enter zeros and ones into the transformations, respectively. Of course, the motivation behind this tool comes from my experience in rigging characters in XSI. There’s a very nice, easy to use, Save…

MEL: Duplicating and Transforming Revisited

This tool will duplicate a single object and move it to multiple locations of a multi-selection. It could easily be modified to do other jobs, like replace all selected objects with instances. I’ve been researching Maya MEL script more and more. I’ve been inspired lately, by a few projects and art going on around me, to tighten up my MEL. I’ve revisited the duplicate and transform tool. It’s now more efficient, does not use “select”, and uses the -matrix flag of the xform command. This makes a very succinct script and it is much faster. Lately, I’ve been reading the…

Maya: Duplicate and Match Transforms

Here’s a duplicate and match transforms script. Right at the end of class today someone was asking for a way to replace their stack of cups with a newly textured cup. I came up with this. He’ll still need to delete or hide the old cups, but this will match the cups transforms and preserve the inputs for each cup. Note: there are far better methods I’ve created since this was posted. Search for Matching and Neutral pose scripts for more information. /* Duplicate and Match Transforms version .01 Sept. 7, 2012 Author: Matthew L. Stoehr Source: formandspace.com Objective: Duplicate…

Maya: Universal Duplicate

The duplicate tool in Softimage is brilliant. No matter what you select, it will be duplicated relative to the object type. I want that in Maya, or at least some of it. So I wrote this tonight. It’s a start. It will work well in modeling processes. I remapped this script to the ctrl+d, replacing the default tool in Maya. More at cgtalk.com /************************************************ Universal Duplicate version 0.2 Author: Matthew L. Stoehr Source: formandspace.com Objective: Create a duplicate tool that can be universally used for all objects and components. Currently this tool can: if the selection is a polygon, point,…

Maya: Locators to CVs Script

Here’s a very useful tool for animating or sculpting a curve(s) shape. I’m in the middle of finishing my training recording on making grapes, and I was in need of a tool like this. It’s all yours. /************** Locators to CVs version 0.4 Author: Matthew L. Stoehr formandspace.com mattstoehr@gmail.com updated Feb. 04, 2013 Creates a locator at each CV to animate or sculpt the curve shape. Select curve(s), then run. ****************************/ mls_nullsToCVs(); proc string[] mls_nullsToCVs() { string $sel[] = `ls -selection`; string $nulls[]; for($node in $sel) { select ($node + “.cv[*]”); string $cvs[] = `filterExpand -sm 28 -fullPath true`; int…

Maya: Simple 3D Array

For those of you starting out, here’s a simple array script to create instances of a primitive. You should be able to build onto this script very easily. Play with the numbers, and see how far you can push it. Soon, I’ll modify it so it arrays your selection. I’m working on a ring mail script, and this is a fundamental part of making ring mail. mls_f3DArray(3, 1.0); proc mls_f3DArray(int $objCount, float $oSp) { int $n = 0; string $cube[] = `polyCube -ax 0 1 0`; BevelPolygon; //1D, X for($i = 0; $i < $objCount; $i++) { //2D, Y for($j...

Maya: Neutral Pose

Use this script to create a neutral pose, sort of. For example, say you had a model robot, and you have already set the pivot point for each part. This will take the pivot, and create a group at the pivot location. The group is translation 0,0,0 rotation 0,0,0 and scale 1,1,1. Effectively, a neutral pose. mls_neutralPose(); proc mls_neutralPose() { string $oSelection[] = `ls -sl`; int $oCount = size($oSelection); for ($i = 0; $i < $oCount; $i++){ select -r $oSelection[$i]; //get the pivot location of the selection vector $v1 = `xform -q -t`; vector $v2 = `xform -q -sp`; vector...

Maya: Path Constraint v0.2

This path constraint script is developed from my former multi-motion path script. It’s more developed, and is simpler for the user. To use it, select all the objects you’d like to path constrain, and then select the curve last. Run the tool. The order of your selection is the order along the path. Each object will be grouped, and the group will be path constrained using a standard motion path. The user’s objects can be transformed, while maintaining it’s connection to the path via the parent group. It’s simple rigging principles. 🙂 You can then edit the curve, and each…

Inherited Transformation

Here’s a simple script for creating a long chain of parented objects. Create a bunch of cubes in one place, select then all in the viewport, and run this script. Marquee select them all again, and transform the objects to see the effect. This takes advantage of inherited transformation. mls_inheretTransform(); proc mls_inheretTransform() { string $null[] = `ls -tr -sl`; int $n = size($null); for($i = 0; $i < $n; $i++){ if($i != $n-1){ parent $null[$i] $null[$i+1]; } } } /************** end *********************/

Multiple Motion Paths

Here’s a tool for Maya that is similar to a multi-path constraint in Softimage, multi motion paths. Make a new scene, create a curve, create a few objects to attach to the curve, select the objects, and run the script below. string $selection[] = `ls -selection`; int $size = size($selection); //change this to your curve name string $path = “curve1”; for($i=0; $i

Iterated Space Transformation

One of my classroom assignments is to model a spiraling staircase, or iterated transform of objects. I find this assignment to be very exciting, as it introduces my students to modeling with multi-dimensional arrays. Then my one of my students, Casey, found a reference on Google images that I hadn’t seen before. A sculpture by Peter Coffin at the Saatchi Gallery. Untitled (Spiral Staircase) 2007 Aluminum and steel 670.6 x 670.6 x 213.4 cm Peter Coffin Now, this is interesting, and it peaked my curiosity to try and recreate it in Maya. Start with a radial array.  A radial array…