winepulse: Introduce pulse_stream struct.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Andrew Eikum <aeikum@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2021-05-11 18:31:24 +02:00 committed by Alexandre Julliard
parent fa097243e0
commit 5477f2b015
3 changed files with 319 additions and 298 deletions

File diff suppressed because it is too large Load Diff

View File

@ -32,6 +32,7 @@
#define WIN32_NO_STATUS
#include "winternl.h"
#include "mmdeviceapi.h"
#include "initguid.h"
#include "audioclient.h"

View File

@ -16,6 +16,8 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "wine/list.h"
struct pulse_config
{
struct
@ -27,6 +29,34 @@ struct pulse_config
unsigned int speakers_mask;
};
struct pulse_stream
{
EDataFlow dataflow;
pa_stream *stream;
pa_sample_spec ss;
pa_channel_map map;
pa_buffer_attr attr;
DWORD flags;
AUDCLNT_SHAREMODE share;
HANDLE event;
INT32 locked;
UINT32 bufsize_frames, real_bufsize_bytes, period_bytes;
UINT32 started, peek_ofs, read_offs_bytes, lcl_offs_bytes, pa_offs_bytes;
UINT32 tmp_buffer_bytes, held_bytes, peek_len, peek_buffer_len, pa_held_bytes;
BYTE *local_buffer, *tmp_buffer, *peek_buffer;
void *locked_ptr;
BOOL please_quit, just_started, just_underran;
pa_usec_t last_time, mmdev_period_usec;
INT64 clock_lastpos, clock_written;
struct list packet_free_head;
struct list packet_filled_head;
};
struct unix_funcs
{
void (WINAPI *lock)(void);