Forum: Poser Technical


Subject: More Poser secrets revealed - Don't read...

VK opened this issue on Oct 27, 2003 ยท 33 posts


VK posted Mon, 27 October 2003 at 10:11 AM

This post isn't an explanation, but a warning of a potential pitfall. The track model shown is made of many track elements, which move along the track shape. It's not very obvious, but the elements need two slightly different origins, to travel properly along the rollers (radius R1 is 0.17362, radius R2 is 0.16982). This track model needs more consideration, because the elements have a specific default orientation. Some of the elements are neither vertically nor horizontally oriented. The variable origin method works for models, which rotate around the main axes of the Poser scene. The "local coordinates" and the "world coordinates" should be aligned. You can easily rotate the local coordinates in relation to the world coordinates, when you set "Orientation" angles in the Joint Editor, or modify the "orientation" data stored in the code. If you modify the default orientation (use "Orientation" angles other than zero), the variable origin will not work. So, if your model really requires special default orientations, you can't use this technique to create variable origins. Whenever your model will work at default orientation, don't modify the default orientation. In the track example, you should not modify the default orientation of the elements, although this might appear to be useful. The above code is a basic variant of the method. It works for simple models like the arrow prop. When you develop variable origins for the track elements, or for the links of a bike chain, you need to adjust the code due to the odd default orientation of some elements. The CenterA translation of such element is always a motion vector of two components (a yCenterA and a zCenterA channel in this case). Thus, the CenterB reset translation also consists of two channels, even if there was no preexisting rotation. Since each element has its own preexisting rotation, when you switch origins, the CenterB reset motion of each element should also compensate for a different phantom motion. You don't need additional CenterB channels, but different formulas to calculate the reset motions.