Closed Bug 1033128 Opened 10 years ago Closed 6 years ago

[dolphin][7715] Camera taking picture takes an average of 3.1s, slower than android

Categories

(Firefox OS Graveyard :: Gaia::Camera, defect, P3)

ARM
Gonk (Firefox OS)
defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: Xiaohong.Fan, Unassigned)

References

Details

(Keywords: perf, Whiteboard: [sprd324605][c=progress p= s= u=][partner-blocker][perf][POVB])

Attachments

(1 file)

13.07 KB, application/vnd.oasis.opendocument.spreadsheet
Details
Steps to reproduce:
1) Enter the camera app
2) Click camera capture button, start recording time
3) The thumbnail appears, stop recording time

Actual result:
 It takes an average of 3.1s, slower than android,2.6s.
Whiteboard: sprd324605
(In reply to Xiaohong.Fan from comment #0)
> Steps to reproduce:
> 1) Enter the camera app
> 2) Click camera capture button, start recording time
> 3) The thumbnail appears, stop recording time
> 
> Actual result:
>  It takes an average of 3.1s, slower than android,2.6s.

xiaohong, now we have bug 931733 and bug 988291 so the thumbnail never appears after recording.
BTW, I think taking picture also has problem when saving picture on dolphin. Flame and Buri are actually faster.
(In reply to pcheng from comment #1)
> (In reply to Xiaohong.Fan from comment #0)
> > Steps to reproduce:
> > 1) Enter the camera app
> > 2) Click camera capture button, start recording time
> > 3) The thumbnail appears, stop recording time
> > 
> > Actual result:
> >  It takes an average of 3.1s, slower than android,2.6s.
> 
> xiaohong, now we have bug 931733 and bug 988291 so the thumbnail never
> appears after recording.
> BTW, I think taking picture also has problem when saving picture on dolphin.
> Flame and Buri are actually faster.

You are right, dolphin is slower than Flame,and the thumbnail is slow to appear.
the two functions below are about the saving picture and getting picture to show thumbnails,they take about 0.72s
1)req = self.image.addNamed(blob, filepath);
2)req = self.image.get(filepath);

Besides,the function self.mozCamera.takePicture(config, onSuccess, onError) takes about 1.6s, 
more than half of the total time,3.1s. The log is below.

