3 ms·
The size is way off for me. Tried on my Mac Book Pro's 15" screen and the batteries are huge, a good 50% bigger than real life. I'd imagine you would need to ge
by jonknee 18y ago
The size is way off for me. Tried on my Mac Book Pro's 15" screen and the batteries are huge, a good 50% bigger than real life. I'd imagine you would need to get screen size and DPI to accurately resize the images. Perhaps you could have a sample image (like the AA batteries) along with a slider to allow the user to set the exact ratio.
- ptm 18y agoPerhaps you've disabled your screen resolution tracking (screen.width / screen.height). To calculate the DPI it uses the screen resolution (pixels) and your reported screen size (inches), if either is missing it would fail to work (for now).
- jonknee 18y agoSafari might not report it, because I haven't changed anything (I wouldn't even know where to change that in Safari). I checked in FireFox and it was much closer to reality. Update: Safari does report it, so it looks to be another issue. Perhaps a bug in the scaling for Safari?
- ptm 18y agoYes, perhaps it is a bug in Safari. Thanks for the report. Edit - It might be the way Safari handles onload - https://bugs.webkit.org/show_bug.cgi?id=13241 https://bugs.webkit.org/show_bug.cgi?id=13241