res and blurry in PhoneGap 2.5

I'm developing a PhoneGap app that uses the Google Maps API. I've created high-res versions of a number of my graphics for display on higher resolution screens, which look very nice, but the map tiles themselves are very low-resolution and blurry. The map tiles on our mobile website, which is built from essentially the same code, are much sharper and better looking. (See here for a full-sized comparison.)

My viewport tag is:

<meta id="viewport" name="viewport" 
    content="width=device-width, initial-scale=1.0, user-scalable=no" />

How can I make the map tiles look better in my app?

PhoneGap应用和移动网站的比较


Been struggling with the same issue for age and it seems to be a DPI scaling issue in the WebView component used by Phonegap when having hardware acceleration enabled, which is turned on by default since Android 4.0.

You can force the hardware acceleration to be disabled by adding android:hardwareAccelerated="false" to the tag in your AndroidManifest.xml and the map will be sharp again, but the rest of yoru app might be more sluggish, especially if you have heavy HTML/CSS elements.

Another solution is to set in the of your index.html to make the viewport use the native screen DPI, but then all your app will look tiny.

So unfortunately I haven't found any satisfactory solution yet, and there's not much more information about the issue around the web.

链接地址: http://www.djcxy.com/p/67416.html

上一篇: 最佳地图系统为phonegap网络应用程序

下一篇: 在PhoneGap 2.5中的res和blurry