function locs = cloudToImLoc(pts)
% cloudToImage.m - Get image pixel locations of 3D point cloud
% Author: Kevin Lai
%
% Input: 
% pts - the 3D point cloud
%
% Output:
% locs - the pixel locations of each point in pts
%

% RGB-D camera constants
center = [320 240];
constant = 570.3;

locs = zeros(size(pts,1),2);
locs(:,1) = center(1) + round(pts(:,1)*constant./pts(:,3));
locs(:,2) = center(2) + round(pts(:,2)*constant./pts(:,3));

