Commit 76dc7641 authored by Davide Beatrici's avatar Davide Beatrici Committed by Alexandre Julliard

wineoss: Switch to mmdevapi's unixlib.h.

parent 65796159
...@@ -1612,7 +1612,9 @@ static NTSTATUS oss_aux_message(void *args) ...@@ -1612,7 +1612,9 @@ static NTSTATUS oss_aux_message(void *args)
unixlib_entry_t __wine_unix_call_funcs[] = unixlib_entry_t __wine_unix_call_funcs[] =
{ {
oss_test_connect, NULL,
NULL,
NULL,
oss_get_endpoint_ids, oss_get_endpoint_ids,
oss_create_stream, oss_create_stream,
oss_release_stream, oss_release_stream,
...@@ -1626,6 +1628,7 @@ unixlib_entry_t __wine_unix_call_funcs[] = ...@@ -1626,6 +1628,7 @@ unixlib_entry_t __wine_unix_call_funcs[] =
oss_release_capture_buffer, oss_release_capture_buffer,
oss_is_format_supported, oss_is_format_supported,
oss_get_mix_format, oss_get_mix_format,
NULL,
oss_get_buffer_size, oss_get_buffer_size,
oss_get_latency, oss_get_latency,
oss_get_current_padding, oss_get_current_padding,
...@@ -1634,7 +1637,9 @@ unixlib_entry_t __wine_unix_call_funcs[] = ...@@ -1634,7 +1637,9 @@ unixlib_entry_t __wine_unix_call_funcs[] =
oss_get_position, oss_get_position,
oss_set_volumes, oss_set_volumes,
oss_set_event_handle, oss_set_event_handle,
oss_test_connect,
oss_is_started, oss_is_started,
NULL,
oss_midi_release, oss_midi_release,
oss_midi_out_message, oss_midi_out_message,
oss_midi_in_message, oss_midi_in_message,
...@@ -2008,7 +2013,9 @@ static NTSTATUS oss_wow64_aux_message(void *args) ...@@ -2008,7 +2013,9 @@ static NTSTATUS oss_wow64_aux_message(void *args)
unixlib_entry_t __wine_unix_call_wow64_funcs[] = unixlib_entry_t __wine_unix_call_wow64_funcs[] =
{ {
oss_wow64_test_connect, NULL,
NULL,
NULL,
oss_wow64_get_endpoint_ids, oss_wow64_get_endpoint_ids,
oss_wow64_create_stream, oss_wow64_create_stream,
oss_wow64_release_stream, oss_wow64_release_stream,
...@@ -2022,6 +2029,7 @@ unixlib_entry_t __wine_unix_call_wow64_funcs[] = ...@@ -2022,6 +2029,7 @@ unixlib_entry_t __wine_unix_call_wow64_funcs[] =
oss_release_capture_buffer, oss_release_capture_buffer,
oss_wow64_is_format_supported, oss_wow64_is_format_supported,
oss_wow64_get_mix_format, oss_wow64_get_mix_format,
NULL,
oss_wow64_get_buffer_size, oss_wow64_get_buffer_size,
oss_wow64_get_latency, oss_wow64_get_latency,
oss_wow64_get_current_padding, oss_wow64_get_current_padding,
...@@ -2030,7 +2038,9 @@ unixlib_entry_t __wine_unix_call_wow64_funcs[] = ...@@ -2030,7 +2038,9 @@ unixlib_entry_t __wine_unix_call_wow64_funcs[] =
oss_wow64_get_position, oss_wow64_get_position,
oss_wow64_set_volumes, oss_wow64_set_volumes,
oss_wow64_set_event_handle, oss_wow64_set_event_handle,
oss_wow64_test_connect,
oss_is_started, oss_is_started,
NULL,
oss_midi_release, oss_midi_release,
oss_wow64_midi_out_message, oss_wow64_midi_out_message,
oss_wow64_midi_in_message, oss_wow64_midi_in_message,
......
...@@ -16,285 +16,7 @@ ...@@ -16,285 +16,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/ */
#include "mmdeviceapi.h" #include "../mmdevapi/unixlib.h"
typedef UINT64 stream_handle;
/* From <dlls/mmdevapi/mmdevapi.h> */
enum driver_priority
{
Priority_Unavailable = 0, /* driver won't work */
Priority_Low, /* driver may work, but unlikely */
Priority_Neutral, /* driver makes no judgment */
Priority_Preferred /* driver thinks it's correct */
};
struct test_connect_params
{
const char *name;
enum driver_priority priority;
};
struct endpoint
{
unsigned int name;
unsigned int device;
};
struct get_endpoint_ids_params
{
EDataFlow flow;
struct endpoint *endpoints;
unsigned int size;
HRESULT result;
unsigned int num;
unsigned int default_idx;
};
struct create_stream_params
{
const char *name;
const char *device;
EDataFlow flow;
AUDCLNT_SHAREMODE share;
UINT flags;
REFERENCE_TIME duration;
REFERENCE_TIME period;
const WAVEFORMATEX *fmt;
HRESULT result;
UINT32 *channel_count;
stream_handle *stream;
};
struct release_stream_params
{
stream_handle stream;
HANDLE timer_thread;
HRESULT result;
};
struct start_params
{
stream_handle stream;
HRESULT result;
};
struct stop_params
{
stream_handle stream;
HRESULT result;
};
struct reset_params
{
stream_handle stream;
HRESULT result;
};
struct timer_loop_params
{
stream_handle stream;
};
struct get_render_buffer_params
{
stream_handle stream;
UINT32 frames;
HRESULT result;
BYTE **data;
};
struct release_render_buffer_params
{
stream_handle stream;
UINT32 written_frames;
UINT flags;
HRESULT result;
};
struct get_capture_buffer_params
{
stream_handle stream;
HRESULT result;
BYTE **data;
UINT32 *frames;
UINT *flags;
UINT64 *devpos;
UINT64 *qpcpos;
};
struct release_capture_buffer_params
{
stream_handle stream;
UINT32 done;
HRESULT result;
};
struct is_format_supported_params
{
const char *device;
EDataFlow flow;
AUDCLNT_SHAREMODE share;
const WAVEFORMATEX *fmt_in;
WAVEFORMATEXTENSIBLE *fmt_out;
HRESULT result;
};
struct get_mix_format_params
{
const char *device;
EDataFlow flow;
WAVEFORMATEXTENSIBLE *fmt;
HRESULT result;
};
struct get_buffer_size_params
{
stream_handle stream;
HRESULT result;
UINT32 *size;
};
struct get_latency_params
{
stream_handle stream;
HRESULT result;
REFERENCE_TIME *latency;
};
struct get_current_padding_params
{
stream_handle stream;
HRESULT result;
UINT32 *padding;
};
struct get_next_packet_size_params
{
stream_handle stream;
HRESULT result;
UINT32 *frames;
};
struct get_frequency_params
{
stream_handle stream;
HRESULT result;
UINT64 *freq;
};
struct get_position_params
{
stream_handle stream;
BOOL device;
HRESULT result;
UINT64 *pos;
UINT64 *qpctime;
};
struct set_volumes_params
{
stream_handle stream;
float master_volume;
const float *volumes;
const float *session_volumes;
};
struct set_event_handle_params
{
stream_handle stream;
HANDLE event;
HRESULT result;
};
struct is_started_params
{
stream_handle stream;
HRESULT result;
};
struct notify_context
{
BOOL send_notify;
WORD dev_id;
WORD msg;
UINT_PTR param_1;
UINT_PTR param_2;
UINT_PTR callback;
UINT flags;
HANDLE device;
UINT_PTR instance;
};
struct midi_out_message_params
{
UINT dev_id;
UINT msg;
UINT_PTR user;
UINT_PTR param_1;
UINT_PTR param_2;
UINT *err;
struct notify_context *notify;
};
struct midi_in_message_params
{
UINT dev_id;
UINT msg;
UINT_PTR user;
UINT_PTR param_1;
UINT_PTR param_2;
UINT *err;
struct notify_context *notify;
};
struct midi_notify_wait_params
{
BOOL *quit;
struct notify_context *notify;
};
struct aux_message_params
{
UINT dev_id;
UINT msg;
UINT_PTR user;
UINT_PTR param_1;
UINT_PTR param_2;
UINT *err;
};
enum oss_funcs
{
test_connect,
get_endpoint_ids,
create_stream,
release_stream,
start,
stop,
reset,
timer_loop,
get_render_buffer,
release_render_buffer,
get_capture_buffer,
release_capture_buffer,
is_format_supported,
get_mix_format,
get_buffer_size,
get_latency,
get_current_padding,
get_next_packet_size,
get_frequency,
get_position,
set_volumes,
set_event_handle,
is_started,
midi_release,
midi_out_message,
midi_in_message,
midi_notify_wait,
aux_message,
};
NTSTATUS oss_midi_release(void *args) DECLSPEC_HIDDEN; NTSTATUS oss_midi_release(void *args) DECLSPEC_HIDDEN;
NTSTATUS oss_midi_out_message(void *args) DECLSPEC_HIDDEN; NTSTATUS oss_midi_out_message(void *args) DECLSPEC_HIDDEN;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment