<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Times New Roman; font-size: 12pt; color: #000000'><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">Hello, </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">I have some issues to read a rigid transform from a .mat file into ITK and apply it to a NIFTI image. </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">First, I read the rotation matrix and store it in a MatrixType object. Same thing with the translation ( with an OutputVectorType). </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">The reading is done without problems. </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">Then the parameters are used in a Rigid3DTransform object. This type requires an orthogonal rotation matrix if I use the SetMatrix method. And this is where the error occurs. When I launch the program, ITK says : </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">"itk::ERROR: Rigid3DTransform(0x26d0300): Attempting to set a non-orthogonal rotation matrix" </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">But the rotation matrix IS orthogonal. I have checked it. Here it is: </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "> -0.049716 -0.80244 0.594658 </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "> -0.8522 0.344577 0.393729 </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "> -0.52085 -0.487193 -0.70097 </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">Can anyone help me with this? </span><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><br style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); "><span style="font-family: Verdana, Geneva, Helvetica, Arial, sans-serif; font-size: 13px; background-color: rgb(255, 255, 255); ">Thanks</span></div></body></html>