开发者

Webbrowser Javascript image encoding and resizing

I'm on my way creating a mobile app using phonegap and jquery mobile. i realized huge performance issues by displaying a list of images on the device. the reason must be that those images have a quite high resolution (> 1900 px in width).

i am using javascript and w开发者_Go百科ant to resize and reduce the resolution of an image taken by the device's camera!

is it possible to manipulate the image data in this way or is there any library to use? if it is possible what one has to read and / or to do to get into the matter of image manipulation.

thanks in advance!


You need to reduce the images on the server side otherwise you aren't gaining anything. Using a server side language such as php you could clone the image and reduce it's size for mobile. So basically you will be retreiving mobile optimized images for mobile devices. Manipulating images on the client won't save you bandwidth and will cost extra processing.


May this link could help you: http://forums.macrumors.com/showthread.php?t=1178073

Instead of resizing the image you could take a smaler picture.


i found something which could be quite useful! actually this is an jpeg encoder written in javascript which can reduce the image's quality but cant scale the picture!

http://www.bytestrom.eu/de/blog/2009/1120a_jpeg_encoder_for_javascript

cu

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