mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-03-29 04:20:20 +00:00
added getRotationAngle from rotation matrix
This commit is contained in:
parent
fc5ceb98a9
commit
122fb60270
@ -154,6 +154,10 @@ void getRotationMatrixFromVectors(float vin[3], float vout[3], float matrix[4][4
|
||||
getRotationMatrixFromQuartenion(q,matrix);
|
||||
}
|
||||
|
||||
void getRotationAngle(float matrix[4][4], float angle){
|
||||
angle = acos( (matrix[0][0]+matrix[1][1]+matrix[2][2]-1) * 0.5);
|
||||
}
|
||||
|
||||
#if 0
|
||||
int main(void)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user