Commit 4b2949be authored by Tobias Bisanz's avatar Tobias Bisanz Committed by Simon Spannagel
Browse files

Correctly transforming translation vector

(cherry picked from commit 411765ee)
parent 9a78a882
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -102,7 +102,7 @@ namespace allpix {
                    ((daughter_rotation != nullptr) ? new G4RotationMatrix(*daughter_rotation * *rotation_)
                                                    : new G4RotationMatrix(*rotation_));
                LOG(TRACE) << "Rotation matrix: " << *rotation_matrix;
                gdml_daughter->SetTranslation(gdml_daughter->GetTranslation() + position_vector);
                gdml_daughter->SetTranslation((rotation_->inverse()) * gdml_daughter->GetTranslation() + position_vector);
                gdml_daughter->SetRotation(rotation_matrix);

                // Check if color information is available and set it to the daughter volume