Ignore:
Timestamp:
Mar 9, 2009 1:08:16 PM (15 years ago)
Author:
bennylp
Message:

BIG refactoring in pjsua_media.c:

  • switchboard/conf detection is done at run-time, removing #ifdefs
    • use one function, open_snd_dev() to open device
    • use one function, create_aud_param() to initialize audio parameters:
      • get the default from device
      • override with user settings previously done with pjsua_snd_set_setting() (new API)
  • added new API to set/get sound device settings. The settings are

semi permanent, it will be used for future opening of sound dev:

  • pjsua_snd_set_setting()
  • pjsua_snd_get_setting()
  • snd_auto_close_time default value changed to 1 (from -1)
  • both pjsua_enum_snd_devs() and pjsua_enum_aud_devs() API are now

supported (previously it was done with #ifdef).

  • make_call() will not open the sound device is switchboard is

used

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/branches/projects/aps-direct/pjsip/include/pjsua-lib/pjsua_internal.h

    r2394 r2493  
    273273    pjsua_conf_setting   mconf_cfg; /**< Additionan conf. bridge. param */ 
    274274    pjmedia_conf        *mconf;     /**< Conference bridge.             */ 
    275     int                  cap_dev;   /**< Capture device ID.             */ 
    276     int                  play_dev;  /**< Playback device ID.            */ 
     275    pj_bool_t            is_mswitch;/**< Are we using audio switchboard 
     276                                         (a.k.a APS-Direct)             */ 
     277 
     278    /* Sound device */ 
     279    pjmedia_aud_dev_index cap_dev;  /**< Capture device ID.             */ 
     280    pjmedia_aud_dev_index play_dev; /**< Playback device ID.            */ 
     281    pj_uint32_t          aud_svmask;/**< Which settings to save         */ 
     282    pjmedia_aud_param    aud_param; /**< User settings to sound dev     */ 
     283    pj_bool_t            aud_open_cnt;/**< How many # device is opened  */ 
    277284    pj_bool_t            no_snd;    /**< No sound (app will manage it)  */ 
    278285    pj_pool_t           *snd_pool;  /**< Sound's private pool.          */ 
Note: See TracChangeset for help on using the changeset viewer.