|Anonymous | Login||2021-06-13 05:11 MSK|
|My View | View Issues | Change Log | Roadmap|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0025946||Community||[OCCT] OCCT:Coding||public||2015-03-16 14:24||2016-03-29 17:35|
|Priority||normal||Severity||just a question|
|Target Version||[OCCT] 7.0.0||Fixed in Version||[OCCT] 7.0.0|
|Summary||0025946: extrinsic Euler conventions in gp_Quaternion|
|Description||According to the English Wikipedia the relation between extrinsic and intrinsic Euler conventions is as follows:|
> Any extrinsic rotation is equivalent to an intrinsic rotation by the same angles but with inverted order of elemental rotations, and vice-versa.
When I set a quaternion using gp_Intrinsic_ZYX and extract the Euler angles for gp_Extrinsic_ZYX i get the same angles but in the reverse order. (I would expect totally different numbers)
But from my understanding of the wikipedia page i would expect that gp_Intrinsic_ZYX would return the same numbers as gp_Extrinsic_XYZ, which isn't case.
If my understanding is correct, then there is a bug in the current implementation and the first axis and the odd flag need to be adjusted for extrinsic Euler conventions.
|Steps To Reproduce|
gp_Quaternion q; Standard_Real alpha,beta,gamma; q.Set(0.06766916507860499, 0.21848101129786085, 0.11994599260380681,0.9660744746954637); q.GetEulerAngles(gp_Intrinsic_ZYX, alpha,beta, gamma); std::cout << "Intrinsic_ZYX: " << alpha / M_PI * 180.0 << "," << beta / M_PI * 180.0 << "," << gamma / M_PI * 180.0 << std::endl; q.GetEulerAngles(gp_Extrinsic_XYZ, alpha,beta,gamma); std::cout << "Extrinsic_XYZ: " << alpha / M_PI * 180.0 << "," << beta / M_PI * 180.0 << "," << gamma / M_PI * 180.0 << std::endl;
|Tags||No tags attached.|
|Test case number|
|Attached Files|| CR25946.gitbundle (717 bytes) 2015-03-16 16:47|
CR25946_2.gitbundle (743 bytes) 2015-03-19 23:53
|The error will only show Tait–Bryan angle conventions (three different axes). For the pure Euler angle conventions the behavior should be correct.|
edited on: 2015-03-19 23:56
I attached a reworked commit to include a fix for 0025574. The order of the angles has to be reversed for the extrinsic cases.
$ git fetch CR25946_2.gitbundle CR25946:CR25946
Sorry for long time passed since the issue registration. The fix is now available, as patch for 0025574 (see branch CR25574_4).
Note that by our analysis we concluded that extrinsic sequences were OK, and intrinsic are the ones to be corrected. This is opposite to what you proposed in your fix, thus I suggest you to check this point (if you are still using this functionality). In the case if you believe your fix was correct one, please give your arguments.
|2015-03-16 14:24||shoogen||New Issue|
|2015-03-16 14:24||shoogen||Assigned To||=> kgv|
|2015-03-16 14:34||shoogen||Note Added: 0038393|
|2015-03-16 16:47||shoogen||File Added: CR25946.gitbundle|
|2015-03-16 16:51||shoogen||Note Added: 0038402|
|2015-03-19 22:05||kgv||Relationship added||related to 0025574|
|2015-03-19 23:53||shoogen||File Added: CR25946_2.gitbundle|
|2015-03-19 23:56||shoogen||Note Edited: 0038402||View Revisions|
|2015-03-23 09:27||kgv||Assigned To||kgv => abv|
|2015-03-23 09:27||kgv||Target Version||=> 6.9.0|
|2015-05-06 13:48||abv||Target Version||6.9.0 => 7.0.0|
|2016-01-22 14:19||abv||Note Added: 0050051|
|2016-01-22 14:19||abv||Assigned To||abv => shoogen|
|2016-01-22 14:19||abv||Status||new => feedback|
|2016-03-29 17:35||abv||Status||feedback => closed|
|2016-03-29 17:35||abv||Resolution||open => fixed|
|2016-03-29 17:35||abv||Fixed in Version||=> 7.0.0|
|Copyright © 2000 - 2021 MantisBT Team|