I have a 3D animation and special effects compositing background and tend to try to relate concepts in XML to functions in those other disciplines when possible for better comprehension of the concepts. I'm currently trying to "nest", "Link", "parent" an object element (the Child) that has it's own independent movement "inside" another object element (the parent) that has it's own independent movement. The desired result is once the "child" is positioned relative to the "parent", the "child" will inherit the motion of the "parent" in addition to it's own motion, but it's "anchor" or bounding 0,0 point would stay locked in the same relationship to the parent no matter what motion the parents does. Is this type of hierarchical relationship between object elements possible in an XML gauge ?
In 3D and 2D animation graphics this is a very simple process of set the 2 objects at the positional relationship desired, then link them declaring one the parent and one the child. Then the child can do any movement on it's own but will also inherit any movement of the parent maintaining that original positional relationship between them. So in affect all the x,y,z positional values of the child are automatically adjusted to include the movement of the parent to maintain that original positional relationship between them.
In my case I have a pitch ladder (my Parent) and a Heading Tape (my Child).
I have nested and aligned the child element in the parent element. Everything lines up and functions as desired as long as I maintain level flight with some minimal movement, but as soon as I bank, climb, or dive significantly the parent and child objects start to float apart but will come back together once level flight is re-established. The more drastic the movement or more G's the more it just goes to crap.
Below is a simplified version of the "nesting" and movement. What am I doing wrong ?
first, is it possible the setup the Parent/child relationship I described, and if so what is the std procedure for setting that relationship ? BTW in this example i have just included 1 of the 3 heading tape bitmaps and 1 of the 5 ladder bmp's but this ladder map is the one i want to "connect" to.
I tried using just a static BMP as a child but it too will start to "float" away from the parent when the parent moves much.
Thanks
Joel
In 3D and 2D animation graphics this is a very simple process of set the 2 objects at the positional relationship desired, then link them declaring one the parent and one the child. Then the child can do any movement on it's own but will also inherit any movement of the parent maintaining that original positional relationship between them. So in affect all the x,y,z positional values of the child are automatically adjusted to include the movement of the parent to maintain that original positional relationship between them.
In my case I have a pitch ladder (my Parent) and a Heading Tape (my Child).
I have nested and aligned the child element in the parent element. Everything lines up and functions as desired as long as I maintain level flight with some minimal movement, but as soon as I bank, climb, or dive significantly the parent and child objects start to float apart but will come back together once level flight is re-established. The more drastic the movement or more G's the more it just goes to crap.
Below is a simplified version of the "nesting" and movement. What am I doing wrong ?
Code:
<Element>
<Visible>(A:GEAR HANDLE POSITION,percent) 0 ></Visible>
<Element>
<Clip Top="100" Left="105" Right="570" Bottom="650"/>
<Image Name="Pitch_Ladder_25_-25_GDown_00FF00.bmp" Bright="Yes" ImageSizes="272,1680">
<Axis X="329" Y="820"/>
</Image>
//****** Heading Tape Nested******************
<Element>
<Position X="0" Y="-40"/>
<Image Name="Heading_tape_340_140_00FF00.bmp" Bright="Yes" ImageSizes="1742,41">
</Image>
<Shift>
<Value>(A:Plane heading degrees gyro, degrees) dnor</Value>
<Nonlinearity>
<Item Value="0" X="-233" Y="-40"/> // X="98" Y="-40
<Item Value="60" X="-857" Y="-40"/> // X="-526" Y="-40"
<Item Value="120" X="-1481" Y="-40"/> // X="-1150" Y="-40"
</Nonlinearity>
</Shift>
</Element>
// END of nested Heading tape ***********
<Shift>
<Value>(L:ClimbAngle, radians)</Value>
<Nonlinearity>
<Item Value="-1.570795" Y="2747"/>
<Item Value="1.570795" Y="-2747"/>
</Nonlinearity>
</Shift>
<Rotate>
<Value>(A:PLANE BANK DEGREES,radians)</Value>
</Rotate>
<Shift>
<Value>(A:VELOCITY BODY Y, m/s) (A:VELOCITY BODY Z, m/s) atg2 rddg /-/</Value>
<Nonlinearity>
<Item Value="0" Y="287"/>
<Item Value="90" Y="3034"/>
</Nonlinearity>
</Shift>
<Shift>
<Value>(A:VELOCITY BODY X, m/s) (A:VELOCITY BODY Z, m/s) atg2 rddg /-/</Value>
<Nonlinearity>
<Item Value="-90" X="3077"/>
<Item Value="90" X="-2417"/>
</Nonlinearity>
</Shift>
</Element>
first, is it possible the setup the Parent/child relationship I described, and if so what is the std procedure for setting that relationship ? BTW in this example i have just included 1 of the 3 heading tape bitmaps and 1 of the 5 ladder bmp's but this ladder map is the one i want to "connect" to.
I tried using just a static BMP as a child but it too will start to "float" away from the parent when the parent moves much.
Thanks
Joel



