Modifying Texture Projections

This section describes various ways of editing a texture projection — some interactive and others using the projection’s property editor.

Editing Texture Projection Properties

A texture projection’s property editor contains options for, among other things, modifying, transforming and renaming the projection.

To edit texture projection properties

• Select the object(s) whose projection you wish to edit, and choose one of the following from the Render toolbar:

- Modify > Projection > Inspect Current UV opens the property editor for the object’s current texture projection. This is the projection used when the object is viewed in a textured display mode (textured, textured decal, and so on).

If you selected more than one object, a multi-selection property editor opens, allowing you to set properties for all of the objects’ current texture projections.

You can change the current projection from the object’s Material property editor, as described in Image Clip OGL Display Settings.

or

- Modify > Projection > Inspect All UVs opens a multi-selection property editor for all of the object’s texture projections.

If you selected more than one object, the property editor affects all texture projections belonging to all selected objects.

• Choose Modify > Texture > name of the texture from the Render toolbar to open the texture’s property editor.

Click the Edit button on the Texture tab (beside the Texture Projection list) to open the Texture Projection property editor.

Transforming Texture Projections

By default, a texture projection fills the entire support. For example, if you apply a simple XZ Planar projection to a grid, the texture coordinates span the entire projection from one grid corner to the other. You can transform the texture projection to reposition the texture, or to make room on the support for other projections in different locations (see Adding a Texture Projection to a Texture Support).

 

 

There are two ways to transform texture projections—using the projection manipulator in a 3D view, or by editing the scaling, rotation, and translation values in the Texture Projection property editor.

 

Changes that you make to the texture projection using the projection manipulator (press j) carry over into the Texture Projection property editor, and vice versa.

To transform texture projections in a 3D view

1. Select the texture support object to which the projection is attached.

2. Do one of the following:

- Press j to activate the texture coordinates.

or

- Choose Modify > Projection > Edit Projection Tool from the Render toolbar.

In the 3D views, the texture projection is displayed on the texture support. It is represented by a yellow bounding-box with handles.

3. In a 3D view, drag the projection’s handles to adjust the texture’s scale and position, as shown in the following image.

 

To transform texture projections using the Texture Projection property editor

1. Edit the texture projection that you wish to transform, as described in Editing Texture Projection Properties.

2. From the Texture Projection Definition page, you can scale, rotate, or translate the projection. You can also mark and animate the transform parameters.

 

The Scale, Rotate, and Translate options use the upper-left corner of the picture file as a reference point to scale and offset instead of the texture’s “center.”

Fitting Texture Projections to Components

Rather than manually transforming a texture projection to fit over a specific area of an object, you can fit the texture projection to a selection of the object’s components using the Fit Subcomponent UVs to Image tool. This tool automatically calculates and performs the necessary transformations (scaling, transformation, and rotation) to position the texture projection over the selected components. If necessary, you can then refine the projection’s placement interactively in a 3D view or from the property editor, as described [here].

Textured Decal View

 

Rendered Result

 

The original coffee mug shown here is a little too plain. You decide to put a snazzy logo on the side.

 

 

Adding the logo texture to the object (as described in Adding More Textures) using a cylindrical projection produces the result shown here. Though interesting, it’s not what you want.

 

 

Fitting the texture to a selection of polygons automatically transforms (scales, translates, and rotates) the projection to fit precisely over the selected polygons. Ah, just right!

 

To fit a texture projection to a selection of components

1. Edit the texture projection that you wish to fit to an object’s components, as described in Editing Texture Projection Properties.

 

You may want to click the lock button in the property editor’s title bar. This ensures that the property editor stays open and remains focused on the texture projection in the following steps.

2. Do one of the following:

- From the Texture Projection page of the Texture Projection property editor, click the Fit Subcomponent UVs to Image button. A pick session begins.

In any 3D view, select the components to which you want to fit the texture projection, and then right-click an empty area of the 3D view to end the pick session.

or

- In any 3D view, select the components to which you want to fit the texture projection.

Then click the Fit Subcomponent UVs to Image button in the Texture Projection property editor.

3. The texture projection is transformed to fit precisely over the selected components.

Freezing Texture Projection Transformations

Once you have transformed a texture projection, as described [here], or fit it to a selection of components, as described in the previous section, you can “freeze” the transformation into the texture’s final UV coordinates. You can then edit the texture in the texture editor.

When you freeze UVW transformations, three things happen:

• The object’s UV coordinates are modified to match the projection’s transformation.

• The ClsSetValuesOp operator is created in the texture operator stack (see [here]).

• The texture projection’s UVW transformation values are reset to their defaults (scaling = 1,1,1; rotation = 0,0,0; translation = 0,0,0).

 

Freezing texture projection transformations is particularly useful in game development because it allows you to export all of the texture information to your game engine as part of the final UV coordinates without having to export additional information about projection transformations.

For more information about editing UV coordinates in the texture editor, see Working with UVs in the Texture Editor.

To freeze texture projection transformations

1. Edit the texture projection that you wish to freeze, as described in Editing Texture Projection Properties.

 

