January 14, 2007 Justin Chin

Posing Rig “Hack” For SU (More)

INTRODUCTION:
I talked about this in previous post (http://www.infinitemachine.com/homepage/archives/361). I wanted to go into this a little further with an example rig.

In short this is a posing rig hack that I patched together using the SketchUp Pro 5 tool set. It’s nothing new, and in fact this was how it was done in the old days. If you haven’t heard of SketchUp, then this will make absolutely no sense to you.

THE PROBLEM:
SketchUp is a powerful and unique visual modeling program, but it does not have tools to rig characters or objects for pose manipulation.

SOLUTION:
Using SketchUp’s current tool set; Groups, Outliner, Layers, and Pages, you can create a simple posing rig.

Some notes:

  • This technique is only for rigid body posing.

  • The rig is purely hierarchical and does not have inverse kinematics.

  • This paper explains a method using SketchUp Pro 5.

  • This paper is not a walkthrough, but an explanation of the method.

DETAILS:
Before We Begin

For this paper I created a finished rigged up example, PickUp_Rig.skp (download). Use the example model to get a glimpse of the method discussed here.

In order to create a posing rig for SketchUp you will need to have some understanding as to how Groups and the Outliner work in the program. In addition, part of the technique involves some work flow concepts, and requires additional understanding as to how Layers and Pages work in SketchUp. If you do not understand these features I highly suggest that you use the video tutorials on the SketchUp website to learn about them before you read on.

The Posing Rig
The posing rig is built up out of standard geometry created from the typical set of SketchUp tools.

Here is a picture of the PickUp_Rig.skp rig and model side by side:

Posing_Detail.jpg

The posing rig is intended to be simple geometry that renders fast in real time. Typically when you are working on a scene you will only have the posing rig geometry visible, for rendering and ease of manipulation purposes. The detailed geometry will be hidden from view. The posing rig is made up of separate pieces of geometry that represent the items you wish to manipulate in that model.

A good rule of thumb is to create your detailed geometry first, then create your rig geometry afterwards. Obviously this allows you accurately portray your rig geometry in relationship to the detailed geometry.
The posing geometry should represent the needs you might have for that model. In the case of this pickup, I made the geometry for the wheels slightly rounded at the bottom. This was so I could have an understanding as how the wheels are contacting the ground when I pose it.

You should also create your detailed geometry and your rig geometry both in a matching basic pose. This will make combing them and understanding their relationship to each other clear and representative of their positioning.

Registration Handles
If you look closely you can see that the posing rig has checker coloring all over it.  We’ll call them registration handles. Using these registration handles allow you easy manipulation of the posing rig and take advantage of the unique inferencing features of the SketchUp toolset.

Wheel_Axis_.jpg  Wheel_Rotation_.jpg

You will want to design your registration handles that best represents how you want your object to rotate or move. Using the front right wheel as an example I created the rig geometry in a way that would allow me to turn the wheel in the vertical axis to represent steering under normal conditions, left or right.

You can also see that the top of the right and left front wheels posing geometry I created a tall portion of the wheel that sticks out through the hood of the pickup. This is a functionality trick that will allow me to turn the wheels without hiding the body that would normally surround the wheel. You should design your rig geometry that allows you the best selection of that registration handle from most angles, or at least from most angles that you’ll be working with.

Case and point; I didn’t put registration points at the bottom of the wheels, where they would normally contact the ground. I normally wouldn’t work from underneath the ground plane so a registration handle at the bottom of the wheel would be needless. You can add them if you prefer. Do what works best for your needs.

The Moving Parts
In this example I created a rig that has these moving parts:

 > Body
> Front Wheel Left
> Front Wheel Right
> Front Axle
> Rear Axle

Shapes.jpg

You could add more pieces to this rig if you want, i.e. doors, hood etc. but for the purpose of this explanation I’ll cover just these 5 items.

When all the parts I want are built I create a Layer in SketchUp called //PICKUP RIG. This is a work-flow element that will allow me to visually turn off and on the posing rig as I work on my scene. I select all the posing geometry (ungrouped for now) and add that geometry to the //PICKUP RIG Layer in the Entity Info window.

Once the posing rig geometry is associated with the //PICKUP RIG Layer I can then start creating groups for each individual part. In this example they are (with respect to the list above):

 > CN_Body
> CN_Front_L_wheel
> CN_Front_R_wheel
> CN_Front_Axle
> CN_Rear_Axle

The “CN_” in the name means control node. This naming convention allows me to easily spot the rig geometry in the Outliner. This is important when you are manipulating a large complex model or a large scene.

Tip: By typing in, “CN” in the filter slot in the Outliner you can filter out all the other items and just show the control nodes.

The Parent Child Hierarchy
Now this is where the fun starts.

Using the Outliner I start to arrange the posing geometry groups in relationship to each other based on how they will move. For this example I arranged them in this manner:

 > CN_Body
> CN_Front_Axle
> CN_Front_L_wheel
> CN_Front_R_wheel
> CN_Rear_Axle

So in the above example hierarchy; CN_Front_L_wheel and CN_Front_R_wheel are children to the parent, CN_Front_Axle. This means that if I move CN_Front_Axle, the two front wheels will move with it. On a car that’s what I want, because the two wheels (in normal operation) will always be attached to the axle.

Once this is done I select all the Groups above and Group them as one and name it, PICKUP. The Outliner will look like this:

 > PICKUP
> CN_Body
> CN_Front_Axle
> CN_Front_L_wheel
> CN_Front_R_wheel
> CN_Rear_Axle

The Pickup Group is now a parent to all of the moving parts below it. This allows me to move the PICKUP (parent) anywhere in the scene and all the parts moving parts (children) intact and in their relative position. You will notice that this also allows me to move the body of pickup (CN_Body) separately from the axles and wheels. This is desirable because when a car turns, the chassis and body has a tendency to lean.

And that’s the basics of the rig!

Adding Your Detailed Geometry To The Rig
The next step is to combine the detailed geometry with the rig hierarchy explained above.

Again the assumption is that you’ve created your detailed geometry before you made your rig geometry. Here are some rules to creating your detailed geometry for rigging purposes:

  • All your base detailed geometry (ungrouped) should be created and associated with Layer0.

  • All your detailed parts should be grouped in some manner for easy selection and sorting in the outliner. Geometry that hasn’t been grouped or made into a component does not show up in the Outliner and may not work with the work-flow explained later.

  • I assign all the detailed model groups to a separate layer or layers. In the example that layer is, “Pickup Model.” By hiding that single layer you will hide the entire detailed model. Very useful.

The example model has the exact number of detailed model groups as the rig groups to make it easier to visualize. Those detailed geometry groups are named like this:

 > Body
> Front Wheel Left
> Front Wheel Right
> Front Axle
> Rear Axle

At this point in the process, working exclusively in the Outliner I start moving the detailed geometry groups under where they would belong in the hierarchy. In most other models you would have many more groups and or components.

Here is the end result for this example:

 > PICKUP
> CN_Body
> Body
> CN_Front_Axle
> CN_Front_L_wheel
> Front Wheel Left
> CN_Front_R_wheel
> Front Wheel Right
> Front Axle
> CN_Rear_Axle
> Rear Axle

This hierarchy then allows me to select CN_Front_L_wheel and turn it and thus the detailed geometry turning with it.

This is now a fully pose-able rig and detailed model.

POSING WORK-FLOW
In order to help explain my workflow, download file, PickUp_Rig_Scene.skp (download).
In the example file, take note of the two Layers:

  • // PICKUP RIG – This layer, as explained, above represents all the posing rig geometry.

  • Pickup Model – This is the detailed geometry that is the “child” of the posing rig. Any movement that you make in the posing rig will affect this layer.

The real benefit of having these layers is arrived when you link them up to the Page system. My work-flow uses the Page system in SketchUp to allow me to toggle between the posing rig and the detailed model within my desired camera view.

SceneView_Rig.jpg  SceneView_Model.jpg

If you open up the Page Window you will notice that I have 3 pages set up. These are:

  • // RIG VIEW – This page only displays the //PICKUP RIG layer and the terrain that the vehicle is on. This view has the Camera property turned off. This is because I will use the Scene View page and this page together to switch from the Model View. When I do this I don’t want to camera to change from the Scene View.

  • MODEL VIEW – This page displays the detailed model as well as the terrain. This also has the Camera property turned off, for the same reasons stated above.

  • SCENE VIEW – This page represents the camera angle that I want for my scene. This view has the Layers property turned off.

Most of the other properties for the pages can be turned off or on depending on your preference. But the properties shown above (in bold) are the important ones to set for the work flow.

I usually set up my camera how I want it and create a page to represent that camera angle (SCENE VIEW). Then I will set up my scene with the objects I need.

Setting up the //RIG VIEW and the MODEL VIEW pages are important at this point. When creating these pages I’ll tick the proper layers that I want shown, i.e. in the //RIG VIEW I’ll show all the rig layers and hide all the detailed geometry layers. For the MODEL VIEW page I’ll hide all the rig layers and show all the detailed geometry layers.

Now I can snap to the SCENE VIEW and toggle the types of geometry I want to see by clicking on the other pages. I can now manipulate the scene using the //RIG VIEW, orbiting and moving around the scene to tweak whatever handles I need to, then check my changes with by clicking on the SCENE VIEW page, and clicking the MODEL VIEW page to check the how the detailed model is posed.

Simple as pie.

Useful Links: