Setting Sound Device Id

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

 



I forgot to add the output:

 13:32:05.647    pjsua_app.c  Audio Device 0: HDA Intel: ALC888 Analog
(hw:0,0)
 13:32:05.647    pjsua_app.c  Audio Device 1: HDA Intel: ALC888 Digital
(hw:0,1)
 13:32:05.647    pjsua_app.c  Audio Device 2: HDA Intel: ALC888 Analog
(hw:0,2)
 13:32:05.647    pjsua_app.c  Audio Device 3: USB  AUDIO  : USB Audio
(hw:1,0)
 13:32:05.647    pjsua_app.c  Audio Device 4: front
 13:32:05.647    pjsua_app.c  Audio Device 5: surround40
 13:32:05.647    pjsua_app.c  Audio Device 6: surround51
 13:32:05.647    pjsua_app.c  Audio Device 7: surround71
 13:32:05.647    pjsua_app.c  Audio Device 8: iec958
 13:32:05.647    pjsua_app.c  Audio Device 9: spdif
 13:32:05.647    pjsua_app.c  Audio Device 10: pulse
 13:32:05.647    pjsua_app.c  Audio Device 11: dmix
 13:32:05.647    pjsua_app.c  Audio Device 12: default
 13:32:05.647    pjsua_app.c  Audio Device 13: /dev/dsp
 13:32:05.647    pjsua_app.c  Audio Device 14: /dev/dsp1


2010/8/13 Kabil Akp?nar <kabilakpinar at gmail.com>

> I have 2 sound card installed in my computer, in order to execure 2 pjsua
> application independently for testing purposes. the command line argument
> --playback-dev and --capture-dev need be introduces to change the default
> devices. But what device Id is required to do this. I'm executing the below
> code in order to get some info about installed devices. Also I tried some
> ids but all failed, like --playback-dev=3 --capture-dev=3.
> Your help is very appreciated.
>
>             pjmedia_aud_dev_info info[20];
>             unsigned count = 20;
>             pj_status_t stat;
>             int i, capture_id,playback_id;
>
>             stat = pjsua_enum_aud_devs(info, &count);
>             if (stat == PJ_SUCCESS)
>             {
>                 for (i = 0; i < count; i++)
>                     PJ_LOG(3, (THIS_FILE, "Audio Device %d: %s", i,
> info[i].name));
>
>                  stat = pjsua_get_snd_dev(&capture_id, &playback_id);
>                  if(stat==PJ_SUCCESS)
>                  {
>                     PJ_LOG(3, (THIS_FILE, "Current Capture Device id %d",
> capture_id));
>                     PJ_LOG(3, (THIS_FILE, "Current Playback Device id %d",
> playback_id));
>                  }
>             }
>             else
>             {
>                 PJ_LOG(3, (THIS_FILE, "Error enumeration of audio devices,
> %d", status));
>             }
>
>
>
> --
> Kabil Akp?nar
>
>


-- 
Kabil Akp?nar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20100813/0352f3a9/attachment.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