[TIMOB-7681] iOS: hires property not respected for remote imageviews
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Invalid |
Resolution Date | 2012-10-15T17:54:14.000+0000 |
Affected Version/s | Release 2.0.0, Release 1.8.1, Release 1.8.2 |
Fix Version/s | Sprint 2012-04, Release 2.0.0, Release 1.8.3 |
Components | iOS |
Labels | ipass1, module_imageview, qe-testadded, regression, triage |
Reporter | Federico Casali |
Assignee | Ingo Muschenetz |
Created | 2012-02-15T20:27:39.000+0000 |
Updated | 2017-03-20T22:02:24.000+0000 |
Description
Problem
remote imageviews with property hires set to true are displayed blurry, showing visible square pixelsSteps to reproduce
var win1 = Titanium.UI.createWindow({
title:'win',
backgroundColor:'black'
});
var image = Ti.UI.createImageView({
"width": 45,
"height": 45,
"hires": true,
"image": "http://cloud.rabble.se/images/offers/100_80_20110524154748.jpg"
});
win1.add(image);
win1.open();
Results
Attaching 2 screenshots displaying the image with 1.8.1 and 1.8.0.1Ticket
Customer ticket: http://support-admin.appcelerator.com/display/APP-337519Attachments
File | Date | Size |
---|---|---|
1.8.0.1.png | 2012-03-16T13:42:50.000+0000 | 89271 |
1.8.2.png | 2012-03-16T13:42:50.000+0000 | 82219 |
3.0.0_hires_not_respected.png | 2012-10-12T21:14:12.000+0000 | 1157078 |
ScreenShot-TiSDK_1801.png | 2012-02-15T20:27:39.000+0000 | 23746 |
ScreenShot-TiSDK_181.png | 2012-02-15T20:27:39.000+0000 | 23377 |
The documentation is fairly clear about what constitues an appropriate use of "hires": bq. Causes images to display at 50%, where one pixel of the graphic maps to one physical pixel on-screen. This functionality is automatically determined for local images via their filenames, and thus this property is only applicable to remote images. We need more information for this ticket: * Whether or not the image is sized for 2x and conforms to this standard
The problem is valid with 2x images, but the problem is likely the remote image cache. [Quote from Q&A:](http://developer.appcelerator.com/question/131879/sdk-181---remote-image-cache-without-retina-display) "I just noticed that the remote image cache does not show cached images with retina display. If the image is loaded the first time, everything looks good. But on second load (now from cache folder /Library/Caches) the graphic is pixelated, seems like "hires" parameter is ignored. Code works perfect with SDK <= 1.8.0.1 but fails with latest SDK 1.8.1"
Jonas - Thanks for the information. There was no change between image caching in 1.8.0.1 and 1.8.1 that would cause this behavior but it may still be introducing the problem.
I am having the exact same issue. As soon as I switched the SDK Version to 1.8.1 in tiapp.xml, all of my remote images look terrible. I switched it back to 1.8.0.1 and they look good again. I did not change the remote images or my createImageView properties - all I changed was the SDK Version. You can see a side-by-side comparison of the same image using the different SDK versions here: [http://dl.dropbox.com/u/3289523/pics/misc/imageView_hires_issue_1.8.1.jpg] I cannot release an app that has blurry images, so to me this is a critical bug. Please fix this ASAP! Dave
Dave and Jonas - would either of you be so kind as to attach a sample script that reproduces the noted behavior? That will assist us in getting resolution as quickly as possible. Thanks much!
See "Steps to reproduce" above. Important: Load the app a second time so that the image is displayed from cache. Then you will notice that the image is blurry.
Regression introduced by TIMOB-7051
PR https://github.com/appcelerator/titanium_mobile/pull/1492 merged into master.
Bug is not resolved in latest SDK 1.8.2? Do I only have to modify the 2 files as described in https://github.com/sptramer/titanium_mobile/commit/db0702eb19f0ac0777c824e12982413e43f2e1b3 to get this working? Or does the bugfix involves more files and places?
Correct. This fix is not part of 1.8.2 release.
Adding larger, clearer screenshots comparing 1.8.0.1 (correct) and 1.8.2 (bug). Will add code when bug closed.
Closing as Fixed. SDK: 2.0.0.v20120316130302 Studio: 2.0.0.201203152033 OS: Snow Leopard Devices Tested: iPad 4.3.5, iPhone Simulator 5.0
Note: The error image results in an extremely blurry image (fine lines are not discernable), while the correct image is only slightly blurry (fine lines are discernable).
Note: The hires property is iOS only.
Note: This test uses external server resources.
Opening to edit labels.
Reopened, two the same resolution images are displayed on a screen. Added a screenshot 3.0.0_hires_notrespected.png. Tested on: Titanium Studio, build: 3.0.0.201210090117 Titanium SDK, build: 3.0.0.v20121012114611 Devices: iPad3 ios 5.1.1 iPhone4 ios 5.1.1 iPhone5 ios 6.0
Is there a reason this didn't get the qe-ios100112 label?
Invalid test case. Ofcourse both the images have the same resolution. You have explicitly set the width and the height. The test case for respecting hires flag should have Ti.UI.SIZE width and height. When that is the case the hires image should have half the resolution of the non hires image.
Closing ticket as invalid.