One solution I found for those who will have the same problem. I used knnsearch to find the closest points in my latitude and longitude grid, and used their indexs and applied poly2mask on it.
clear indLat indLon latPix lonPix coord
for i = 1:size(area,1)
indLat = knnsearch(lat(1,:)',area(i,2));
indLon = knnsearch(lon(:,1),area(i,1));
latCoord(i,1) = indLat;
lonCoord(i,1) = indLon;
end
bw = poly2mask(latCoord(:,1),lonCoord(:,1),size(lon,1),size(lon,2));
with area being my matrix of real coordinates associated to the area (column 1 = lat, 2 = lon). I can use this solution because my latitude and longitude grid are of high resolution enough, and that I am not constrained by the quality of the final results, it is ok if I miss a pixel, which may not be for very high resolution tasks.