log:
06-30 01:01:44.950 E/GeckoConsole( 2172): Content JS LOG at app://camera.gaiamobile.org/js/main.js:3546 in onFocused: mozCamera_takePicture_begin
06-30 01:01:46.580 E/GeckoConsole( 2172): Content JS LOG at app://camera.gaiamobile.org/js/main.js:3569 in onSuccess: camera_prototype_takePicture_onSuccess_begin
depend on 988291 and 931733. Since mozilla build cannot show thumbnails after taking video.
Depends on: 988291, 931733
Keywords: perf
Priority: -- → P3
Whiteboard: sprd324605 → sprd324605[c=progress p= s= u=]
Hi Thomas, could you please kindly check this?
Thanks a lot.
Flags: needinfo?(ttsai)
Hi Vincent: please comment your findings. Thanks!
Flags: needinfo?(ttsai) → needinfo?(vliu)
(In reply to thomas tsai from comment #5)
> Hi Vincent: please comment your findings. Thanks!

Hi Thomas,

From seeing the title, I through this is a dup of bug 1033166, which I had added comment. But observed the comments in detail, I found this bug is talking about camera recording. As Comment 3 said, this might depends on bug 988291, 931733. 

@Solomon, bug 988291 is owned by you. Can you please help us to confirm if your fix on bug 988291 is also work for this? Thanks
Flags: needinfo?(vliu) → needinfo?(schiu)
Regarding comment 0: well before the thumbnail appears, the camera is capable of taking another picture. Should that be the metric of picture-taking time instead?
(In reply to Vincent Liu[:vliu] from comment #6)
> (In reply to thomas tsai from comment #5)
> > Hi Vincent: please comment your findings. Thanks!
> 
> Hi Thomas,
> 
> From seeing the title, I through this is a dup of bug 1033166, which I had
> added comment. But observed the comments in detail, I found this bug is
> talking about camera recording. As Comment 3 said, this might depends on bug
> 988291, 931733. 
> 
> @Solomon, bug 988291 is owned by you. Can you please help us to confirm if
> your fix on bug 988291 is also work for this? Thanks

Vincent,

As we discussed previously, the issue described here seems not relative to bug#931733. We may need to measure the time again.
Flags: needinfo?(schiu)
blocking-b2g: --- → 1.4?
Whiteboard: sprd324605[c=progress p= s= u=] → [sprd324605][c=progress p= s= u=][partner-blocker]
Whiteboard: [sprd324605][c=progress p= s= u=][partner-blocker] → [sprd324605][c=progress p= s= u=][partner-blocker][perf]
Hi Vincent,

Please ni? our partner to take a look this issue after you upload the profiling result.
Flags: needinfo?(vliu)
Remove the blocking flag since it should be POVB according to the profiling result.
blocking-b2g: 1.4? → ---
Whiteboard: [sprd324605][c=progress p= s= u=][partner-blocker][perf] → [sprd324605][c=progress p= s= u=][partner-blocker][perf][POVB]
(In reply to Ivan Tsay (:ITsay) from comment #9)
> Hi Vincent,
> 
> Please ni? our partner to take a look this issue after you upload the
> profiling result.

I tried to add some logs to buri, flame and dolphin to compare the performance for taking picture. These devices are all run on v1.4 branch. The result of profiling data is attached. There are two items need to be discussed.

1. For measuring time of auto focus, Dolphin runs about 8 times than other devices. Please see column B for more detailed. 

2. For measuring time of taking picture, Dolphin sometimes takes above 2 seconds when the first launch after reboot.

Hi James,

Can you have someone in your side to have a look for these? Thanks.
Flags: needinfo?(vliu) → needinfo?(james.zhang)
Hi, Vincent,
Autofocus on Dolphin ref. phone is provided by camera sensor (OV5640, YUV sensor), focus duration is relatively stable.
800ms is reasonable value, and is similar with performance on Dolphin android.


(In reply to Vincent Liu[:vliu] from comment #11)
> Created attachment 8460083 [details]
> profiling_for_taking_picture.ods
> 
> (In reply to Ivan Tsay (:ITsay) from comment #9)
> > Hi Vincent,
> > 
> > Please ni? our partner to take a look this issue after you upload the
> > profiling result.
> 
> I tried to add some logs to buri, flame and dolphin to compare the
> performance for taking picture. These devices are all run on v1.4 branch.
> The result of profiling data is attached. There are two items need to be
> discussed.
> 
> 1. For measuring time of auto focus, Dolphin runs about 8 times than other
> devices. Please see column B for more detailed. 
> 
> 2. For measuring time of taking picture, Dolphin sometimes takes above 2
> seconds when the first launch after reboot.
> 
> Hi James,
> 
> Can you have someone in your side to have a look for these? Thanks.
FYI, Bug 1039937 might affect to the performance.
Flags: needinfo?(james.zhang)
bug 1039937 may have improved the performance here, not much more we can do from our end. Please check what you can reduce on the bsp side.
Are you still having this issue? Have you tested with the patch in bug 1039937?
Flags: needinfo?(Xiaohong.Fan)
Flags: needinfo?(Xiaohong.Fan) → needinfo?(jinchao.wang)
Steps to reproduce:
1) Enter the camera app
2) Click camera capture button, start recording time
3) The thumbnail appears, stop recording time

The average time is 3.1s too, the take picture performance  hadn't been improved here.
Flags: needinfo?(jinchao.wang)
Firefox OS is not being worked on
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: