[haiku-development] Re: Proposed changes to media_kit

  • From: Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Sun, 12 Jul 2015 14:28:41 +0200

Am 10/07/2015 um 22:14 schrieb Dario Casalinuovo:
[...]

* Change the current media_server mechanism that use ping/pong messages
to watch for BMediaRosters.

It has been already discussed about modifying the registrar
notifications so that it's possible to watch only for a specific team.
Once i do this, i'll update my implementation of media services
start/quit notifications to take advantage of this (it is in a branch in
github for any interested).

As noted during the discussion (if I recall it correctly), is that this is pretty much overkill, as there only ever are very few applications that could quit to begin with.
The difference between 100 messages and 20 messages over day is really completely negligible.

* Change BBufferGroup synchronization to don't use shared semaphores.
The actual implementation is using shared semaphores among multiple
teams. The bebook advise against that and it's discouraged.

First of all, there is *nothing* wrong about sharing semaphores between multiple teams (or threads -- that's not really much of a difference). Nowadays, that's pretty much their only use case, as we support more light weight constructs for single teams.
The question is just what you will be using the semaphore for.

[...]
I would like to listen some opinion against it (if any).

What exactly is the problem you are trying to solve?

* Implement BMediaPlayer and BMediaFilter then make BSoundPlayer
deprecated or alternatively make it a wrapper.

I guess that depends on the API differences between the two classes; if they can be used very similarly, deprecating it should be the way to go.

I'm fine with separating the R3 audio classes; are there any apps actually using those still, though?

Bye,
Axel.


Other related posts: