gstaudiosrc/sink: Set audio ringbuffer thread priority
authorNirbheek Chauhan <nirbheek@centricular.com>
Mon, 10 Sep 2018 19:11:59 +0000 (00:41 +0530)
committerNirbheek Chauhan <nirbheek@centricular.com>
Mon, 10 Sep 2018 19:11:59 +0000 (00:41 +0530)
commit17332330601930b03eecb85e2d693cdb960fca5a
tree40bd369753bbe99ce379765e0052a37ddc02913a
parent41b7a65b81bdb1f257f2a8552d42dc0047e463dc
gstaudiosrc/sink: Set audio ringbuffer thread priority

On Windows, the ringbuffer thread function must have the "Pro Audio"
priority set, otherwise it sometimes doesn't get scheduled for
200-300ms, which will immediately cause an underrun unless you set
a very high latency-time and buffer-time.

This has no compile-time deps since it tries to load avrt.dll at
runtime to set the thread priority.
gst-libs/gst/audio/gstaudiosink.c
gst-libs/gst/audio/gstaudiosrc.c
gst-libs/gst/audio/gstaudioutilsprivate.c
gst-libs/gst/audio/gstaudioutilsprivate.h