GGEMS Community

General Category => Geometry, Material & Navigation => Topic started by: mwj12 on Jan 23, 2026, 06:30 PM

Title: Are detector rotations applied before or after detector translations?
Post by: mwj12 on Jan 23, 2026, 06:30 PM
Does anyone have the exact formula for the location (in world coordinates) of the center of a flat CT detector as a function of its 8 pose parameters (rx,ry,rz,tx,ty,tz,SDD,SID)

cbct_system = GGEMSCTSystem('detector')
cbct_system.set_ct_type('flat')
cbct_system.set_source_detector_distance(SDD)
cbct_system.set_source_isocenter_distance(SID)
cbct_system.set_rotation(  rx,ry,rz)
cbct_system.set_global_system_position(tx,ty,tz);

I am trying to position a CBCT detector perpendicular to the world y-axis and with a translational offset of -160 mm along the world x-axis. I am having difficulty doing this, partly because I am not sure in what order the translations and rotations are executed. The transformation might have the form,

B = Rz*Ry*Rx * ( A - [tx;ty;tz ])

or it might be,

B = Rz*Ry*Rx*A - [tx;ty;tz]


Here is what I have done currently:


detectorNavigator_1 = GGEMSCTSystem('L1')
detectorNavigator_1.set_ct_type('flat')
detectorNavigator_1.set_number_of_modules(1, 1)
detectorNavigator_1.set_number_of_detection_elements(191, 255, 1)
detectorNavigator_1.set_size_of_detection_elements(1.5520, 1.5520, 0.7000, 'mm')
detectorNavigator_1.set_material('CsI')
detectorNavigator_1.set_source_isocenter_distance(1000.0, 'mm')
detectorNavigator_1.set_source_detector_distance(1500.0, 'mm')
detectorNavigator_1.set_global_system_position(-160.0, 0.0, 0.0, 'mm')
detectorNavigator_1.set_rotation(0.0, 0.0, 90.0, 'deg')
detectorNavigator_1.set_threshold(20.0, 'keV')
detectorNavigator_1.save(r'mhdData\PELVIS_001_NoMetal\DLI L1\proj_0001')
detectorNavigator_1.store_scatter(True)