Closed Bug 1054994 Opened 10 years ago Closed 10 years ago

Contact photos are scaled down below the screen resolution

Categories

(Firefox OS Graveyard :: Gaia::Contacts, defect)

All
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(b2g-v1.4 affected, b2g-v2.0 affected, b2g-v2.1 affected)

RESOLVED FIXED
2.1 S7 (24Oct)
Tracking Status
b2g-v1.4 --- affected
b2g-v2.0 --- affected
b2g-v2.1 --- affected

People

(Reporter: hsivonen, Assigned: jmcf)

Details

(Whiteboard: [2.1-flame-test-run-3])

Attachments

(2 files)

Steps to reproduce:
 1) Use Flame.
 2) Use nightly Gecko+Gaia
 3) Add a high-resolution (more pixels than fit on the screen) photo to a contact
 4) Call that contact

Actual results:
The photo shown during the call is visibly pixelated.

Expected results:
Expected the high-resolution photo to be nicely scaled to device pixels and to be as sharp as the screen allows.
QA Wanted for a branch check.
Keywords: qawanted
This bug repro's on: Flame 2.1, Flame 2.0, Flame 1.4, Buri 2.1

Actual Results: High Resolution images appear pixalated when used as a contacts image and the image appears during a call.

Repro Rate: 5/5

Environmental Variables:
Device: Flame Master
BuildID: 20140818002014
Gaia: aa8aace12d65956dd9525da5dac66e0d3b28597f
Gecko: 0aaa2d3d15cc
Version: 34.0a1 (Master) 
Firmware Version: v123
------------------------------------------------
Environmental Variables:
Device: Flame 2.0
BuildID: 20140815172512
Gaia: fb2dd31abed2803eb7ad67eb4c52abb48de1e0f7
Gecko: f1fb2b4549b6
Version: 32.0 (2.0) 
Firmware Version: v123
------------------------------------------------
Environmental Variables:
Device: Flame 1.4
BuildID: 20140818062816
Gaia: 21bec64497dc06a7f12071d573570ba8fea598ae
Gecko: 07d78d0f9bef
Version: 30.0 (1.4) 
Firmware Version: v123
------------------------------------------------
Environmental Variables:
Device: Buri Master
BuildID: 20140818072913
Gaia: ba1992f2addc5a84afc2eab426f222a6bf2962ba
Gecko: bf27e27c994d
Version: 34.0a1 (Master) 
Firmware Version: v1.2device.cfg
QA Whiteboard: [QAnalyst-Triage?]
Flags: needinfo?(jmitchell)
Keywords: qawanted
QA Contact: croesch
Attached image 2014-08-18-13-40-59.png
This is a great example of what we are seeing.
not a regression
QA Whiteboard: [QAnalyst-Triage?] → [QAnalyst-Triage+]
Flags: needinfo?(jmitchell)
QA Whiteboard: [QAnalyst-Triage+] → [QAnalyst-Triage+][lead-review+]
This is not a regression, we need to compress the quality of the photos cause of the space taken, for devices like dolphin (or even tarako) is simple way too much.

Probably we will need, in the future (I'm talking about a new feature), a way to distinguis between device capabilities and have different strategies for contacts photos.
QA Whiteboard: [QAnalyst-Triage+][lead-review+] → [QAnalyst-Triage?][lead-review+]
Flags: needinfo?(dharris)
Whiteboard: [2.1-flame-test-run-3]
QA Whiteboard: [QAnalyst-Triage?][lead-review+] → [QAnalyst-Triage+][lead-review+]
Flags: needinfo?(dharris)
Assignee: nobody → jmcf
(In reply to Francisco Jordano [:arcturus] [:francisco] from comment #5)
> This is not a regression, we need to compress the quality of the photos
> cause of the space taken, for devices like dolphin (or even tarako) is
> simple way too much.
> 
> Probably we will need, in the future (I'm talking about a new feature), a
> way to distinguis between device capabilities and have different strategies
> for contacts photos.

Francisco, I think this bug is true. The problem is that https://github.com/mozilla-b2g/gaia/blob/master/shared/js/contacts/import/utilities/misc.js#L7  should be 

var SCALE_RATIO = window.devicePixelRatio || 1;

The fix is pretty easy and I think we can fix that in this sprint.
Flags: needinfo?(francisco)
Arrrrg!

We missed the history of that file when we moved from FTU! We did not moved but copy it, loosing all info about why (and who) we decided to go for that.

The solution that you proposed looks nice, since our lowend devices don't go further than 320x480.

My concern is about the space needed if we don't scale the images, so ideally, I would like to have a config parameter where we can modify this at build time.

Meanwhile, definitely what you propose is a good solution.

Thanks Jose!
Flags: needinfo?(francisco)
(In reply to Francisco Jordano [:arcturus] [:francisco] from comment #7)
> Arrrrg!
> 
> We missed the history of that file when we moved from FTU! We did not moved
> but copy it, loosing all info about why (and who) we decided to go for that.
> 
> The solution that you proposed looks nice, since our lowend devices don't go
> further than 320x480.
> 
> My concern is about the space needed if we don't scale the images, so
> ideally, I would like to have a config parameter where we can modify this at
> build time.

Yes, that currently exists in communications_services.json, line 16. And if you remember those parameters are configurable at build time. 

> 
> Meanwhile, definitely what you propose is a good solution.
> 

A patch is coming :)

> Thanks Jose!
Attached file 25355.html
Attachment #8508733 - Flags: review?(francisco)
Comment on attachment 8508733 [details]
25355.html

r+ with comment on gh addressed

Thx!
Attachment #8508733 - Flags: review?(francisco) → review+
https://github.com/mozilla-b2g/gaia/commit/55558c1aac9d4757de8a2feebeb8dbeae81d594f
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → 2.1 S7 (24Oct)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: