I'm not sure what you mean. Let Ax mean rotating x by A (which is a rotation matrix, quaternion, rotor, whatever). Then, the composition of Ax + b and Cx + d is
C(Ax + b) + d = (CA)x + (Cb + d). C(Ax + b) + d = (CA)x + (Cb + d).