WMME device: setting input volume

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

 



Hello everybody!

In one of my Windows applications I needed the ability to control the 
input volume of the audio devices used there.
Unfortunately, only setting the output volume was implemented so I 
updated the WMME backend to also support
setting/getting the input volume.

Please review the code and consider merging it into upstream.

Note:
- I was unable to test the code with audio devices that have more than 
one input channel (I don't have any of these).
- When querying the input volume, the volume of the first channel will 
be returned only*
- When setting the input volume, it will be applied to all channels of 
the device*
- The patch is against pjproject 2.3

* That's not an issue if the WMME controls indicate "uniform" settings
(meaning the setting of one channel is applied to all the other 
channels; see the code)

What might need to be revisited is the return of error codes from the 
new function 'wave_mixer_control'
because I wasn't sure on how to introduce a new ERRNO range for this.
There's already PJMEDIA_AUDIODEV_ERRNO_FROM_WMME_IN()
and PJMEDIA_AUDIODEV_ERRNO_FROM_WMME_OUT()
and now something like PJMEDIA_AUDIODEV_ERRNO_FROM_WMME_MIXER() would be 
needed... I think?


Best regards,

Andreas Wehrmann

-------------- next part --------------
A non-text attachment was scrubbed...
Name: wmme_dev_input_volume.patch
Type: text/x-diff
Size: 12110 bytes
Desc: not available
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20141113/1bce206b/attachment.patch>


[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