简体   繁体   中英

Load images for different screen sizes from the server using picasso?

Hello i am making an android app in which i am getting images from the server and for that i am using picasso library now my question is that as there are different densities of screens with different sizes including (ldpi, mdpi, hdpi, xhdpi )required for different devices now i want to know in background does picasso itself do something so that if i will open an high density pic on an small screen size mobile then it will not get blurred or something or hang my phone or anyway so that it can dynamically adjust the pic for respective devices. Can i use ninepatch images for resolving my query.

Update - i have read answers that picasso itself handle all these densities problems but in my case what am i doing wrong because of what my recyclerview is hanging ??

毕加索不知道要下载哪个图像,但是请检查Picasso.fit()每个文档将尝试哪个图像,以尝试调整图像的大小以完全适合目标{@link ImageView}的边界

ninepatch used for system elements images rather than pictures. You have not specified the image is part of the interface or content.

You can get the density of the screen and the resolution of software and stretch / compress the image. (I would in your place was not afraid of distortion and memory problems in the low devices) So what can you do multiple sets of graphics on the server, if so worried.

But most of all, you really will approach the solution of this response .

But it's weird, to be honest. We need more information. I normally use drawable-XXX, ninepatch for buttons (backgound panels...), and stretch / compress on RapidDecoder for content.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM