Channel view hpr settings

New Message Reply Date view Thread view Subject view Author view

Scott Herod (herod++at++evt.com)
Fri, 05 Feb 1999 12:56:19 -0700


I realize that rotation matrices don't commute,
but I am a little surprised that heading changes
and roll changes are negatives of each other if I
pitch down by 90 degrees. Try

    switch (count) {
    case 0:
      hpr.set( 20.0f, -90.0f, 0.0f );
      break;
    case 1:
      hpr.set( 0.0f, -90.0f, 20.0f );
      break;
    }
    chan->setView( xyz, hpr );
    pfMatrix mat;
    chan->getViewMat( mat );
    for (int i=0; i<4; i++ ) {
      for (int j=0; j<4; j++ ) {
        printf( "%f ", mat.mat[i][j] );
      }
      printf( "\n" );
    }
    printf( "\n" );
     
Is this typical behavior in 3D systems?

Scott Herod
scott++at++evt.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Fri Feb 05 1999 - 11:56:25 PST

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.