Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.
added 89 characters in body
Source Link

I'm working on this website : sphere.mars2540.com.

Is there any way in javascript or css to force the canvas size not to scale regarding the zoom factor of the page and to constantly correspond to the real pixels of a screen (even 4k) ? I did know about devicePixelRatio, but it's not showing true ratio here on my 4k screen

thank you

I'm working on this website : sphere.mars2540.com.

Is there any way in javascript or css to force the canvas size not to scale regarding the zoom factor of the page and to constantly correspond to the real pixels of a screen (even 4k) ?

thank you

I'm working on this website : sphere.mars2540.com.

Is there any way in javascript or css to force the canvas size not to scale regarding the zoom factor of the page and to constantly correspond to the real pixels of a screen (even 4k) ? I did know about devicePixelRatio, but it's not showing true ratio here on my 4k screen

thank you

Source Link

how to force a canvas size to real size of a window in pixels, disregarding the zoom factor of the browser?

I'm working on this website : sphere.mars2540.com.

Is there any way in javascript or css to force the canvas size not to scale regarding the zoom factor of the page and to constantly correspond to the real pixels of a screen (even 4k) ?

thank you