[B2G] The MozSpeakerAPI should only take effect on the specific process which turn the speaker on.

NEW
Unassigned

Status

Firefox OS
AudioChannel
3 years ago
2 years ago

People

(Reporter: alwu, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Now the design of the MozSpeaker API is to control all sound at the same time.
> "forcespeaker=true means that this app attempts to force the speaker to be on. This is only honored if 
> the app is currently in the foreground. So if a foreground app calls forcespeaker=true that means that 
> 'speakerforced' in all applications switches to true, and any audio from any application will go to the 
> speaker." [1] 

But I think that is conflict with the user perspective.
We can see the bug 1153124 and bug 1157122, they are all related with this issue.

If we open the MozSpeaker of FM (turn the speaker on), then we put the FM to the background.

THEN, ANY sound will be playback out from the speaker, it doesn't make sense.
Therefore, we should check the process ID to check who is using the MozSpeaker. We should only affect the sound of this process, instead of all sound.
Assignee: nobody → alwu
Duplicate of this bug: 1153124
Duplicate of this bug: 1157122
Hi, Baku,
MozSpeakerAPI lets all applications go out from the speaker instead of specific application, it resulted in some bugs. Ex. bug1123124, bug1157122.

I want to change the MozSpeakerAPI, that is only control the specific application which is using this MozSpeakerAPI.
What do you think about this proposal? Does it sound appropriate?

Thanks a lots :)
Flags: needinfo?(amarchesini)

Comment 4

3 years ago
Hi Vance,

We need this feature in 2.1,see SPRD bug432057,could you help to check this issue?
Flags: needinfo?(vchen)
Yes, your approach makes totally sense. I'm happy to review your code if you have time to work on this feature!
Flags: needinfo?(amarchesini)

Comment 6

3 years ago
Hi Alastor,

Any update for this issue?

We need this modify in 2.1s ;(
Flags: needinfo?(alwu)
Duplicate of this bug: 1095377
Flags: needinfo?(alwu)
Assignee: alwu → nobody
You need to log in before you can comment on or make changes to this bug.