You can also open the Texture Projection Definition property editor directly from the explorer by clicking on its icon, which is located under the object’s Clusters node.

 

2. In the UVW transformation section, click the Freeze button.

The transformation is “frozen” into the object’s UV coordinates and the UVW transformations reset to their default values.

Removing a Texture Projection Transformation Freeze

There are two ways to “unfreeze” a projection’s UVW transformations: you can either undo the freeze, or remove it entirely by deleting the ClsSetValuesOp operator. But be careful! Deleting the operator unfreezes the texture projection, but also destroys its UVW transformations. As a general rule:

• You should delete the ClsSetValuesOp operator only if you want to redo the texture projection transformation from scratch or if you decide not to freeze the transformation after all.

 

• You should undo the freeze when you want to get back to the unfrozen transformation.

Wrapping Texture Projections

The texture projection’s wrapping options control whether the texture extends past the projection’s boundaries to wrap around the object.

 

 

When you set the wrapping options in the texture projection property editor, the result is only visible in a rendered image. To get a texture to wrap when you display it in a 3D view, you need to set its clamp/repeat options in the object’s Material node property editor. This is described in Texture Clamping or Repeating.

To wrap a texture

1. Edit the projection whose texture you wish to wrap, as described in Editing Texture Projection Properties.

2. In the Wrapping, check the appropriate check boxes to wrap the texture in U, V, and/or Z.

Renaming Texture Projections

Although renaming a texture projection is an easy task, it can seem complicated when you are using the projection to drive several different elements. For example, you can use a single projection to drive textures, shaders, and rendermaps.

Fortunately, it’s easy to update all of these references automatically when you rename the projection. You can specify if and how the references are updated.

To rename a texture projection

1. Edit the texture projection that you wish to rename, as described in Editing Texture Projection Properties.

2. Click the Rename button in the Texture Projection page. The Rename Texture Projection dialog box opens.

 

You can also open the Rename Texture Projection dialog box by selecting the projection’s node in the explorer and pressing F2.

 

3. Enter the new name for the projection in the New Name text box.

Spaces and other illegal characters are automatically converted to underscores. If the name already exists, a number is automatically appended to preserve uniqueness.

4. Use the following options to control how references to the projection are updated:

- Update references to the property searches for shaders, render maps, texture maps, and materials that refer to the old name of the property explicitly (that is, without using wildcards), and updates them to use the new name.

- Update references containing wildcards searches for property references containing wildcards that resolve to the old name, and tests whether they still resolve to the new name. If they do not resolve to the new name, the references are updated.

For example, suppose you are using a naming convention such as skin_objectname for your texture maps, and using the wildcard expression skin_* to match it in shader trees. If you change the name of the texture map skin_belly to skin_abdomen, the wildcard expression still matches the new name so the reference is not changed. If you change the name of the map to tummy_skin, the wildcard expression does not match so the reference is updated.

5. Click OK to close the dialog box, rename the texture projection, and update the references.

6. Repeat this process to add as many objects to the projection as you wish.

Muting and Freezing Texture Projections

Once you have scaled, rotated, or translated a texture projection to your liking, you can freeze it permanently or mute it temporarily. Freezing a texture projection is the equivalent of freezing the texturing operator stack. This is useful if you want to avoid accidentally editing or moving your texture support, especially when the object is animated.

To mute a texture projection

1. From any 3D view, select an object whose texture projection you wish to temporarily freeze.

2. From the Select panel, click Selection. In the explorer that opens, locate the TextureOp node (under the Texture Projection Definition node) and click it to open the Texture Op property editor.

 

3. Select the Mute option to mute (temporarily freeze) the texture support.

 

Muted texture projections don’t always save vertex information when a scene is saved. You may need to re-edit the texture support once you reload the scene.

To freeze a texture projection

1. From any 3D view, select an object whose texture projection you wish to freeze.

2. From the Select panel, click Selection. In the explorer that opens, select the TextureOp node.

3. Do one of the following:

- Right-click the node and choose Freeze from the menu.

or

- Click the Freeze button in the Edit panel to permanently freeze the texture’s position and scaling.

Managing Frozen Projections Seams

When you freeze a texture projection, its seam parameters (SeamU and SeamV) become available in the Texture Projection property editor. These are useful for fixing old scenes where artifacts might appear at the objects’ seams.

For example, a cylindrical projection has a seam in the U direction. When you freeze the projection, the cylindrical texture support disappears, but the SeamU parameter is automatically activated, allowing Softimage to keep track of where the projection’s seam is.

When you open a scene created in an older version of Softimage, your frozen texture projections will have both of these parameters inactive by default. Activate the correct seam for the projection.

To enable texture projection seams

1. Select the object whose projection’s seams you want to edit.

2. From the Render toolbar, choose Modify > Texture > Name of Texture. The texture’s property editor opens.

3. Click the Edit button on the Texture tab (beside the Texture Projection list) to open the Texture Projection property editor.

4. Enable the Seam U or Seam V parameter, depending on which is appropriate to the texture projection.



Autodesk Softimage v.7.5