%% Extract Translation Vector from Homogeneous Transformation

tform = [1 0 0 0.5; 0 -1 0 5; 0 0 -1 -1.2; 0 0 0 1];
trvec = tform2trvec(tform)

% Copyright 2019 The MathWorks, Inc.