To prevent floods from endangering lives and property, surveillance cameras are widely used in places prone to floods, such as low-lying areas and rivers, to monitor water levels during typhoons. Recently, with the advancement of surveillance camera technologies, surveillance cameras have been widely applied to automatically measure water levels. In this study, an embedded system based on a single camera is proposed, where camera images are used to measure water levels. Digital image processing is used to identify the current water level from an image of the on-site staff gauge. The fact that the camera position typically results in a non-orthogonal angle between the camera's optical axis and the staff gauge plane on-site was taken into consideration due to the fact that it causes perspective distortion and leads to deviations in water level measurements. In this study, the inverse perspective mapping (IPM) method was applied in the system to overcome this problem. Using IPM to transform the coordinate system of images from one perspective plane to another rectified the perspective distortion. To simplify the image processing of every input frame, only the region of interest (ROI) underwent IPM transformation during the water level calculation in order to improve the system operating performance. The experimental results proved that the water level measurement system using the IPM method effectively reduced measurement deviations for confined space applications and effectively tracked real-world water level changes.