pixels vs centimetres

edited January 2014 in How To...

how do you calculate pixels vs centimetres? say i have wall 3x3 meters with objects hanging there and i want to project on this wall p5 sketch, say ellipses and i want them to be precisely between the physical objects... what size my processing sketch should be now to match the dimensions of physical surface?

Tagged:

Answers

  • edited January 2014 Answer ✓

    You need to know the DPI of your display. Once you know how many dots (in this case pixels) are there per inch (in this case centimeter) you will be able to easily calculate the exact pixel dimensions.

    alternatively, if you don't have access to DPI of your display, you can just display a known pixel dimension (i.e. 1000px, 500px, 100px) take some measurement tape and get a pixel to centimeter ratio this way. Than using proportions you can get pixel values for desired dimensions. If you don't have access to your final display you can put a global variable in your code, calibrate for your monitor, and once you have access to your wall just update the value.

Sign In or Register to comment.