function pout=applyTransformMatrix(pin,M)

pin(3,:)=zeros(1,size(pin,2));
pin(4,:)=ones(1,size(pin,2));

pout=M*pin;

pout=pout(1:2,:);