managing media

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Mar 11, 2014 at 1:59 PM, Brian White <mscdex at mscdex.net> wrote:

> While working on my node.js binding, I've run into some major issues that
> have to do with managing the various media objects with the pjsua2 API.
>
> One issue is that there doesn't seem to be a way to tell when an
> AudioMediaPlayer instance has finished playing when PJMEDIA_FILE_NO_LOOP
> is used. I noticed there are pjmedia_*_eof_cb() functions, so I guess the
> underlying parts are there but the c++ interface is just lacking currently.
> I couldn't find a way to do it myself in the meantime as there is no way to
> get at the AudioMediaPlayer's underlying pjmedia_port(?) struct to be able
> to use the pjmedia_*_eof_cb() methods.
>
>
That's true. Let me add a callback for it.


> The other big issue I'm running into is trying to find out when
> AudioMedia, AudioMediaPlayer, and AudioMediaRecorder objects are removed
> from the call/conference so that I can emit my own events in javascript
> land to alert the end user. This is especially important since I read that
> if a call is put on hold, these objects are automatically removed(!). I
> thought I could use the onStream* callbacks but then I found out that
> streams are different things than AudioMedia* objects, so I couldn't use
> those.
>
>
Only call's media that can get removed from the bridge by the stack. The
rest are manipulated by app, so app knows when they are removed, hence
there's no need for callback.

For call, the callback is Call::onCallMediaState().



> Also, I was hoping to also be able to do a
> AudioMediaPlayer::lookup(portId) and AudioMediaRecorder::lookup(portId)
> to be able to locate any players or recorders that may have been created,
> as that would make things much easier for writing a binding.
>
>
>
Currently that's not possible, as we don't have the type information about
the AudioMedia that was added to the bridge. But why do you need to lookup
anyway? Shouldn't you keep the AudiaMediaPlayer instance somewhere if you
need it?

Cheers
 Benny



> - Brian
>
> _______________________________________________
> Visit our blog: http://blog.pjsip.org
>
> pjsip mailing list
> pjsip at lists.pjsip.org
> http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20140311/02fe0841/attachment-0001.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux