EDIT2: I've added an assumption that the camera calibration matrix is given. Other factors (rotation, camera pose) are still not given.
I want to measure actual lengths of floor edges (blue lines in the example below) of a room by finding the homography matrix, from its length given in pixels (of blue lines in the second image).
We can use the camera calibration matrix, the height of the room (green lines in the example below), the room layout image (like the second image) and the assumption that the room follows Manhattan layout.
EDIT: I've removed some words that makes the question looks begging for an working code. Anyway, thank you for your answers. I've decided to take photos from our camera with drawing several lines parallel with the wall to do this.