I need to draw some vertical lines on screen ( I display it on a monitor), That lines must to be 1 inch from each one. I also need to draw another line that user can move pressing arrows. Once in final position I want to find the real distance in inches from the nearest line. I'm able to draw line in winform, WPF and XNA, but how can I be sure that lines have a real world distance of 1 inches? And how can I measure the distance in inches? Any advice?
Asked
Active
Viewed 33 times
0
-
see [Convert Pixels to Inches and vice versa in C#](https://stackoverflow.com/questions/474810/convert-pixels-to-inches-and-vice-versa-in-c-sharp) – Étienne Laneville Jun 21 '23 at 20:13
-
1To do this, you have to be able to guarantee the monitor dot pitch, resolution, and system zoom level, NONE of which are normally available. – Joel Coehoorn Jun 21 '23 at 20:23
-
@Étienne Laneville I'll try your suggestion. – user18107302 Jun 22 '23 at 12:34