This is a child page. You can use Parent in the quick nav bar at the top or the bottom of the page to navigate directly back to the parent of this page. Some child pages are more than one level deep, and in that case will require more than one Parent click to reach the outermost document level.

§ 16.90.5.29 - normalize (SceneScript element)

 <normalize

This is a shortcut language element that is exactly equivalent to:

 <scale 1 1 1  <rotate 0 0 0  <translate 0 0 0

A commonly encountered scenario is to build an object centered around zero, and then scale, rotate and translate it away. In order to build the next object around zero, a convenient method is to use  <normalize.

 Note:

You might also want to look at the stacking commands for another way to control these and other elements of the environment:  <stack and  <unstack.

For instance, we provide a library file that contains a fair number of triangles that define a cut gem as a unit. These are defined around zero, so that once placed in the scene file, they may be placed anywhere using  <rotate,  <scale and  <translate. Once this is done,  <normalize resets the language for the next such definition. Here's how that looks:

 <apply "diamond"  <rotate -45 0 0  <scale .5 .5 .5  <translate 1 3 0  <color 1 1 1  <structure  <lib "dia8.w3d"  </structure  <normalize

Now, you don't have to use  <normalize, as setting all three of the above mentioned language elements to new, reasonable values prior to a objects being defined will have the desired result, but many times you won't be rotating, or scaling, etc., and then using  <normalize will be very convenient. We like to use it after every object definition, just so we know where we are when we start...

Keyboard Navigation
, Previous Page . Next Page t TOC i Index o Operators g Glossary
WinImages F/x, Morph and all associated documentation
Copyright © 1992-2007 Black Belt Systems ALL RIGHTS RESERVED Under the Pan-American Conventions
WinImages F/x Manual Version 7, Revision 6, Level A

Valid HTML 4.01 Loose
 

This manual was generated with wtfm
wtfm uses aa_macro and SqLite
aa_macro uses python 2.7
Page 201
box