[RFC PATCH 2/5] xaudio2_7: Load FAudio dynamically.
Rémi Bernon
rbernon at codeweavers.com
Wed Jun 23 07:37:24 CDT 2021
Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
---
dlls/x3daudio1_0/Makefile.in | 3 +-
dlls/x3daudio1_1/Makefile.in | 3 +-
dlls/x3daudio1_2/Makefile.in | 3 +-
dlls/x3daudio1_3/Makefile.in | 3 +-
dlls/x3daudio1_4/Makefile.in | 3 +-
dlls/x3daudio1_5/Makefile.in | 3 +-
dlls/x3daudio1_6/Makefile.in | 3 +-
dlls/x3daudio1_7/Makefile.in | 3 +-
dlls/xactengine2_0/Makefile.in | 3 +-
dlls/xactengine2_4/Makefile.in | 3 +-
dlls/xactengine2_7/Makefile.in | 3 +-
dlls/xactengine2_9/Makefile.in | 3 +-
dlls/xactengine3_0/Makefile.in | 3 +-
dlls/xactengine3_1/Makefile.in | 3 +-
dlls/xactengine3_2/Makefile.in | 3 +-
dlls/xactengine3_3/Makefile.in | 3 +-
dlls/xactengine3_4/Makefile.in | 3 +-
dlls/xactengine3_5/Makefile.in | 3 +-
dlls/xactengine3_6/Makefile.in | 3 +-
dlls/xactengine3_7/Makefile.in | 3 +-
dlls/xapofx1_1/Makefile.in | 3 +-
dlls/xapofx1_2/Makefile.in | 3 +-
dlls/xapofx1_3/Makefile.in | 3 +-
dlls/xapofx1_4/Makefile.in | 3 +-
dlls/xapofx1_5/Makefile.in | 3 +-
dlls/xaudio2_0/Makefile.in | 3 +-
dlls/xaudio2_1/Makefile.in | 3 +-
dlls/xaudio2_2/Makefile.in | 3 +-
dlls/xaudio2_3/Makefile.in | 3 +-
dlls/xaudio2_4/Makefile.in | 3 +-
dlls/xaudio2_5/Makefile.in | 3 +-
dlls/xaudio2_6/Makefile.in | 3 +-
dlls/xaudio2_7/Makefile.in | 3 +-
dlls/xaudio2_7/compat.c | 32 +--
dlls/xaudio2_7/faudio.c | 345 ++++++++++++++++++++++++++++++++
dlls/xaudio2_7/x3daudio.c | 28 ++-
dlls/xaudio2_7/xact_dll.c | 145 +++++++-------
dlls/xaudio2_7/xapo.c | 8 +-
dlls/xaudio2_7/xapofx.c | 19 ++
dlls/xaudio2_7/xaudio_dll.c | 168 ++++++++--------
dlls/xaudio2_7/xaudio_private.h | 151 +++++++++++++-
dlls/xaudio2_8/Makefile.in | 3 +-
dlls/xaudio2_9/Makefile.in | 3 +-
43 files changed, 789 insertions(+), 212 deletions(-)
create mode 100644 dlls/xaudio2_7/faudio.c
diff --git a/dlls/x3daudio1_0/Makefile.in b/dlls/x3daudio1_0/Makefile.in
index d2305be6f17..1fc804116be 100644
--- a/dlls/x3daudio1_0/Makefile.in
+++ b/dlls/x3daudio1_0/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=0 -DXAUDIO2_VER=0
MODULE = x3daudio1_0.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_1/Makefile.in b/dlls/x3daudio1_1/Makefile.in
index efe8d74539f..75cacbbdb27 100644
--- a/dlls/x3daudio1_1/Makefile.in
+++ b/dlls/x3daudio1_1/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=1 -DXAUDIO2_VER=1
MODULE = x3daudio1_1.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_2/Makefile.in b/dlls/x3daudio1_2/Makefile.in
index 3b52e063fc0..c621ba9bfe9 100644
--- a/dlls/x3daudio1_2/Makefile.in
+++ b/dlls/x3daudio1_2/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=2 -DXAUDIO2_VER=2
MODULE = x3daudio1_2.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_3/Makefile.in b/dlls/x3daudio1_3/Makefile.in
index 9afd1e64312..fb678cf19a3 100644
--- a/dlls/x3daudio1_3/Makefile.in
+++ b/dlls/x3daudio1_3/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=3 -DXAUDIO2_VER=3
MODULE = x3daudio1_3.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_4/Makefile.in b/dlls/x3daudio1_4/Makefile.in
index e481567cce0..66805bfc845 100644
--- a/dlls/x3daudio1_4/Makefile.in
+++ b/dlls/x3daudio1_4/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=4 -DXAUDIO2_VER=4
MODULE = x3daudio1_4.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_5/Makefile.in b/dlls/x3daudio1_5/Makefile.in
index 0a97959e7eb..3180ac41b17 100644
--- a/dlls/x3daudio1_5/Makefile.in
+++ b/dlls/x3daudio1_5/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=5 -DXAUDIO2_VER=5
MODULE = x3daudio1_5.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_6/Makefile.in b/dlls/x3daudio1_6/Makefile.in
index c88374a381f..54f46236d62 100644
--- a/dlls/x3daudio1_6/Makefile.in
+++ b/dlls/x3daudio1_6/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=6 -DXAUDIO2_VER=6
MODULE = x3daudio1_6.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/x3daudio1_7/Makefile.in b/dlls/x3daudio1_7/Makefile.in
index 267a93fd6da..a53a993019e 100644
--- a/dlls/x3daudio1_7/Makefile.in
+++ b/dlls/x3daudio1_7/Makefile.in
@@ -1,8 +1,9 @@
EXTRADEFS = -DX3DAUDIO1_VER=7 -DXAUDIO2_VER=7
MODULE = x3daudio1_7.dll
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
x3daudio.c
diff --git a/dlls/xactengine2_0/Makefile.in b/dlls/xactengine2_0/Makefile.in
index a15eeb03576..6a98d4df558 100644
--- a/dlls/xactengine2_0/Makefile.in
+++ b/dlls/xactengine2_0/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine2_0.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0200
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine2_4/Makefile.in b/dlls/xactengine2_4/Makefile.in
index 43d394dbb73..eef48ed32ea 100644
--- a/dlls/xactengine2_4/Makefile.in
+++ b/dlls/xactengine2_4/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine2_4.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0204
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine2_7/Makefile.in b/dlls/xactengine2_7/Makefile.in
index 74de611d059..bdc0c5565e3 100644
--- a/dlls/xactengine2_7/Makefile.in
+++ b/dlls/xactengine2_7/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine2_7.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0207
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine2_9/Makefile.in b/dlls/xactengine2_9/Makefile.in
index bbf66178aca..035b6276e37 100644
--- a/dlls/xactengine2_9/Makefile.in
+++ b/dlls/xactengine2_9/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine2_9.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0209
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_0/Makefile.in b/dlls/xactengine3_0/Makefile.in
index af23d203776..940d33560e2 100644
--- a/dlls/xactengine3_0/Makefile.in
+++ b/dlls/xactengine3_0/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_0.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0300
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_1/Makefile.in b/dlls/xactengine3_1/Makefile.in
index 6e8ff952c5d..683be88529e 100644
--- a/dlls/xactengine3_1/Makefile.in
+++ b/dlls/xactengine3_1/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_1.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0301
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_2/Makefile.in b/dlls/xactengine3_2/Makefile.in
index be054b53801..f8c0d9cec89 100644
--- a/dlls/xactengine3_2/Makefile.in
+++ b/dlls/xactengine3_2/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_2.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0302
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_3/Makefile.in b/dlls/xactengine3_3/Makefile.in
index 1b232bca8fe..8a5854a0813 100644
--- a/dlls/xactengine3_3/Makefile.in
+++ b/dlls/xactengine3_3/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_3.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0303
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_4/Makefile.in b/dlls/xactengine3_4/Makefile.in
index 47acf0763d8..024e96c3a17 100644
--- a/dlls/xactengine3_4/Makefile.in
+++ b/dlls/xactengine3_4/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_4.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0304
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_5/Makefile.in b/dlls/xactengine3_5/Makefile.in
index b171628fcde..9a1d7813b13 100644
--- a/dlls/xactengine3_5/Makefile.in
+++ b/dlls/xactengine3_5/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_5.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0305
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_6/Makefile.in b/dlls/xactengine3_6/Makefile.in
index fb09448023f..859fb906571 100644
--- a/dlls/xactengine3_6/Makefile.in
+++ b/dlls/xactengine3_6/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_6.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0306
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xactengine3_7/Makefile.in b/dlls/xactengine3_7/Makefile.in
index 535b1335087..4e606ad5a49 100644
--- a/dlls/xactengine3_7/Makefile.in
+++ b/dlls/xactengine3_7/Makefile.in
@@ -2,10 +2,11 @@ MODULE = xactengine3_7.dll
IMPORTS = ole32 uuid
EXTRADEFS = -DXACT3_VER=0x0307
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xact_dll.c
IDL_SRCS = xact_classes.idl
diff --git a/dlls/xapofx1_1/Makefile.in b/dlls/xapofx1_1/Makefile.in
index df40978ecde..58e07c94af8 100644
--- a/dlls/xapofx1_1/Makefile.in
+++ b/dlls/xapofx1_1/Makefile.in
@@ -2,10 +2,11 @@ EXTRADEFS = -DXAPOFX1_VER=1 -DXAUDIO2_VER=2
MODULE = xapofx1_1.dll
IMPORTS = ole32
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xapo.c \
xapofx.c \
xaudio_allocator.c
diff --git a/dlls/xapofx1_2/Makefile.in b/dlls/xapofx1_2/Makefile.in
index 5e70ad2625a..146a679ceff 100644
--- a/dlls/xapofx1_2/Makefile.in
+++ b/dlls/xapofx1_2/Makefile.in
@@ -2,10 +2,11 @@ EXTRADEFS = -DXAPOFX1_VER=2 -DXAUDIO2_VER=3
MODULE = xapofx1_2.dll
IMPORTS = ole32
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xapo.c \
xapofx.c \
xaudio_allocator.c
diff --git a/dlls/xapofx1_3/Makefile.in b/dlls/xapofx1_3/Makefile.in
index 5cf91a7c2c0..c9f4bd80d92 100644
--- a/dlls/xapofx1_3/Makefile.in
+++ b/dlls/xapofx1_3/Makefile.in
@@ -2,10 +2,11 @@ EXTRADEFS = -DXAPOFX1_VER=3 -DXAUDIO2_VER=4
MODULE = xapofx1_3.dll
IMPORTS = ole32
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xapo.c \
xapofx.c \
xaudio_allocator.c
diff --git a/dlls/xapofx1_4/Makefile.in b/dlls/xapofx1_4/Makefile.in
index ab1106fcf65..bd71b614bad 100644
--- a/dlls/xapofx1_4/Makefile.in
+++ b/dlls/xapofx1_4/Makefile.in
@@ -2,10 +2,11 @@ EXTRADEFS = -DXAPOFX1_VER=4 -DXAUDIO2_VER=6
MODULE = xapofx1_4.dll
IMPORTS = ole32
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xapo.c \
xapofx.c \
xaudio_allocator.c
diff --git a/dlls/xapofx1_5/Makefile.in b/dlls/xapofx1_5/Makefile.in
index bda50c04866..42eadd12614 100644
--- a/dlls/xapofx1_5/Makefile.in
+++ b/dlls/xapofx1_5/Makefile.in
@@ -2,10 +2,11 @@ EXTRADEFS = -DXAPOFX1_VER=5 -DXAUDIO2_VER=7
MODULE = xapofx1_5.dll
IMPORTS = ole32
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
+ faudio.c \
xapo.c \
xapofx.c \
xaudio_allocator.c
diff --git a/dlls/xaudio2_0/Makefile.in b/dlls/xaudio2_0/Makefile.in
index 4f766b82450..9e981603db4 100644
--- a/dlls/xaudio2_0/Makefile.in
+++ b/dlls/xaudio2_0/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=0
MODULE = xaudio2_0.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_1/Makefile.in b/dlls/xaudio2_1/Makefile.in
index 9e50adfa8e2..fc81d653ab3 100644
--- a/dlls/xaudio2_1/Makefile.in
+++ b/dlls/xaudio2_1/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=1
MODULE = xaudio2_1.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_2/Makefile.in b/dlls/xaudio2_2/Makefile.in
index b7076fea4e1..f4b0e4578b8 100644
--- a/dlls/xaudio2_2/Makefile.in
+++ b/dlls/xaudio2_2/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=2
MODULE = xaudio2_2.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_3/Makefile.in b/dlls/xaudio2_3/Makefile.in
index a1140f83363..d9337240350 100644
--- a/dlls/xaudio2_3/Makefile.in
+++ b/dlls/xaudio2_3/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=3
MODULE = xaudio2_3.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_4/Makefile.in b/dlls/xaudio2_4/Makefile.in
index 6d1f5e4e71f..0a8b6277b8e 100644
--- a/dlls/xaudio2_4/Makefile.in
+++ b/dlls/xaudio2_4/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=4
MODULE = xaudio2_4.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_5/Makefile.in b/dlls/xaudio2_5/Makefile.in
index d65b4bd1ed2..5805a4d7629 100644
--- a/dlls/xaudio2_5/Makefile.in
+++ b/dlls/xaudio2_5/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=5
MODULE = xaudio2_5.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_6/Makefile.in b/dlls/xaudio2_6/Makefile.in
index 3bcc930e265..3dd582e512e 100644
--- a/dlls/xaudio2_6/Makefile.in
+++ b/dlls/xaudio2_6/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=6
MODULE = xaudio2_6.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
xapo.c \
xaudio_allocator.c \
xaudio_dll.c
diff --git a/dlls/xaudio2_7/Makefile.in b/dlls/xaudio2_7/Makefile.in
index 294f841b019..26ced808cc6 100644
--- a/dlls/xaudio2_7/Makefile.in
+++ b/dlls/xaudio2_7/Makefile.in
@@ -1,11 +1,12 @@
EXTRADEFS = -DXAUDIO2_VER=7
MODULE = xaudio2_7.dll
IMPORTS = advapi32 ole32 user32 uuid
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
x3daudio.c \
xapo.c \
xapofx.c \
diff --git a/dlls/xaudio2_7/compat.c b/dlls/xaudio2_7/compat.c
index c4538ae3677..e756736e23f 100644
--- a/dlls/xaudio2_7/compat.c
+++ b/dlls/xaudio2_7/compat.c
@@ -2049,7 +2049,7 @@ static HRESULT WINAPI XA20_GetDeviceCount(IXAudio20 *iface, UINT32 *pCount)
{
IXAudio2Impl *This = impl_from_IXAudio20(iface);
TRACE("%p, %p\n", This, pCount);
- return FAudio_GetDeviceCount(This->faudio, pCount);
+ return pFAudio_GetDeviceCount(This->faudio, pCount);
}
static HRESULT WINAPI XA20_GetDeviceDetails(IXAudio20 *iface, UINT32 index,
@@ -2057,7 +2057,7 @@ static HRESULT WINAPI XA20_GetDeviceDetails(IXAudio20 *iface, UINT32 index,
{
IXAudio2Impl *This = impl_from_IXAudio20(iface);
TRACE("%p, %u, %p\n", This, index, pDeviceDetails);
- return FAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
+ return pFAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
}
static HRESULT WINAPI XA20_Initialize(IXAudio20 *iface, UINT32 flags,
@@ -2170,9 +2170,9 @@ static HRESULT WINAPI XA20_CreateMasteringVoice(IXAudio20 *iface,
pthread_mutex_unlock(&This->mst.engine_lock);
- FAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
+ pFAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
- FAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
+ pFAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
inputSampleRate, flags, deviceIndex, This->mst.effect_chain);
This->mst.in_use = TRUE;
@@ -2284,7 +2284,7 @@ static HRESULT WINAPI XA22_GetDeviceCount(IXAudio22 *iface, UINT32 *pCount)
{
IXAudio2Impl *This = impl_from_IXAudio22(iface);
TRACE("%p, %p\n", This, pCount);
- return FAudio_GetDeviceCount(This->faudio, pCount);
+ return pFAudio_GetDeviceCount(This->faudio, pCount);
}
static HRESULT WINAPI XA22_GetDeviceDetails(IXAudio22 *iface, UINT32 index,
@@ -2292,7 +2292,7 @@ static HRESULT WINAPI XA22_GetDeviceDetails(IXAudio22 *iface, UINT32 index,
{
IXAudio2Impl *This = impl_from_IXAudio22(iface);
TRACE("%p, %u, %p\n", This, index, pDeviceDetails);
- return FAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
+ return pFAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
}
static HRESULT WINAPI XA22_Initialize(IXAudio22 *iface, UINT32 flags,
@@ -2405,9 +2405,9 @@ static HRESULT WINAPI XA22_CreateMasteringVoice(IXAudio22 *iface,
pthread_mutex_unlock(&This->mst.engine_lock);
- FAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
+ pFAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
- FAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
+ pFAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
inputSampleRate, flags, deviceIndex, This->mst.effect_chain);
This->mst.in_use = TRUE;
@@ -2518,7 +2518,7 @@ static HRESULT WINAPI XA23_GetDeviceCount(IXAudio23 *iface, UINT32 *pCount)
{
IXAudio2Impl *This = impl_from_IXAudio23(iface);
TRACE("%p, %p\n", This, pCount);
- return FAudio_GetDeviceCount(This->faudio, pCount);
+ return pFAudio_GetDeviceCount(This->faudio, pCount);
}
static HRESULT WINAPI XA23_GetDeviceDetails(IXAudio23 *iface, UINT32 index,
@@ -2526,7 +2526,7 @@ static HRESULT WINAPI XA23_GetDeviceDetails(IXAudio23 *iface, UINT32 index,
{
IXAudio2Impl *This = impl_from_IXAudio23(iface);
TRACE("%p, %u, %p\n", This, index, pDeviceDetails);
- return FAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
+ return pFAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
}
static HRESULT WINAPI XA23_Initialize(IXAudio23 *iface, UINT32 flags,
@@ -2639,9 +2639,9 @@ static HRESULT WINAPI XA23_CreateMasteringVoice(IXAudio23 *iface,
pthread_mutex_unlock(&This->mst.engine_lock);
- FAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
+ pFAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
- FAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
+ pFAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
inputSampleRate, flags, deviceIndex, This->mst.effect_chain);
This->mst.in_use = TRUE;
@@ -2734,7 +2734,7 @@ static HRESULT WINAPI XA27_GetDeviceCount(IXAudio27 *iface, UINT32 *pCount)
{
IXAudio2Impl *This = impl_from_IXAudio27(iface);
TRACE("%p, %p\n", This, pCount);
- return FAudio_GetDeviceCount(This->faudio, pCount);
+ return pFAudio_GetDeviceCount(This->faudio, pCount);
}
static HRESULT WINAPI XA27_GetDeviceDetails(IXAudio27 *iface, UINT32 index,
@@ -2742,7 +2742,7 @@ static HRESULT WINAPI XA27_GetDeviceDetails(IXAudio27 *iface, UINT32 index,
{
IXAudio2Impl *This = impl_from_IXAudio27(iface);
TRACE("%p, %u, %p\n", This, index, pDeviceDetails);
- return FAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
+ return pFAudio_GetDeviceDetails(This->faudio, index, (FAudioDeviceDetails *)pDeviceDetails);
}
static HRESULT WINAPI XA27_Initialize(IXAudio27 *iface, UINT32 flags,
@@ -2827,9 +2827,9 @@ static HRESULT WINAPI XA27_CreateMasteringVoice(IXAudio27 *iface,
pthread_mutex_unlock(&This->mst.engine_lock);
- FAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
+ pFAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
- FAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
+ pFAudio_CreateMasteringVoice(This->faudio, &This->mst.faudio_voice, inputChannels,
inputSampleRate, flags, deviceIndex, This->mst.effect_chain);
This->mst.in_use = TRUE;
diff --git a/dlls/xaudio2_7/faudio.c b/dlls/xaudio2_7/faudio.c
new file mode 100644
index 00000000000..0858b79d973
--- /dev/null
+++ b/dlls/xaudio2_7/faudio.c
@@ -0,0 +1,345 @@
+/*
+ * Copyright 2021 Rémi Bernon for CodeWeavers
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "config.h"
+
+#include <stdarg.h>
+#include <dlfcn.h>
+
+#define NONAMELESSUNION
+#define COBJMACROS
+
+#include "xaudio_private.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(xaudio2);
+
+#define MAKE_FUNCPTR(f) typeof(f) * p##f = NULL;
+MAKE_FUNCPTR(FAudio_AddRef)
+#ifdef HAVE_FAUDIO_COMMITOPERATIONSET
+MAKE_FUNCPTR(FAudio_CommitOperationSet)
+#else
+MAKE_FUNCPTR(FAudio_CommitChanges)
+#endif
+MAKE_FUNCPTR(FAudio_CreateMasteringVoice)
+MAKE_FUNCPTR(FAudio_CreateMasteringVoice8)
+MAKE_FUNCPTR(FAudio_CreateSourceVoice)
+MAKE_FUNCPTR(FAudio_CreateSubmixVoice)
+MAKE_FUNCPTR(FAudio_GetDeviceCount)
+MAKE_FUNCPTR(FAudio_GetDeviceDetails)
+MAKE_FUNCPTR(FAudio_GetPerformanceData)
+MAKE_FUNCPTR(FAudio_Initialize)
+MAKE_FUNCPTR(FAudio_RegisterForCallbacks)
+MAKE_FUNCPTR(FAudio_Release)
+MAKE_FUNCPTR(FAudio_SetDebugConfiguration)
+MAKE_FUNCPTR(FAudio_StartEngine)
+MAKE_FUNCPTR(FAudio_StopEngine)
+
+MAKE_FUNCPTR(FAudioVoice_DestroyVoice)
+MAKE_FUNCPTR(FAudioVoice_DisableEffect)
+MAKE_FUNCPTR(FAudioVoice_EnableEffect)
+MAKE_FUNCPTR(FAudioVoice_GetChannelVolumes)
+MAKE_FUNCPTR(FAudioVoice_GetEffectParameters)
+MAKE_FUNCPTR(FAudioVoice_GetEffectState)
+MAKE_FUNCPTR(FAudioVoice_GetFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_GetOutputFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_GetOutputMatrix)
+MAKE_FUNCPTR(FAudioVoice_GetVoiceDetails)
+MAKE_FUNCPTR(FAudioVoice_GetVolume)
+MAKE_FUNCPTR(FAudioVoice_SetChannelVolumes)
+MAKE_FUNCPTR(FAudioVoice_SetEffectChain)
+MAKE_FUNCPTR(FAudioVoice_SetEffectParameters)
+MAKE_FUNCPTR(FAudioVoice_SetFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_SetOutputFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_SetOutputMatrix)
+MAKE_FUNCPTR(FAudioVoice_SetOutputVoices)
+MAKE_FUNCPTR(FAudioVoice_SetVolume)
+
+MAKE_FUNCPTR(FAudioSourceVoice_Discontinuity)
+MAKE_FUNCPTR(FAudioSourceVoice_ExitLoop)
+MAKE_FUNCPTR(FAudioSourceVoice_FlushSourceBuffers)
+MAKE_FUNCPTR(FAudioSourceVoice_GetFrequencyRatio)
+MAKE_FUNCPTR(FAudioSourceVoice_GetState)
+MAKE_FUNCPTR(FAudioSourceVoice_SetFrequencyRatio)
+MAKE_FUNCPTR(FAudioSourceVoice_SetSourceSampleRate)
+MAKE_FUNCPTR(FAudioSourceVoice_Start)
+MAKE_FUNCPTR(FAudioSourceVoice_Stop)
+MAKE_FUNCPTR(FAudioSourceVoice_SubmitSourceBuffer)
+
+MAKE_FUNCPTR(FAudioMasteringVoice_GetChannelMask)
+
+MAKE_FUNCPTR(FAudioCOMConstructWithCustomAllocatorEXT)
+MAKE_FUNCPTR(FAudioCreate)
+MAKE_FUNCPTR(FAudioCreateReverb)
+MAKE_FUNCPTR(FAudioCreateReverb9)
+#ifdef HAVE_FAUDIOCREATEREVERB9WITHCUSTOMALLOCATOREXT
+MAKE_FUNCPTR(FAudioCreateReverb9WithCustomAllocatorEXT)
+#endif
+MAKE_FUNCPTR(FAudioCreateReverbWithCustomAllocatorEXT)
+MAKE_FUNCPTR(FAudioCreateVolumeMeter)
+MAKE_FUNCPTR(FAudioCreateVolumeMeterWithCustomAllocatorEXT)
+#ifdef HAVE_FAUDIOLINKEDVERSION
+MAKE_FUNCPTR(FAudioLinkedVersion)
+#endif
+
+MAKE_FUNCPTR(F3DAudioCalculate)
+MAKE_FUNCPTR(F3DAudioInitialize)
+#ifdef HAVE_F3DAUDIOINITIALIZE8
+MAKE_FUNCPTR(F3DAudioInitialize8)
+#endif
+
+MAKE_FUNCPTR(FACTAudioEngine_AddRef)
+MAKE_FUNCPTR(FACTAudioEngine_CreateInMemoryWaveBank)
+MAKE_FUNCPTR(FACTAudioEngine_CreateSoundBank)
+MAKE_FUNCPTR(FACTAudioEngine_CreateStreamingWaveBank)
+MAKE_FUNCPTR(FACTAudioEngine_DoWork)
+MAKE_FUNCPTR(FACTAudioEngine_GetCategory)
+MAKE_FUNCPTR(FACTAudioEngine_GetFinalMixFormat)
+MAKE_FUNCPTR(FACTAudioEngine_GetGlobalVariable)
+MAKE_FUNCPTR(FACTAudioEngine_GetGlobalVariableIndex)
+MAKE_FUNCPTR(FACTAudioEngine_GetRendererCount)
+MAKE_FUNCPTR(FACTAudioEngine_GetRendererDetails)
+MAKE_FUNCPTR(FACTAudioEngine_Initialize)
+MAKE_FUNCPTR(FACTAudioEngine_Pause)
+MAKE_FUNCPTR(FACTAudioEngine_PrepareWave)
+MAKE_FUNCPTR(FACTAudioEngine_RegisterNotification)
+MAKE_FUNCPTR(FACTAudioEngine_Release)
+MAKE_FUNCPTR(FACTAudioEngine_SetGlobalVariable)
+MAKE_FUNCPTR(FACTAudioEngine_SetVolume)
+MAKE_FUNCPTR(FACTAudioEngine_ShutDown)
+MAKE_FUNCPTR(FACTAudioEngine_Stop)
+MAKE_FUNCPTR(FACTAudioEngine_UnRegisterNotification)
+
+MAKE_FUNCPTR(FACTCreateEngineWithCustomAllocatorEXT)
+
+MAKE_FUNCPTR(FACTCue_Destroy)
+MAKE_FUNCPTR(FACTCue_GetProperties)
+MAKE_FUNCPTR(FACTCue_GetState)
+MAKE_FUNCPTR(FACTCue_GetVariable)
+MAKE_FUNCPTR(FACTCue_GetVariableIndex)
+MAKE_FUNCPTR(FACTCue_Pause)
+MAKE_FUNCPTR(FACTCue_Play)
+MAKE_FUNCPTR(FACTCue_SetMatrixCoefficients)
+MAKE_FUNCPTR(FACTCue_SetVariable)
+MAKE_FUNCPTR(FACTCue_Stop)
+
+MAKE_FUNCPTR(FACTSoundBank_Destroy)
+MAKE_FUNCPTR(FACTSoundBank_GetCueIndex)
+MAKE_FUNCPTR(FACTSoundBank_GetCueProperties)
+MAKE_FUNCPTR(FACTSoundBank_GetNumCues)
+MAKE_FUNCPTR(FACTSoundBank_GetState)
+MAKE_FUNCPTR(FACTSoundBank_Play)
+MAKE_FUNCPTR(FACTSoundBank_Prepare)
+MAKE_FUNCPTR(FACTSoundBank_Stop)
+
+MAKE_FUNCPTR(FACTWave_Destroy)
+MAKE_FUNCPTR(FACTWave_GetProperties)
+MAKE_FUNCPTR(FACTWave_GetState)
+MAKE_FUNCPTR(FACTWave_Pause)
+MAKE_FUNCPTR(FACTWave_Play)
+MAKE_FUNCPTR(FACTWave_SetMatrixCoefficients)
+MAKE_FUNCPTR(FACTWave_SetPitch)
+MAKE_FUNCPTR(FACTWave_SetVolume)
+MAKE_FUNCPTR(FACTWave_Stop)
+
+MAKE_FUNCPTR(FACTWaveBank_Destroy)
+MAKE_FUNCPTR(FACTWaveBank_GetNumWaves)
+MAKE_FUNCPTR(FACTWaveBank_GetState)
+MAKE_FUNCPTR(FACTWaveBank_GetWaveIndex)
+MAKE_FUNCPTR(FACTWaveBank_GetWaveProperties)
+MAKE_FUNCPTR(FACTWaveBank_Play)
+MAKE_FUNCPTR(FACTWaveBank_Prepare)
+MAKE_FUNCPTR(FACTWaveBank_Stop)
+
+MAKE_FUNCPTR(FAPOFX_CreateFXWithCustomAllocatorEXT)
+#undef MAKE_FUNCPTR
+
+#ifdef SONAME_LIBFAUDIO
+
+BOOL load_faudio(void)
+{
+ void *faudio;
+
+ if (!(faudio = dlopen( SONAME_LIBFAUDIO, RTLD_NOW )))
+ {
+ ERR( "FAudio library %s not found.\n", SONAME_LIBFAUDIO );
+ return FALSE;
+ }
+
+#define LOAD_FUNCPTR(f) \
+ if (!(p##f = dlsym( faudio, #f ))) \
+ { \
+ ERR( "FAudio function %s not found\n", #f ); \
+ dlclose( faudio ); \
+ return FALSE; \
+ }
+LOAD_FUNCPTR(FAudio_AddRef)
+#ifdef HAVE_FAUDIO_COMMITOPERATIONSET
+LOAD_FUNCPTR(FAudio_CommitOperationSet)
+#else
+LOAD_FUNCPTR(FAudio_CommitChanges)
+#endif
+LOAD_FUNCPTR(FAudio_CreateMasteringVoice)
+LOAD_FUNCPTR(FAudio_CreateMasteringVoice8)
+LOAD_FUNCPTR(FAudio_CreateSourceVoice)
+LOAD_FUNCPTR(FAudio_CreateSubmixVoice)
+LOAD_FUNCPTR(FAudio_GetDeviceCount)
+LOAD_FUNCPTR(FAudio_GetDeviceDetails)
+LOAD_FUNCPTR(FAudio_GetPerformanceData)
+LOAD_FUNCPTR(FAudio_Initialize)
+LOAD_FUNCPTR(FAudio_RegisterForCallbacks)
+LOAD_FUNCPTR(FAudio_Release)
+LOAD_FUNCPTR(FAudio_SetDebugConfiguration)
+LOAD_FUNCPTR(FAudio_StartEngine)
+LOAD_FUNCPTR(FAudio_StopEngine)
+
+LOAD_FUNCPTR(FAudioVoice_DestroyVoice)
+LOAD_FUNCPTR(FAudioVoice_DisableEffect)
+LOAD_FUNCPTR(FAudioVoice_EnableEffect)
+LOAD_FUNCPTR(FAudioVoice_GetChannelVolumes)
+LOAD_FUNCPTR(FAudioVoice_GetEffectParameters)
+LOAD_FUNCPTR(FAudioVoice_GetEffectState)
+LOAD_FUNCPTR(FAudioVoice_GetFilterParameters)
+LOAD_FUNCPTR(FAudioVoice_GetOutputFilterParameters)
+LOAD_FUNCPTR(FAudioVoice_GetOutputMatrix)
+LOAD_FUNCPTR(FAudioVoice_GetVoiceDetails)
+LOAD_FUNCPTR(FAudioVoice_GetVolume)
+LOAD_FUNCPTR(FAudioVoice_SetChannelVolumes)
+LOAD_FUNCPTR(FAudioVoice_SetEffectChain)
+LOAD_FUNCPTR(FAudioVoice_SetEffectParameters)
+LOAD_FUNCPTR(FAudioVoice_SetFilterParameters)
+LOAD_FUNCPTR(FAudioVoice_SetOutputFilterParameters)
+LOAD_FUNCPTR(FAudioVoice_SetOutputMatrix)
+LOAD_FUNCPTR(FAudioVoice_SetOutputVoices)
+LOAD_FUNCPTR(FAudioVoice_SetVolume)
+
+LOAD_FUNCPTR(FAudioSourceVoice_Discontinuity)
+LOAD_FUNCPTR(FAudioSourceVoice_ExitLoop)
+LOAD_FUNCPTR(FAudioSourceVoice_FlushSourceBuffers)
+LOAD_FUNCPTR(FAudioSourceVoice_GetFrequencyRatio)
+LOAD_FUNCPTR(FAudioSourceVoice_GetState)
+LOAD_FUNCPTR(FAudioSourceVoice_SetFrequencyRatio)
+LOAD_FUNCPTR(FAudioSourceVoice_SetSourceSampleRate)
+LOAD_FUNCPTR(FAudioSourceVoice_Start)
+LOAD_FUNCPTR(FAudioSourceVoice_Stop)
+LOAD_FUNCPTR(FAudioSourceVoice_SubmitSourceBuffer)
+
+LOAD_FUNCPTR(FAudioMasteringVoice_GetChannelMask)
+
+LOAD_FUNCPTR(FAudioCOMConstructWithCustomAllocatorEXT)
+LOAD_FUNCPTR(FAudioCreate)
+LOAD_FUNCPTR(FAudioCreateReverb)
+LOAD_FUNCPTR(FAudioCreateReverb9)
+#ifdef HAVE_FAUDIOCREATEREVERB9WITHCUSTOMALLOCATOREXT
+LOAD_FUNCPTR(FAudioCreateReverb9WithCustomAllocatorEXT)
+#endif
+LOAD_FUNCPTR(FAudioCreateReverbWithCustomAllocatorEXT)
+LOAD_FUNCPTR(FAudioCreateVolumeMeter)
+LOAD_FUNCPTR(FAudioCreateVolumeMeterWithCustomAllocatorEXT)
+#ifdef HAVE_FAUDIOLINKEDVERSION
+LOAD_FUNCPTR(FAudioLinkedVersion)
+#endif
+
+LOAD_FUNCPTR(F3DAudioCalculate)
+LOAD_FUNCPTR(F3DAudioInitialize)
+#ifdef HAVE_F3DAUDIOINITIALIZE8
+LOAD_FUNCPTR(F3DAudioInitialize8)
+#endif
+
+LOAD_FUNCPTR(FACTAudioEngine_AddRef)
+LOAD_FUNCPTR(FACTAudioEngine_CreateInMemoryWaveBank)
+LOAD_FUNCPTR(FACTAudioEngine_CreateSoundBank)
+LOAD_FUNCPTR(FACTAudioEngine_CreateStreamingWaveBank)
+LOAD_FUNCPTR(FACTAudioEngine_DoWork)
+LOAD_FUNCPTR(FACTAudioEngine_GetCategory)
+LOAD_FUNCPTR(FACTAudioEngine_GetFinalMixFormat)
+LOAD_FUNCPTR(FACTAudioEngine_GetGlobalVariable)
+LOAD_FUNCPTR(FACTAudioEngine_GetGlobalVariableIndex)
+LOAD_FUNCPTR(FACTAudioEngine_GetRendererCount)
+LOAD_FUNCPTR(FACTAudioEngine_GetRendererDetails)
+LOAD_FUNCPTR(FACTAudioEngine_Initialize)
+LOAD_FUNCPTR(FACTAudioEngine_Pause)
+LOAD_FUNCPTR(FACTAudioEngine_PrepareWave)
+LOAD_FUNCPTR(FACTAudioEngine_RegisterNotification)
+LOAD_FUNCPTR(FACTAudioEngine_Release)
+LOAD_FUNCPTR(FACTAudioEngine_SetGlobalVariable)
+LOAD_FUNCPTR(FACTAudioEngine_SetVolume)
+LOAD_FUNCPTR(FACTAudioEngine_ShutDown)
+LOAD_FUNCPTR(FACTAudioEngine_Stop)
+LOAD_FUNCPTR(FACTAudioEngine_UnRegisterNotification)
+
+LOAD_FUNCPTR(FACTCreateEngineWithCustomAllocatorEXT)
+
+LOAD_FUNCPTR(FACTCue_Destroy)
+LOAD_FUNCPTR(FACTCue_GetProperties)
+LOAD_FUNCPTR(FACTCue_GetState)
+LOAD_FUNCPTR(FACTCue_GetVariable)
+LOAD_FUNCPTR(FACTCue_GetVariableIndex)
+LOAD_FUNCPTR(FACTCue_Pause)
+LOAD_FUNCPTR(FACTCue_Play)
+LOAD_FUNCPTR(FACTCue_SetMatrixCoefficients)
+LOAD_FUNCPTR(FACTCue_SetVariable)
+LOAD_FUNCPTR(FACTCue_Stop)
+
+LOAD_FUNCPTR(FACTSoundBank_Destroy)
+LOAD_FUNCPTR(FACTSoundBank_GetCueIndex)
+LOAD_FUNCPTR(FACTSoundBank_GetCueProperties)
+LOAD_FUNCPTR(FACTSoundBank_GetNumCues)
+LOAD_FUNCPTR(FACTSoundBank_GetState)
+LOAD_FUNCPTR(FACTSoundBank_Play)
+LOAD_FUNCPTR(FACTSoundBank_Prepare)
+LOAD_FUNCPTR(FACTSoundBank_Stop)
+
+LOAD_FUNCPTR(FACTWave_Destroy)
+LOAD_FUNCPTR(FACTWave_GetProperties)
+LOAD_FUNCPTR(FACTWave_GetState)
+LOAD_FUNCPTR(FACTWave_Pause)
+LOAD_FUNCPTR(FACTWave_Play)
+LOAD_FUNCPTR(FACTWave_SetMatrixCoefficients)
+LOAD_FUNCPTR(FACTWave_SetPitch)
+LOAD_FUNCPTR(FACTWave_SetVolume)
+LOAD_FUNCPTR(FACTWave_Stop)
+
+LOAD_FUNCPTR(FACTWaveBank_Destroy)
+LOAD_FUNCPTR(FACTWaveBank_GetNumWaves)
+LOAD_FUNCPTR(FACTWaveBank_GetState)
+LOAD_FUNCPTR(FACTWaveBank_GetWaveIndex)
+LOAD_FUNCPTR(FACTWaveBank_GetWaveProperties)
+LOAD_FUNCPTR(FACTWaveBank_Play)
+LOAD_FUNCPTR(FACTWaveBank_Prepare)
+LOAD_FUNCPTR(FACTWaveBank_Stop)
+
+LOAD_FUNCPTR(FAPOFX_CreateFXWithCustomAllocatorEXT)
+#undef LOAD_FUNCPTR
+
+ return TRUE;
+}
+
+#else /* SONAME_LIBFAUDIO */
+
+BOOL load_faudio(void)
+{
+ ERR( "FAudio support not compiled in.\n" );
+ return FALSE;
+}
+
+#endif /* SONAME_LIBFAUDIO */
+
+void unload_faudio(void)
+{
+}
diff --git a/dlls/xaudio2_7/x3daudio.c b/dlls/xaudio2_7/x3daudio.c
index e0a0280c3cd..f07a1282150 100644
--- a/dlls/xaudio2_7/x3daudio.c
+++ b/dlls/xaudio2_7/x3daudio.c
@@ -24,6 +24,7 @@
#include "windef.h"
#include "winbase.h"
#include "x3daudio.h"
+#include "xaudio_private.h"
#include "wine/debug.h"
@@ -33,15 +34,34 @@
WINE_DEFAULT_DEBUG_CHANNEL(xaudio2);
#endif
+#ifdef X3DAUDIO1_VER
+BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, LPVOID reserved)
+{
+ TRACE("inst %p, reason %d, reserved %p.\n", inst, reason, reserved );
+
+ switch (reason)
+ {
+ case DLL_PROCESS_ATTACH:
+ DisableThreadLibraryCalls(inst);
+ if (!load_faudio()) return FALSE;
+ break;
+ case DLL_PROCESS_DETACH:
+ unload_faudio();
+ break;
+ }
+ return TRUE;
+}
+#endif /* X3DAUDIO1_VER */
+
#if XAUDIO2_VER >= 8
HRESULT CDECL X3DAudioInitialize(UINT32 chanmask, float speedofsound,
X3DAUDIO_HANDLE handle)
{
TRACE("0x%x, %f, %p\n", chanmask, speedofsound, handle);
#ifdef HAVE_F3DAUDIOINITIALIZE8
- return F3DAudioInitialize8(chanmask, speedofsound, handle);
+ return pF3DAudioInitialize8(chanmask, speedofsound, handle);
#else
- F3DAudioInitialize(chanmask, speedofsound, handle);
+ pF3DAudioInitialize(chanmask, speedofsound, handle);
return S_OK;
#endif
}
@@ -57,7 +77,7 @@ void CDECL LEGACY_X3DAudioInitialize(UINT32 chanmask, float speedofsound,
#endif
{
TRACE("0x%x, %f, %p\n", chanmask, speedofsound, handle);
- F3DAudioInitialize(chanmask, speedofsound, handle);
+ pF3DAudioInitialize(chanmask, speedofsound, handle);
}
#endif /* X3DAUDIO1_VER */
@@ -73,7 +93,7 @@ void CDECL X3DAudioCalculate(const X3DAUDIO_HANDLE handle,
#endif
{
TRACE("%p, %p, %p, 0x%x, %p\n", handle, listener, emitter, flags, out);
- F3DAudioCalculate(
+ pF3DAudioCalculate(
handle,
(const F3DAUDIO_LISTENER*) listener,
(const F3DAUDIO_EMITTER*) emitter,
diff --git a/dlls/xaudio2_7/xact_dll.c b/dlls/xaudio2_7/xact_dll.c
index 231ef753f22..229980216f7 100644
--- a/dlls/xaudio2_7/xact_dll.c
+++ b/dlls/xaudio2_7/xact_dll.c
@@ -25,6 +25,7 @@
#define COBJMACROS
#include "initguid.h"
+#include "xaudio_private.h"
#if XACT3_VER < 0x0300
#include "xact.h"
#else
@@ -66,7 +67,7 @@ static HRESULT WINAPI IXACT3CueImpl_Play(IXACT3Cue *iface)
TRACE("(%p)\n", iface);
- return FACTCue_Play(This->fact_cue);
+ return pFACTCue_Play(This->fact_cue);
}
static HRESULT WINAPI IXACT3CueImpl_Stop(IXACT3Cue *iface, DWORD dwFlags)
@@ -75,7 +76,7 @@ static HRESULT WINAPI IXACT3CueImpl_Stop(IXACT3Cue *iface, DWORD dwFlags)
TRACE("(%p)->(%u)\n", iface, dwFlags);
- return FACTCue_Stop(This->fact_cue, dwFlags);
+ return pFACTCue_Stop(This->fact_cue, dwFlags);
}
static HRESULT WINAPI IXACT3CueImpl_GetState(IXACT3Cue *iface, DWORD *pdwState)
@@ -84,7 +85,7 @@ static HRESULT WINAPI IXACT3CueImpl_GetState(IXACT3Cue *iface, DWORD *pdwState)
TRACE("(%p)->(%p)\n", iface, pdwState);
- return FACTCue_GetState(This->fact_cue, pdwState);
+ return pFACTCue_GetState(This->fact_cue, pdwState);
}
static HRESULT WINAPI IXACT3CueImpl_Destroy(IXACT3Cue *iface)
@@ -94,9 +95,9 @@ static HRESULT WINAPI IXACT3CueImpl_Destroy(IXACT3Cue *iface)
TRACE("(%p)\n", iface);
- ret = FACTCue_Destroy(This->fact_cue);
+ ret = pFACTCue_Destroy(This->fact_cue);
if (ret != 0)
- WARN("FACTCue_Destroy returned %d\n", ret);
+ WARN("pFACTCue_Destroy returned %d\n", ret);
HeapFree(GetProcessHeap(), 0, This);
return S_OK;
}
@@ -143,7 +144,7 @@ static HRESULT WINAPI IXACT3CueImpl_SetMatrixCoefficients(IXACT3Cue *iface,
TRACE("(%p)->(%u, %u, %p)\n", iface, uSrcChannelCount, uDstChannelCount,
pMatrixCoefficients);
- return FACTCue_SetMatrixCoefficients(This->fact_cue, uSrcChannelCount,
+ return pFACTCue_SetMatrixCoefficients(This->fact_cue, uSrcChannelCount,
uDstChannelCount, pMatrixCoefficients);
}
@@ -154,7 +155,7 @@ static XACTVARIABLEINDEX WINAPI IXACT3CueImpl_GetVariableIndex(IXACT3Cue *iface,
TRACE("(%p)->(%s)\n", iface, szFriendlyName);
- return FACTCue_GetVariableIndex(This->fact_cue, szFriendlyName);
+ return pFACTCue_GetVariableIndex(This->fact_cue, szFriendlyName);
}
static HRESULT WINAPI IXACT3CueImpl_SetVariable(IXACT3Cue *iface,
@@ -164,7 +165,7 @@ static HRESULT WINAPI IXACT3CueImpl_SetVariable(IXACT3Cue *iface,
TRACE("(%p)->(%u, %f)\n", iface, nIndex, nValue);
- return FACTCue_SetVariable(This->fact_cue, nIndex, nValue);
+ return pFACTCue_SetVariable(This->fact_cue, nIndex, nValue);
}
static HRESULT WINAPI IXACT3CueImpl_GetVariable(IXACT3Cue *iface,
@@ -174,7 +175,7 @@ static HRESULT WINAPI IXACT3CueImpl_GetVariable(IXACT3Cue *iface,
TRACE("(%p)->(%u, %p)\n", iface, nIndex, nValue);
- return FACTCue_GetVariable(This->fact_cue, nIndex, nValue);
+ return pFACTCue_GetVariable(This->fact_cue, nIndex, nValue);
}
static HRESULT WINAPI IXACT3CueImpl_Pause(IXACT3Cue *iface, BOOL fPause)
@@ -183,7 +184,7 @@ static HRESULT WINAPI IXACT3CueImpl_Pause(IXACT3Cue *iface, BOOL fPause)
TRACE("(%p)->(%u)\n", iface, fPause);
- return FACTCue_Pause(This->fact_cue, fPause);
+ return pFACTCue_Pause(This->fact_cue, fPause);
}
#if XACT3_VER >= 0x0205
@@ -196,7 +197,7 @@ static HRESULT WINAPI IXACT3CueImpl_GetProperties(IXACT3Cue *iface,
TRACE("(%p)->(%p)\n", iface, ppProperties);
- hr = FACTCue_GetProperties(This->fact_cue, &fProps);
+ hr = pFACTCue_GetProperties(This->fact_cue, &fProps);
if(FAILED(hr))
return hr;
@@ -269,7 +270,7 @@ static XACTINDEX WINAPI IXACT3SoundBankImpl_GetCueIndex(IXACT3SoundBank *iface,
TRACE("(%p)->(%s)\n", This, szFriendlyName);
- return FACTSoundBank_GetCueIndex(This->fact_soundbank, szFriendlyName);
+ return pFACTSoundBank_GetCueIndex(This->fact_soundbank, szFriendlyName);
}
#if XACT3_VER >= 0x0205
@@ -280,7 +281,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_GetNumCues(IXACT3SoundBank *iface,
TRACE("(%p)->(%p)\n", This, pnNumCues);
- return FACTSoundBank_GetNumCues(This->fact_soundbank, pnNumCues);
+ return pFACTSoundBank_GetNumCues(This->fact_soundbank, pnNumCues);
}
static HRESULT WINAPI IXACT3SoundBankImpl_GetCueProperties(IXACT3SoundBank *iface,
@@ -290,7 +291,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_GetCueProperties(IXACT3SoundBank *ifac
TRACE("(%p)->(%u, %p)\n", This, nCueIndex, pProperties);
- return FACTSoundBank_GetCueProperties(This->fact_soundbank, nCueIndex,
+ return pFACTSoundBank_GetCueProperties(This->fact_soundbank, nCueIndex,
(FACTCueProperties*) pProperties);
}
#endif
@@ -307,7 +308,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_Prepare(IXACT3SoundBank *iface,
TRACE("(%p)->(%u, 0x%x, %u, %p)\n", This, nCueIndex, dwFlags, timeOffset,
ppCue);
- ret = FACTSoundBank_Prepare(This->fact_soundbank, nCueIndex, dwFlags,
+ ret = pFACTSoundBank_Prepare(This->fact_soundbank, nCueIndex, dwFlags,
timeOffset, &fcue);
if(ret != 0)
{
@@ -318,7 +319,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_Prepare(IXACT3SoundBank *iface,
cue = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*cue));
if (!cue)
{
- FACTCue_Destroy(fcue);
+ pFACTCue_Destroy(fcue);
ERR("Failed to allocate XACT3CueImpl!\n");
return E_OUTOFMEMORY;
}
@@ -349,10 +350,10 @@ static HRESULT WINAPI IXACT3SoundBankImpl_Play(IXACT3SoundBank *iface,
* -flibit
*/
if (ppCue == NULL){
- hr = FACTSoundBank_Play(This->fact_soundbank, nCueIndex, dwFlags,
+ hr = pFACTSoundBank_Play(This->fact_soundbank, nCueIndex, dwFlags,
timeOffset, NULL);
}else{
- hr = FACTSoundBank_Play(This->fact_soundbank, nCueIndex, dwFlags,
+ hr = pFACTSoundBank_Play(This->fact_soundbank, nCueIndex, dwFlags,
timeOffset, &fcue);
if(FAILED(hr))
return hr;
@@ -360,7 +361,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_Play(IXACT3SoundBank *iface,
cue = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*cue));
if (!cue)
{
- FACTCue_Destroy(fcue);
+ pFACTCue_Destroy(fcue);
ERR("Failed to allocate XACT3CueImpl!\n");
return E_OUTOFMEMORY;
}
@@ -380,7 +381,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_Stop(IXACT3SoundBank *iface,
TRACE("(%p)->(%u)\n", This, dwFlags);
- return FACTSoundBank_Stop(This->fact_soundbank, nCueIndex, dwFlags);
+ return pFACTSoundBank_Stop(This->fact_soundbank, nCueIndex, dwFlags);
}
static HRESULT WINAPI IXACT3SoundBankImpl_Destroy(IXACT3SoundBank *iface)
@@ -390,7 +391,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_Destroy(IXACT3SoundBank *iface)
TRACE("(%p)\n", This);
- hr = FACTSoundBank_Destroy(This->fact_soundbank);
+ hr = pFACTSoundBank_Destroy(This->fact_soundbank);
HeapFree(GetProcessHeap(), 0, This);
return hr;
}
@@ -402,7 +403,7 @@ static HRESULT WINAPI IXACT3SoundBankImpl_GetState(IXACT3SoundBank *iface,
TRACE("(%p)->(%p)\n", This, pdwState);
- return FACTSoundBank_GetState(This->fact_soundbank, pdwState);
+ return pFACTSoundBank_GetState(This->fact_soundbank, pdwState);
}
static const IXACT3SoundBankVtbl XACT3SoundBank_Vtbl =
@@ -439,7 +440,7 @@ static HRESULT WINAPI IXACT3WaveImpl_Destroy(IXACT3Wave *iface)
TRACE("(%p)\n", This);
- hr = FACTWave_Destroy(This->fact_wave);
+ hr = pFACTWave_Destroy(This->fact_wave);
HeapFree(GetProcessHeap(), 0, This);
return hr;
}
@@ -450,7 +451,7 @@ static HRESULT WINAPI IXACT3WaveImpl_Play(IXACT3Wave *iface)
TRACE("(%p)\n", This);
- return FACTWave_Play(This->fact_wave);
+ return pFACTWave_Play(This->fact_wave);
}
static HRESULT WINAPI IXACT3WaveImpl_Stop(IXACT3Wave *iface, DWORD dwFlags)
@@ -459,7 +460,7 @@ static HRESULT WINAPI IXACT3WaveImpl_Stop(IXACT3Wave *iface, DWORD dwFlags)
TRACE("(%p)->(0x%x)\n", This, dwFlags);
- return FACTWave_Stop(This->fact_wave, dwFlags);
+ return pFACTWave_Stop(This->fact_wave, dwFlags);
}
static HRESULT WINAPI IXACT3WaveImpl_Pause(IXACT3Wave *iface, BOOL fPause)
@@ -468,7 +469,7 @@ static HRESULT WINAPI IXACT3WaveImpl_Pause(IXACT3Wave *iface, BOOL fPause)
TRACE("(%p)->(%u)\n", This, fPause);
- return FACTWave_Pause(This->fact_wave, fPause);
+ return pFACTWave_Pause(This->fact_wave, fPause);
}
static HRESULT WINAPI IXACT3WaveImpl_GetState(IXACT3Wave *iface, DWORD *pdwState)
@@ -477,7 +478,7 @@ static HRESULT WINAPI IXACT3WaveImpl_GetState(IXACT3Wave *iface, DWORD *pdwState
TRACE("(%p)->(%p)\n", This, pdwState);
- return FACTWave_GetState(This->fact_wave, pdwState);
+ return pFACTWave_GetState(This->fact_wave, pdwState);
}
static HRESULT WINAPI IXACT3WaveImpl_SetPitch(IXACT3Wave *iface, XACTPITCH pitch)
@@ -486,7 +487,7 @@ static HRESULT WINAPI IXACT3WaveImpl_SetPitch(IXACT3Wave *iface, XACTPITCH pitch
TRACE("(%p)->(%d)\n", This, pitch);
- return FACTWave_SetPitch(This->fact_wave, pitch);
+ return pFACTWave_SetPitch(This->fact_wave, pitch);
}
static HRESULT WINAPI IXACT3WaveImpl_SetVolume(IXACT3Wave *iface, XACTVOLUME volume)
@@ -495,7 +496,7 @@ static HRESULT WINAPI IXACT3WaveImpl_SetVolume(IXACT3Wave *iface, XACTVOLUME vol
TRACE("(%p)->(%f)\n", This, volume);
- return FACTWave_SetVolume(This->fact_wave, volume);
+ return pFACTWave_SetVolume(This->fact_wave, volume);
}
static HRESULT WINAPI IXACT3WaveImpl_SetMatrixCoefficients(IXACT3Wave *iface,
@@ -507,7 +508,7 @@ static HRESULT WINAPI IXACT3WaveImpl_SetMatrixCoefficients(IXACT3Wave *iface,
TRACE("(%p)->(%u, %u, %p)\n", This, uSrcChannelCount, uDstChannelCount,
pMatrixCoefficients);
- return FACTWave_SetMatrixCoefficients(This->fact_wave, uSrcChannelCount,
+ return pFACTWave_SetMatrixCoefficients(This->fact_wave, uSrcChannelCount,
uDstChannelCount, pMatrixCoefficients);
}
@@ -518,7 +519,7 @@ static HRESULT WINAPI IXACT3WaveImpl_GetProperties(IXACT3Wave *iface,
TRACE("(%p)->(%p)\n", This, pProperties);
- return FACTWave_GetProperties(This->fact_wave,
+ return pFACTWave_GetProperties(This->fact_wave,
(FACTWaveInstanceProperties*) pProperties);
}
@@ -555,7 +556,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Destroy(IXACT3WaveBank *iface)
TRACE("(%p)\n", This);
- hr = FACTWaveBank_Destroy(This->fact_wavebank);
+ hr = pFACTWaveBank_Destroy(This->fact_wavebank);
HeapFree(GetProcessHeap(), 0, This);
return hr;
}
@@ -569,7 +570,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_GetNumWaves(IXACT3WaveBank *iface,
TRACE("(%p)->(%p)\n", This, pnNumWaves);
- return FACTWaveBank_GetNumWaves(This->fact_wavebank, pnNumWaves);
+ return pFACTWaveBank_GetNumWaves(This->fact_wavebank, pnNumWaves);
}
static XACTINDEX WINAPI IXACT3WaveBankImpl_GetWaveIndex(IXACT3WaveBank *iface,
@@ -579,7 +580,7 @@ static XACTINDEX WINAPI IXACT3WaveBankImpl_GetWaveIndex(IXACT3WaveBank *iface,
TRACE("(%p)->(%s)\n", This, szFriendlyName);
- return FACTWaveBank_GetWaveIndex(This->fact_wavebank, szFriendlyName);
+ return pFACTWaveBank_GetWaveIndex(This->fact_wavebank, szFriendlyName);
}
static HRESULT WINAPI IXACT3WaveBankImpl_GetWaveProperties(IXACT3WaveBank *iface,
@@ -589,7 +590,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_GetWaveProperties(IXACT3WaveBank *iface
TRACE("(%p)->(%u, %p)\n", This, nWaveIndex, pWaveProperties);
- return FACTWaveBank_GetWaveProperties(This->fact_wavebank, nWaveIndex,
+ return pFACTWaveBank_GetWaveProperties(This->fact_wavebank, nWaveIndex,
(FACTWaveProperties*) pWaveProperties);
}
@@ -605,7 +606,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Prepare(IXACT3WaveBank *iface,
TRACE("(%p)->(0x%x, %u, 0x%x, %u, %p)\n", This, nWaveIndex, dwFlags,
dwPlayOffset, nLoopCount, ppWave);
- ret = FACTWaveBank_Prepare(This->fact_wavebank, nWaveIndex, dwFlags,
+ ret = pFACTWaveBank_Prepare(This->fact_wavebank, nWaveIndex, dwFlags,
dwPlayOffset, nLoopCount, &fwave);
if(ret != 0)
{
@@ -616,7 +617,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Prepare(IXACT3WaveBank *iface,
wave = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*wave));
if (!wave)
{
- FACTWave_Destroy(fwave);
+ pFACTWave_Destroy(fwave);
ERR("Failed to allocate XACT3WaveImpl!\n");
return E_OUTOFMEMORY;
}
@@ -647,10 +648,10 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Play(IXACT3WaveBank *iface,
* -flibit
*/
if (ppWave == NULL){
- hr = FACTWaveBank_Play(This->fact_wavebank, nWaveIndex, dwFlags,
+ hr = pFACTWaveBank_Play(This->fact_wavebank, nWaveIndex, dwFlags,
dwPlayOffset, nLoopCount, NULL);
}else{
- hr = FACTWaveBank_Play(This->fact_wavebank, nWaveIndex, dwFlags,
+ hr = pFACTWaveBank_Play(This->fact_wavebank, nWaveIndex, dwFlags,
dwPlayOffset, nLoopCount, &fwave);
if(FAILED(hr))
return hr;
@@ -658,7 +659,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Play(IXACT3WaveBank *iface,
wave = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*wave));
if (!wave)
{
- FACTWave_Destroy(fwave);
+ pFACTWave_Destroy(fwave);
ERR("Failed to allocate XACT3WaveImpl!\n");
return E_OUTOFMEMORY;
}
@@ -678,7 +679,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_Stop(IXACT3WaveBank *iface,
TRACE("(%p)->(%u, %u)\n", This, nWaveIndex, dwFlags);
- return FACTWaveBank_Stop(This->fact_wavebank, nWaveIndex, dwFlags);
+ return pFACTWaveBank_Stop(This->fact_wavebank, nWaveIndex, dwFlags);
}
#endif
@@ -690,7 +691,7 @@ static HRESULT WINAPI IXACT3WaveBankImpl_GetState(IXACT3WaveBank *iface,
TRACE("(%p)->(%p)\n", This, pdwState);
- return FACTWaveBank_GetState(This->fact_wavebank, pdwState);
+ return pFACTWaveBank_GetState(This->fact_wavebank, pdwState);
}
static const IXACT3WaveBankVtbl XACT3WaveBank_Vtbl =
@@ -777,7 +778,7 @@ static HRESULT WINAPI IXACT3EngineImpl_QueryInterface(IXACT3Engine *iface,
static ULONG WINAPI IXACT3EngineImpl_AddRef(IXACT3Engine *iface)
{
XACT3EngineImpl *This = impl_from_IXACT3Engine(iface);
- ULONG ref = FACTAudioEngine_AddRef(This->fact_engine);
+ ULONG ref = pFACTAudioEngine_AddRef(This->fact_engine);
TRACE("(%p)->(): Refcount now %u\n", This, ref);
return ref;
}
@@ -785,7 +786,7 @@ static ULONG WINAPI IXACT3EngineImpl_AddRef(IXACT3Engine *iface)
static ULONG WINAPI IXACT3EngineImpl_Release(IXACT3Engine *iface)
{
XACT3EngineImpl *This = impl_from_IXACT3Engine(iface);
- ULONG ref = FACTAudioEngine_Release(This->fact_engine);
+ ULONG ref = pFACTAudioEngine_Release(This->fact_engine);
TRACE("(%p)->(): Refcount now %u\n", This, ref);
@@ -801,7 +802,7 @@ static HRESULT WINAPI IXACT3EngineImpl_GetRendererCount(IXACT3Engine *iface,
TRACE("(%p)->(%p)\n", This, pnRendererCount);
- return FACTAudioEngine_GetRendererCount(This->fact_engine, pnRendererCount);
+ return pFACTAudioEngine_GetRendererCount(This->fact_engine, pnRendererCount);
}
static HRESULT WINAPI IXACT3EngineImpl_GetRendererDetails(IXACT3Engine *iface,
@@ -811,7 +812,7 @@ static HRESULT WINAPI IXACT3EngineImpl_GetRendererDetails(IXACT3Engine *iface,
TRACE("(%p)->(%d, %p)\n", This, nRendererIndex, pRendererDetails);
- return FACTAudioEngine_GetRendererDetails(This->fact_engine,
+ return pFACTAudioEngine_GetRendererDetails(This->fact_engine,
nRendererIndex, (FACTRendererDetails*) pRendererDetails);
}
@@ -824,7 +825,7 @@ static HRESULT WINAPI IXACT3EngineImpl_GetFinalMixFormat(IXACT3Engine *iface,
TRACE("(%p)->(%p)\n", This, pFinalMixFormat);
- return FACTAudioEngine_GetFinalMixFormat(This->fact_engine,
+ return pFACTAudioEngine_GetFinalMixFormat(This->fact_engine,
(FAudioWaveFormatExtensible*) pFinalMixFormat);
}
@@ -900,9 +901,9 @@ static HRESULT WINAPI IXACT3EngineImpl_Initialize(IXACT3Engine *iface,
This->notification_callback = (XACT_NOTIFICATION_CALLBACK)pParams->fnNotificationCallback;
- ret = FACTAudioEngine_Initialize(This->fact_engine, ¶ms);
+ ret = pFACTAudioEngine_Initialize(This->fact_engine, ¶ms);
if (ret != 0)
- WARN("FACTAudioEngine_Initialize returned %d\n", ret);
+ WARN("pFACTAudioEngine_Initialize returned %d\n", ret);
return !ret ? S_OK : E_FAIL;
}
@@ -913,7 +914,7 @@ static HRESULT WINAPI IXACT3EngineImpl_ShutDown(IXACT3Engine *iface)
TRACE("(%p)\n", This);
- return FACTAudioEngine_ShutDown(This->fact_engine);
+ return pFACTAudioEngine_ShutDown(This->fact_engine);
}
static HRESULT WINAPI IXACT3EngineImpl_DoWork(IXACT3Engine *iface)
@@ -922,7 +923,7 @@ static HRESULT WINAPI IXACT3EngineImpl_DoWork(IXACT3Engine *iface)
TRACE("(%p)\n", This);
- return FACTAudioEngine_DoWork(This->fact_engine);
+ return pFACTAudioEngine_DoWork(This->fact_engine);
}
static HRESULT WINAPI IXACT3EngineImpl_CreateSoundBank(IXACT3Engine *iface,
@@ -937,7 +938,7 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateSoundBank(IXACT3Engine *iface,
TRACE("(%p)->(%p, %u, 0x%x, 0x%x, %p): stub!\n", This, pvBuffer, dwSize, dwFlags,
dwAllocAttributes, ppSoundBank);
- ret = FACTAudioEngine_CreateSoundBank(This->fact_engine, pvBuffer, dwSize,
+ ret = pFACTAudioEngine_CreateSoundBank(This->fact_engine, pvBuffer, dwSize,
dwFlags, dwAllocAttributes, &fsb);
if(ret != 0)
{
@@ -948,7 +949,7 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateSoundBank(IXACT3Engine *iface,
sb = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*sb));
if (!sb)
{
- FACTSoundBank_Destroy(fsb);
+ pFACTSoundBank_Destroy(fsb);
ERR("Failed to allocate XACT3SoundBankImpl!\n");
return E_OUTOFMEMORY;
}
@@ -974,7 +975,7 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac
TRACE("(%p)->(%p, %u, 0x%x, 0x%x, %p)\n", This, pvBuffer, dwSize, dwFlags,
dwAllocAttributes, ppWaveBank);
- ret = FACTAudioEngine_CreateInMemoryWaveBank(This->fact_engine, pvBuffer,
+ ret = pFACTAudioEngine_CreateInMemoryWaveBank(This->fact_engine, pvBuffer,
dwSize, dwFlags, dwAllocAttributes, &fwb);
if(ret != 0)
{
@@ -985,7 +986,7 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateInMemoryWaveBank(IXACT3Engine *ifac
wb = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*wb));
if (!wb)
{
- FACTWaveBank_Destroy(fwb);
+ pFACTWaveBank_Destroy(fwb);
ERR("Failed to allocate XACT3WaveBankImpl!\n");
return E_OUTOFMEMORY;
}
@@ -1022,7 +1023,7 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa
fakeParms.offset = pParms->offset;
fakeParms.packetSize = pParms->packetSize;
- ret = FACTAudioEngine_CreateStreamingWaveBank(This->fact_engine, &fakeParms,
+ ret = pFACTAudioEngine_CreateStreamingWaveBank(This->fact_engine, &fakeParms,
&fwb);
if(ret != 0)
{
@@ -1033,7 +1034,7 @@ static HRESULT WINAPI IXACT3EngineImpl_CreateStreamingWaveBank(IXACT3Engine *ifa
wb = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*wb));
if (!wb)
{
- FACTWaveBank_Destroy(fwb);
+ pFACTWaveBank_Destroy(fwb);
ERR("Failed to allocate XACT3WaveBankImpl!\n");
return E_OUTOFMEMORY;
}
@@ -1083,7 +1084,7 @@ static HRESULT WINAPI IXACT3EngineImpl_PrepareWave(IXACT3Engine *iface,
TRACE("(%p)->(0x%08x, %s, %d, %d, %d, %d, %p)\n", This, dwFlags, debugstr_a(szWavePath),
wStreamingPacketSize, dwAlignment, dwPlayOffset, nLoopCount, ppWave);
- ret = FACTAudioEngine_PrepareWave(This->fact_engine, dwFlags, szWavePath, wStreamingPacketSize,
+ ret = pFACTAudioEngine_PrepareWave(This->fact_engine, dwFlags, szWavePath, wStreamingPacketSize,
dwAlignment, dwPlayOffset, nLoopCount, &fwave);
if(ret != 0 || !fwave)
{
@@ -1094,7 +1095,7 @@ static HRESULT WINAPI IXACT3EngineImpl_PrepareWave(IXACT3Engine *iface,
wave = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*wave));
if (!wave)
{
- FACTWave_Destroy(fwave);
+ pFACTWave_Destroy(fwave);
return E_OUTOFMEMORY;
}
@@ -1245,7 +1246,7 @@ static HRESULT WINAPI IXACT3EngineImpl_RegisterNotification(IXACT3Engine *iface,
unwrap_notificationdesc(&fdesc, pNotificationDesc);
fdesc.pvContext = This;
- return FACTAudioEngine_RegisterNotification(This->fact_engine, &fdesc);
+ return pFACTAudioEngine_RegisterNotification(This->fact_engine, &fdesc);
}
static HRESULT WINAPI IXACT3EngineImpl_UnRegisterNotification(IXACT3Engine *iface,
@@ -1258,7 +1259,7 @@ static HRESULT WINAPI IXACT3EngineImpl_UnRegisterNotification(IXACT3Engine *ifac
unwrap_notificationdesc(&fdesc, pNotificationDesc);
fdesc.pvContext = This;
- return FACTAudioEngine_UnRegisterNotification(This->fact_engine, &fdesc);
+ return pFACTAudioEngine_UnRegisterNotification(This->fact_engine, &fdesc);
}
static XACTCATEGORY WINAPI IXACT3EngineImpl_GetCategory(IXACT3Engine *iface,
@@ -1268,7 +1269,7 @@ static XACTCATEGORY WINAPI IXACT3EngineImpl_GetCategory(IXACT3Engine *iface,
TRACE("(%p)->(%s)\n", This, szFriendlyName);
- return FACTAudioEngine_GetCategory(This->fact_engine, szFriendlyName);
+ return pFACTAudioEngine_GetCategory(This->fact_engine, szFriendlyName);
}
static HRESULT WINAPI IXACT3EngineImpl_Stop(IXACT3Engine *iface,
@@ -1278,7 +1279,7 @@ static HRESULT WINAPI IXACT3EngineImpl_Stop(IXACT3Engine *iface,
TRACE("(%p)->(%u, 0x%x)\n", This, nCategory, dwFlags);
- return FACTAudioEngine_Stop(This->fact_engine, nCategory, dwFlags);
+ return pFACTAudioEngine_Stop(This->fact_engine, nCategory, dwFlags);
}
static HRESULT WINAPI IXACT3EngineImpl_SetVolume(IXACT3Engine *iface,
@@ -1288,7 +1289,7 @@ static HRESULT WINAPI IXACT3EngineImpl_SetVolume(IXACT3Engine *iface,
TRACE("(%p)->(%u, %f)\n", This, nCategory, nVolume);
- return FACTAudioEngine_SetVolume(This->fact_engine, nCategory, nVolume);
+ return pFACTAudioEngine_SetVolume(This->fact_engine, nCategory, nVolume);
}
static HRESULT WINAPI IXACT3EngineImpl_Pause(IXACT3Engine *iface,
@@ -1298,7 +1299,7 @@ static HRESULT WINAPI IXACT3EngineImpl_Pause(IXACT3Engine *iface,
TRACE("(%p)->(%u, %u)\n", This, nCategory, fPause);
- return FACTAudioEngine_Pause(This->fact_engine, nCategory, fPause);
+ return pFACTAudioEngine_Pause(This->fact_engine, nCategory, fPause);
}
static XACTVARIABLEINDEX WINAPI IXACT3EngineImpl_GetGlobalVariableIndex(
@@ -1308,7 +1309,7 @@ static XACTVARIABLEINDEX WINAPI IXACT3EngineImpl_GetGlobalVariableIndex(
TRACE("(%p)->(%s)\n", This, szFriendlyName);
- return FACTAudioEngine_GetGlobalVariableIndex(This->fact_engine,
+ return pFACTAudioEngine_GetGlobalVariableIndex(This->fact_engine,
szFriendlyName);
}
@@ -1319,7 +1320,7 @@ static HRESULT WINAPI IXACT3EngineImpl_SetGlobalVariable(IXACT3Engine *iface,
TRACE("(%p)->(%u, %f)\n", This, nIndex, nValue);
- return FACTAudioEngine_SetGlobalVariable(This->fact_engine, nIndex, nValue);
+ return pFACTAudioEngine_SetGlobalVariable(This->fact_engine, nIndex, nValue);
}
static HRESULT WINAPI IXACT3EngineImpl_GetGlobalVariable(IXACT3Engine *iface,
@@ -1329,7 +1330,7 @@ static HRESULT WINAPI IXACT3EngineImpl_GetGlobalVariable(IXACT3Engine *iface,
TRACE("(%p)->(%u, %p)\n", This, nIndex, nValue);
- return FACTAudioEngine_GetGlobalVariable(This->fact_engine, nIndex, nValue);
+ return pFACTAudioEngine_GetGlobalVariable(This->fact_engine, nIndex, nValue);
}
static const IXACT3EngineVtbl XACT3Engine_Vtbl =
@@ -1422,7 +1423,7 @@ static HRESULT WINAPI XACT3CF_CreateInstance(IClassFactory *iface, IUnknown *pOu
object->IXACT3Engine_iface.lpVtbl = &XACT3Engine_Vtbl;
- FACTCreateEngineWithCustomAllocatorEXT(
+ pFACTCreateEngineWithCustomAllocatorEXT(
0,
&object->fact_engine,
XACT_Internal_Malloc,
@@ -1464,11 +1465,15 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD reason, void *pReserved)
{
case DLL_PROCESS_ATTACH:
DisableThreadLibraryCalls( hinstDLL );
+ if (!load_faudio()) return FALSE;
#ifdef HAVE_FAUDIOLINKEDVERSION
- TRACE("Using FAudio version %d\n", FAudioLinkedVersion() );
+ TRACE("Using FAudio version %d\n", pFAudioLinkedVersion() );
#endif
+ break;
+ case DLL_PROCESS_DETACH:
+ unload_faudio();
break;
}
return TRUE;
diff --git a/dlls/xaudio2_7/xapo.c b/dlls/xaudio2_7/xapo.c
index e47442959d3..7972f01a994 100644
--- a/dlls/xaudio2_7/xapo.c
+++ b/dlls/xaudio2_7/xapo.c
@@ -306,7 +306,7 @@ static inline HRESULT get_fapo_from_clsid(REFCLSID clsid, FAPO **fapo)
{
#ifndef XAPOFX1_VER
if(IsEqualGUID(clsid, &CLSID_AudioVolumeMeter27))
- return FAudioCreateVolumeMeterWithCustomAllocatorEXT(
+ return pFAudioCreateVolumeMeterWithCustomAllocatorEXT(
fapo,
0,
XAudio_Internal_Malloc,
@@ -315,7 +315,7 @@ static inline HRESULT get_fapo_from_clsid(REFCLSID clsid, FAPO **fapo)
);
#if XAUDIO2_VER >= 9 && HAVE_FAUDIOCREATEREVERB9WITHCUSTOMALLOCATOREXT
if(IsEqualGUID(clsid, &CLSID_AudioReverb27))
- return FAudioCreateReverb9WithCustomAllocatorEXT(
+ return pFAudioCreateReverb9WithCustomAllocatorEXT(
fapo,
0,
XAudio_Internal_Malloc,
@@ -324,7 +324,7 @@ static inline HRESULT get_fapo_from_clsid(REFCLSID clsid, FAPO **fapo)
);
#else
if(IsEqualGUID(clsid, &CLSID_AudioReverb27))
- return FAudioCreateReverbWithCustomAllocatorEXT(
+ return pFAudioCreateReverbWithCustomAllocatorEXT(
fapo,
0,
XAudio_Internal_Malloc,
@@ -338,7 +338,7 @@ static inline HRESULT get_fapo_from_clsid(REFCLSID clsid, FAPO **fapo)
IsEqualGUID(clsid, &CLSID_FXEQ) ||
IsEqualGUID(clsid, &CLSID_FXEcho) ||
IsEqualGUID(clsid, &CLSID_FXMasteringLimiter))
- return FAPOFX_CreateFXWithCustomAllocatorEXT(
+ return pFAPOFX_CreateFXWithCustomAllocatorEXT(
(const FAudioGUID*) clsid,
fapo,
NULL,
diff --git a/dlls/xaudio2_7/xapofx.c b/dlls/xaudio2_7/xapofx.c
index 4dcdaa2ca5f..4cbc2816bc8 100644
--- a/dlls/xaudio2_7/xapofx.c
+++ b/dlls/xaudio2_7/xapofx.c
@@ -36,6 +36,25 @@
WINE_DEFAULT_DEBUG_CHANNEL(xaudio2);
#endif
+#ifdef XAPOFX1_VER
+BOOL WINAPI DllMain(HINSTANCE inst, DWORD reason, LPVOID reserved)
+{
+ TRACE("inst %p, reason %d, reserved %p.\n", inst, reason, reserved );
+
+ switch (reason)
+ {
+ case DLL_PROCESS_ATTACH:
+ DisableThreadLibraryCalls(inst);
+ if (!load_faudio()) return FALSE;
+ break;
+ case DLL_PROCESS_DETACH:
+ unload_faudio();
+ break;
+ }
+ return TRUE;
+}
+#endif /* XAPOFX1_VER */
+
#if XAUDIO2_VER >= 8
HRESULT CDECL CreateFX(REFCLSID clsid, IUnknown **out, void *initdata, UINT32 initdata_bytes)
{
diff --git a/dlls/xaudio2_7/xaudio_dll.c b/dlls/xaudio2_7/xaudio_dll.c
index c9f5dd2f48e..eb3cae7ad62 100644
--- a/dlls/xaudio2_7/xaudio_dll.c
+++ b/dlls/xaudio2_7/xaudio_dll.c
@@ -87,10 +87,14 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD reason, void *pReserved)
{
case DLL_PROCESS_ATTACH:
DisableThreadLibraryCalls( hinstDLL );
+ if (!load_faudio()) return FALSE;
#ifdef HAVE_FAUDIOLINKEDVERSION
- TRACE("Using FAudio version %d\n", FAudioLinkedVersion() );
+ TRACE("Using FAudio version %d\n", pFAudioLinkedVersion() );
#endif
break;
+ case DLL_PROCESS_DETACH:
+ unload_faudio();
+ break;
}
return TRUE;
}
@@ -494,7 +498,7 @@ static const FAudioEngineCallback FAudioEngineCallback_Vtbl = {
static inline void destroy_voice(XA2VoiceImpl *This)
{
- FAudioVoice_DestroyVoice(This->faudio_voice);
+ pFAudioVoice_DestroyVoice(This->faudio_voice);
free_effect_chain(This->effect_chain);
This->effect_chain = NULL;
This->in_use = FALSE;
@@ -512,7 +516,7 @@ static void WINAPI XA2SRC_GetVoiceDetails(IXAudio2SourceVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %p\n", This, pVoiceDetails);
- FAudioVoice_GetVoiceDetails(This->faudio_voice, (FAudioVoiceDetails *)pVoiceDetails);
+ pFAudioVoice_GetVoiceDetails(This->faudio_voice, (FAudioVoiceDetails *)pVoiceDetails);
}
static HRESULT WINAPI XA2SRC_SetOutputVoices(IXAudio2SourceVoice *iface,
@@ -526,7 +530,7 @@ static HRESULT WINAPI XA2SRC_SetOutputVoices(IXAudio2SourceVoice *iface,
faudio_sends = wrap_voice_sends(pSendList);
- hr = FAudioVoice_SetOutputVoices(This->faudio_voice, faudio_sends);
+ hr = pFAudioVoice_SetOutputVoices(This->faudio_voice, faudio_sends);
free_voice_sends(faudio_sends);
@@ -544,7 +548,7 @@ static HRESULT WINAPI XA2SRC_SetEffectChain(IXAudio2SourceVoice *iface,
free_effect_chain(This->effect_chain);
This->effect_chain = wrap_effect_chain(pEffectChain);
- hr = FAudioVoice_SetEffectChain(This->faudio_voice, This->effect_chain);
+ hr = pFAudioVoice_SetEffectChain(This->faudio_voice, This->effect_chain);
return hr;
}
@@ -554,7 +558,7 @@ static HRESULT WINAPI XA2SRC_EnableEffect(IXAudio2SourceVoice *iface, UINT32 Eff
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, 0x%x\n", This, EffectIndex, OperationSet);
- return FAudioVoice_EnableEffect(This->faudio_voice, EffectIndex, OperationSet);
+ return pFAudioVoice_EnableEffect(This->faudio_voice, EffectIndex, OperationSet);
}
static HRESULT WINAPI XA2SRC_DisableEffect(IXAudio2SourceVoice *iface, UINT32 EffectIndex,
@@ -562,7 +566,7 @@ static HRESULT WINAPI XA2SRC_DisableEffect(IXAudio2SourceVoice *iface, UINT32 Ef
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, 0x%x\n", This, EffectIndex, OperationSet);
- return FAudioVoice_DisableEffect(This->faudio_voice, EffectIndex, OperationSet);
+ return pFAudioVoice_DisableEffect(This->faudio_voice, EffectIndex, OperationSet);
}
static void WINAPI XA2SRC_GetEffectState(IXAudio2SourceVoice *iface, UINT32 EffectIndex,
@@ -570,7 +574,7 @@ static void WINAPI XA2SRC_GetEffectState(IXAudio2SourceVoice *iface, UINT32 Effe
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, %p\n", This, EffectIndex, pEnabled);
- FAudioVoice_GetEffectState(This->faudio_voice, EffectIndex, (int32_t*)pEnabled);
+ pFAudioVoice_GetEffectState(This->faudio_voice, EffectIndex, (int32_t*)pEnabled);
}
static HRESULT WINAPI XA2SRC_SetEffectParameters(IXAudio2SourceVoice *iface,
@@ -580,7 +584,7 @@ static HRESULT WINAPI XA2SRC_SetEffectParameters(IXAudio2SourceVoice *iface,
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, %p, 0x%x, 0x%x\n", This, EffectIndex, pParameters,
ParametersByteSize, OperationSet);
- return FAudioVoice_SetEffectParameters(This->faudio_voice, EffectIndex,
+ return pFAudioVoice_SetEffectParameters(This->faudio_voice, EffectIndex,
pParameters, ParametersByteSize, OperationSet);
}
@@ -590,7 +594,7 @@ static HRESULT WINAPI XA2SRC_GetEffectParameters(IXAudio2SourceVoice *iface,
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, %p, 0x%x\n", This, EffectIndex, pParameters,
ParametersByteSize);
- return FAudioVoice_GetEffectParameters(This->faudio_voice, EffectIndex,
+ return pFAudioVoice_GetEffectParameters(This->faudio_voice, EffectIndex,
pParameters, ParametersByteSize);
}
@@ -599,7 +603,7 @@ static HRESULT WINAPI XA2SRC_SetFilterParameters(IXAudio2SourceVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %p, 0x%x\n", This, pParameters, OperationSet);
- return FAudioVoice_SetFilterParameters(This->faudio_voice,
+ return pFAudioVoice_SetFilterParameters(This->faudio_voice,
(const FAudioFilterParameters *)pParameters, OperationSet);
}
@@ -608,7 +612,7 @@ static void WINAPI XA2SRC_GetFilterParameters(IXAudio2SourceVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %p\n", This, pParameters);
- FAudioVoice_GetFilterParameters(This->faudio_voice, (FAudioFilterParameters *)pParameters);
+ pFAudioVoice_GetFilterParameters(This->faudio_voice, (FAudioFilterParameters *)pParameters);
}
static HRESULT WINAPI XA2SRC_SetOutputFilterParameters(IXAudio2SourceVoice *iface,
@@ -620,7 +624,7 @@ static HRESULT WINAPI XA2SRC_SetOutputFilterParameters(IXAudio2SourceVoice *ifac
TRACE("%p, %p, %p, 0x%x\n", This, pDestinationVoice, pParameters, OperationSet);
- return FAudioVoice_SetOutputFilterParameters(This->faudio_voice,
+ return pFAudioVoice_SetOutputFilterParameters(This->faudio_voice,
dst ? dst->faudio_voice : NULL, (const FAudioFilterParameters *)pParameters, OperationSet);
}
@@ -633,7 +637,7 @@ static void WINAPI XA2SRC_GetOutputFilterParameters(IXAudio2SourceVoice *iface,
TRACE("%p, %p, %p\n", This, pDestinationVoice, pParameters);
- FAudioVoice_GetOutputFilterParameters(This->faudio_voice,
+ pFAudioVoice_GetOutputFilterParameters(This->faudio_voice,
dst ? dst->faudio_voice : NULL, (FAudioFilterParameters *)pParameters);
}
@@ -642,14 +646,14 @@ static HRESULT WINAPI XA2SRC_SetVolume(IXAudio2SourceVoice *iface, float Volume,
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %f, 0x%x\n", This, Volume, OperationSet);
- return FAudioVoice_SetVolume(This->faudio_voice, Volume, OperationSet);
+ return pFAudioVoice_SetVolume(This->faudio_voice, Volume, OperationSet);
}
static void WINAPI XA2SRC_GetVolume(IXAudio2SourceVoice *iface, float *pVolume)
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %p\n", This, pVolume);
- return FAudioVoice_GetVolume(This->faudio_voice, pVolume);
+ return pFAudioVoice_GetVolume(This->faudio_voice, pVolume);
}
static HRESULT WINAPI XA2SRC_SetChannelVolumes(IXAudio2SourceVoice *iface, UINT32 Channels,
@@ -657,7 +661,7 @@ static HRESULT WINAPI XA2SRC_SetChannelVolumes(IXAudio2SourceVoice *iface, UINT3
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, %p, 0x%x\n", This, Channels, pVolumes, OperationSet);
- return FAudioVoice_SetChannelVolumes(This->faudio_voice, Channels,
+ return pFAudioVoice_SetChannelVolumes(This->faudio_voice, Channels,
pVolumes, OperationSet);
}
@@ -666,7 +670,7 @@ static void WINAPI XA2SRC_GetChannelVolumes(IXAudio2SourceVoice *iface, UINT32 C
{
XA2VoiceImpl *This = impl_from_IXAudio2SourceVoice(iface);
TRACE("%p, %u, %p\n", This, Channels, pVolumes);
- return FAudioVoice_GetChannelVolumes(This->faudio_voice, Channels,
+ return pFAudioVoice_GetChannelVolumes(This->faudio_voice, Channels,
pVolumes);
}
@@ -681,7 +685,7 @@ static HRESULT WINAPI XA2SRC_SetOutputMatrix(IXAudio2SourceVoice *iface,
TRACE("%p, %p, %u, %u, %p, 0x%x\n", This, pDestinationVoice,
SourceChannels, DestinationChannels, pLevelMatrix, OperationSet);
- return FAudioVoice_SetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
+ return pFAudioVoice_SetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
SourceChannels, DestinationChannels, pLevelMatrix, OperationSet);
}
@@ -695,7 +699,7 @@ static void WINAPI XA2SRC_GetOutputMatrix(IXAudio2SourceVoice *iface,
TRACE("%p, %p, %u, %u, %p\n", This, pDestinationVoice,
SourceChannels, DestinationChannels, pLevelMatrix);
- FAudioVoice_GetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
+ pFAudioVoice_GetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
SourceChannels, DestinationChannels, pLevelMatrix);
}
@@ -719,7 +723,7 @@ static HRESULT WINAPI XA2SRC_Start(IXAudio2SourceVoice *iface, UINT32 Flags,
TRACE("%p, 0x%x, 0x%x\n", This, Flags, OperationSet);
- return FAudioSourceVoice_Start(This->faudio_voice, Flags, OperationSet);
+ return pFAudioSourceVoice_Start(This->faudio_voice, Flags, OperationSet);
}
static HRESULT WINAPI XA2SRC_Stop(IXAudio2SourceVoice *iface, UINT32 Flags,
@@ -729,7 +733,7 @@ static HRESULT WINAPI XA2SRC_Stop(IXAudio2SourceVoice *iface, UINT32 Flags,
TRACE("%p, 0x%x, 0x%x\n", This, Flags, OperationSet);
- return FAudioSourceVoice_Stop(This->faudio_voice, Flags, OperationSet);
+ return pFAudioSourceVoice_Stop(This->faudio_voice, Flags, OperationSet);
}
static HRESULT WINAPI XA2SRC_SubmitSourceBuffer(IXAudio2SourceVoice *iface,
@@ -739,7 +743,7 @@ static HRESULT WINAPI XA2SRC_SubmitSourceBuffer(IXAudio2SourceVoice *iface,
TRACE("%p, %p, %p\n", This, pBuffer, pBufferWMA);
- return FAudioSourceVoice_SubmitSourceBuffer(This->faudio_voice, (FAudioBuffer*)pBuffer, (FAudioBufferWMA*)pBufferWMA);
+ return pFAudioSourceVoice_SubmitSourceBuffer(This->faudio_voice, (FAudioBuffer*)pBuffer, (FAudioBufferWMA*)pBufferWMA);
}
static HRESULT WINAPI XA2SRC_FlushSourceBuffers(IXAudio2SourceVoice *iface)
@@ -748,7 +752,7 @@ static HRESULT WINAPI XA2SRC_FlushSourceBuffers(IXAudio2SourceVoice *iface)
TRACE("%p\n", This);
- return FAudioSourceVoice_FlushSourceBuffers(This->faudio_voice);
+ return pFAudioSourceVoice_FlushSourceBuffers(This->faudio_voice);
}
static HRESULT WINAPI XA2SRC_Discontinuity(IXAudio2SourceVoice *iface)
@@ -757,7 +761,7 @@ static HRESULT WINAPI XA2SRC_Discontinuity(IXAudio2SourceVoice *iface)
TRACE("%p\n", This);
- return FAudioSourceVoice_Discontinuity(This->faudio_voice);
+ return pFAudioSourceVoice_Discontinuity(This->faudio_voice);
}
static HRESULT WINAPI XA2SRC_ExitLoop(IXAudio2SourceVoice *iface, UINT32 OperationSet)
@@ -766,7 +770,7 @@ static HRESULT WINAPI XA2SRC_ExitLoop(IXAudio2SourceVoice *iface, UINT32 Operati
TRACE("%p, 0x%x\n", This, OperationSet);
- return FAudioSourceVoice_ExitLoop(This->faudio_voice, OperationSet);
+ return pFAudioSourceVoice_ExitLoop(This->faudio_voice, OperationSet);
}
static void WINAPI XA2SRC_GetState(IXAudio2SourceVoice *iface,
@@ -776,7 +780,7 @@ static void WINAPI XA2SRC_GetState(IXAudio2SourceVoice *iface,
TRACE("%p, %p, 0x%x\n", This, pVoiceState, Flags);
- return FAudioSourceVoice_GetState(This->faudio_voice, (FAudioVoiceState*)pVoiceState, Flags);
+ return pFAudioSourceVoice_GetState(This->faudio_voice, (FAudioVoiceState*)pVoiceState, Flags);
}
static HRESULT WINAPI XA2SRC_SetFrequencyRatio(IXAudio2SourceVoice *iface,
@@ -786,7 +790,7 @@ static HRESULT WINAPI XA2SRC_SetFrequencyRatio(IXAudio2SourceVoice *iface,
TRACE("%p, %f, 0x%x\n", This, Ratio, OperationSet);
- return FAudioSourceVoice_SetFrequencyRatio(This->faudio_voice, Ratio, OperationSet);
+ return pFAudioSourceVoice_SetFrequencyRatio(This->faudio_voice, Ratio, OperationSet);
}
static void WINAPI XA2SRC_GetFrequencyRatio(IXAudio2SourceVoice *iface, float *pRatio)
@@ -795,7 +799,7 @@ static void WINAPI XA2SRC_GetFrequencyRatio(IXAudio2SourceVoice *iface, float *p
TRACE("%p, %p\n", This, pRatio);
- return FAudioSourceVoice_GetFrequencyRatio(This->faudio_voice, pRatio);
+ return pFAudioSourceVoice_GetFrequencyRatio(This->faudio_voice, pRatio);
}
static HRESULT WINAPI XA2SRC_SetSourceSampleRate(
@@ -806,7 +810,7 @@ static HRESULT WINAPI XA2SRC_SetSourceSampleRate(
TRACE("%p, %u\n", This, NewSourceSampleRate);
- return FAudioSourceVoice_SetSourceSampleRate(This->faudio_voice, NewSourceSampleRate);
+ return pFAudioSourceVoice_SetSourceSampleRate(This->faudio_voice, NewSourceSampleRate);
}
static const IXAudio2SourceVoiceVtbl XAudio2SourceVoice_Vtbl = {
@@ -853,7 +857,7 @@ static void WINAPI XA2SUB_GetVoiceDetails(IXAudio2SubmixVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %p\n", This, pVoiceDetails);
- FAudioVoice_GetVoiceDetails(This->faudio_voice, (FAudioVoiceDetails *)pVoiceDetails);
+ pFAudioVoice_GetVoiceDetails(This->faudio_voice, (FAudioVoiceDetails *)pVoiceDetails);
}
static HRESULT WINAPI XA2SUB_SetOutputVoices(IXAudio2SubmixVoice *iface,
@@ -867,7 +871,7 @@ static HRESULT WINAPI XA2SUB_SetOutputVoices(IXAudio2SubmixVoice *iface,
faudio_sends = wrap_voice_sends(pSendList);
- hr = FAudioVoice_SetOutputVoices(This->faudio_voice, faudio_sends);
+ hr = pFAudioVoice_SetOutputVoices(This->faudio_voice, faudio_sends);
free_voice_sends(faudio_sends);
@@ -885,7 +889,7 @@ static HRESULT WINAPI XA2SUB_SetEffectChain(IXAudio2SubmixVoice *iface,
free_effect_chain(This->effect_chain);
This->effect_chain = wrap_effect_chain(pEffectChain);
- hr = FAudioVoice_SetEffectChain(This->faudio_voice, This->effect_chain);
+ hr = pFAudioVoice_SetEffectChain(This->faudio_voice, This->effect_chain);
return hr;
}
@@ -895,7 +899,7 @@ static HRESULT WINAPI XA2SUB_EnableEffect(IXAudio2SubmixVoice *iface, UINT32 Eff
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, 0x%x\n", This, EffectIndex, OperationSet);
- return FAudioVoice_EnableEffect(This->faudio_voice, EffectIndex, OperationSet);
+ return pFAudioVoice_EnableEffect(This->faudio_voice, EffectIndex, OperationSet);
}
static HRESULT WINAPI XA2SUB_DisableEffect(IXAudio2SubmixVoice *iface, UINT32 EffectIndex,
@@ -903,7 +907,7 @@ static HRESULT WINAPI XA2SUB_DisableEffect(IXAudio2SubmixVoice *iface, UINT32 Ef
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, 0x%x\n", This, EffectIndex, OperationSet);
- return FAudioVoice_DisableEffect(This->faudio_voice, EffectIndex, OperationSet);
+ return pFAudioVoice_DisableEffect(This->faudio_voice, EffectIndex, OperationSet);
}
static void WINAPI XA2SUB_GetEffectState(IXAudio2SubmixVoice *iface, UINT32 EffectIndex,
@@ -911,7 +915,7 @@ static void WINAPI XA2SUB_GetEffectState(IXAudio2SubmixVoice *iface, UINT32 Effe
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, %p\n", This, EffectIndex, pEnabled);
- FAudioVoice_GetEffectState(This->faudio_voice, EffectIndex, (int32_t*)pEnabled);
+ pFAudioVoice_GetEffectState(This->faudio_voice, EffectIndex, (int32_t*)pEnabled);
}
static HRESULT WINAPI XA2SUB_SetEffectParameters(IXAudio2SubmixVoice *iface,
@@ -921,7 +925,7 @@ static HRESULT WINAPI XA2SUB_SetEffectParameters(IXAudio2SubmixVoice *iface,
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, %p, 0x%x, 0x%x\n", This, EffectIndex, pParameters,
ParametersByteSize, OperationSet);
- return FAudioVoice_SetEffectParameters(This->faudio_voice, EffectIndex,
+ return pFAudioVoice_SetEffectParameters(This->faudio_voice, EffectIndex,
pParameters, ParametersByteSize, OperationSet);
}
@@ -931,7 +935,7 @@ static HRESULT WINAPI XA2SUB_GetEffectParameters(IXAudio2SubmixVoice *iface,
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, %p, 0x%x\n", This, EffectIndex, pParameters,
ParametersByteSize);
- return FAudioVoice_GetEffectParameters(This->faudio_voice, EffectIndex,
+ return pFAudioVoice_GetEffectParameters(This->faudio_voice, EffectIndex,
pParameters, ParametersByteSize);
}
@@ -940,7 +944,7 @@ static HRESULT WINAPI XA2SUB_SetFilterParameters(IXAudio2SubmixVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %p, 0x%x\n", This, pParameters, OperationSet);
- return FAudioVoice_SetFilterParameters(This->faudio_voice, (const FAudioFilterParameters *)pParameters,
+ return pFAudioVoice_SetFilterParameters(This->faudio_voice, (const FAudioFilterParameters *)pParameters,
OperationSet);
}
@@ -949,7 +953,7 @@ static void WINAPI XA2SUB_GetFilterParameters(IXAudio2SubmixVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %p\n", This, pParameters);
- FAudioVoice_GetFilterParameters(This->faudio_voice, (FAudioFilterParameters *)pParameters);
+ pFAudioVoice_GetFilterParameters(This->faudio_voice, (FAudioFilterParameters *)pParameters);
}
static HRESULT WINAPI XA2SUB_SetOutputFilterParameters(IXAudio2SubmixVoice *iface,
@@ -961,7 +965,7 @@ static HRESULT WINAPI XA2SUB_SetOutputFilterParameters(IXAudio2SubmixVoice *ifac
TRACE("%p, %p, %p, 0x%x\n", This, pDestinationVoice, pParameters, OperationSet);
- return FAudioVoice_SetOutputFilterParameters(This->faudio_voice,
+ return pFAudioVoice_SetOutputFilterParameters(This->faudio_voice,
dst ? dst->faudio_voice : NULL, (const FAudioFilterParameters *)pParameters, OperationSet);
}
@@ -974,7 +978,7 @@ static void WINAPI XA2SUB_GetOutputFilterParameters(IXAudio2SubmixVoice *iface,
TRACE("%p, %p, %p\n", This, pDestinationVoice, pParameters);
- FAudioVoice_GetOutputFilterParameters(This->faudio_voice,
+ pFAudioVoice_GetOutputFilterParameters(This->faudio_voice,
dst ? dst->faudio_voice : NULL, (FAudioFilterParameters *)pParameters);
}
@@ -983,14 +987,14 @@ static HRESULT WINAPI XA2SUB_SetVolume(IXAudio2SubmixVoice *iface, float Volume,
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %f, 0x%x\n", This, Volume, OperationSet);
- return FAudioVoice_SetVolume(This->faudio_voice, Volume, OperationSet);
+ return pFAudioVoice_SetVolume(This->faudio_voice, Volume, OperationSet);
}
static void WINAPI XA2SUB_GetVolume(IXAudio2SubmixVoice *iface, float *pVolume)
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %p\n", This, pVolume);
- return FAudioVoice_GetVolume(This->faudio_voice, pVolume);
+ return pFAudioVoice_GetVolume(This->faudio_voice, pVolume);
}
static HRESULT WINAPI XA2SUB_SetChannelVolumes(IXAudio2SubmixVoice *iface, UINT32 Channels,
@@ -998,7 +1002,7 @@ static HRESULT WINAPI XA2SUB_SetChannelVolumes(IXAudio2SubmixVoice *iface, UINT3
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, %p, 0x%x\n", This, Channels, pVolumes, OperationSet);
- return FAudioVoice_SetChannelVolumes(This->faudio_voice, Channels,
+ return pFAudioVoice_SetChannelVolumes(This->faudio_voice, Channels,
pVolumes, OperationSet);
}
@@ -1007,7 +1011,7 @@ static void WINAPI XA2SUB_GetChannelVolumes(IXAudio2SubmixVoice *iface, UINT32 C
{
XA2VoiceImpl *This = impl_from_IXAudio2SubmixVoice(iface);
TRACE("%p, %u, %p\n", This, Channels, pVolumes);
- return FAudioVoice_GetChannelVolumes(This->faudio_voice, Channels,
+ return pFAudioVoice_GetChannelVolumes(This->faudio_voice, Channels,
pVolumes);
}
@@ -1022,7 +1026,7 @@ static HRESULT WINAPI XA2SUB_SetOutputMatrix(IXAudio2SubmixVoice *iface,
TRACE("%p, %p, %u, %u, %p, 0x%x\n", This, pDestinationVoice,
SourceChannels, DestinationChannels, pLevelMatrix, OperationSet);
- return FAudioVoice_SetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
+ return pFAudioVoice_SetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
SourceChannels, DestinationChannels, pLevelMatrix, OperationSet);
}
@@ -1036,7 +1040,7 @@ static void WINAPI XA2SUB_GetOutputMatrix(IXAudio2SubmixVoice *iface,
TRACE("%p, %p, %u, %u, %p\n", This, pDestinationVoice,
SourceChannels, DestinationChannels, pLevelMatrix);
- FAudioVoice_GetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
+ pFAudioVoice_GetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
SourceChannels, DestinationChannels, pLevelMatrix);
}
@@ -1087,7 +1091,7 @@ static void WINAPI XA2M_GetVoiceDetails(IXAudio2MasteringVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %p\n", This, pVoiceDetails);
- FAudioVoice_GetVoiceDetails(This->faudio_voice, (FAudioVoiceDetails *)pVoiceDetails);
+ pFAudioVoice_GetVoiceDetails(This->faudio_voice, (FAudioVoiceDetails *)pVoiceDetails);
}
static HRESULT WINAPI XA2M_SetOutputVoices(IXAudio2MasteringVoice *iface,
@@ -1101,7 +1105,7 @@ static HRESULT WINAPI XA2M_SetOutputVoices(IXAudio2MasteringVoice *iface,
faudio_sends = wrap_voice_sends(pSendList);
- hr = FAudioVoice_SetOutputVoices(This->faudio_voice, faudio_sends);
+ hr = pFAudioVoice_SetOutputVoices(This->faudio_voice, faudio_sends);
free_voice_sends(faudio_sends);
@@ -1119,7 +1123,7 @@ static HRESULT WINAPI XA2M_SetEffectChain(IXAudio2MasteringVoice *iface,
free_effect_chain(This->effect_chain);
This->effect_chain = wrap_effect_chain(pEffectChain);
- hr = FAudioVoice_SetEffectChain(This->faudio_voice, This->effect_chain);
+ hr = pFAudioVoice_SetEffectChain(This->faudio_voice, This->effect_chain);
return hr;
}
@@ -1129,7 +1133,7 @@ static HRESULT WINAPI XA2M_EnableEffect(IXAudio2MasteringVoice *iface, UINT32 Ef
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, 0x%x\n", This, EffectIndex, OperationSet);
- return FAudioVoice_EnableEffect(This->faudio_voice, EffectIndex, OperationSet);
+ return pFAudioVoice_EnableEffect(This->faudio_voice, EffectIndex, OperationSet);
}
static HRESULT WINAPI XA2M_DisableEffect(IXAudio2MasteringVoice *iface, UINT32 EffectIndex,
@@ -1137,7 +1141,7 @@ static HRESULT WINAPI XA2M_DisableEffect(IXAudio2MasteringVoice *iface, UINT32 E
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, 0x%x\n", This, EffectIndex, OperationSet);
- return FAudioVoice_DisableEffect(This->faudio_voice, EffectIndex, OperationSet);
+ return pFAudioVoice_DisableEffect(This->faudio_voice, EffectIndex, OperationSet);
}
static void WINAPI XA2M_GetEffectState(IXAudio2MasteringVoice *iface, UINT32 EffectIndex,
@@ -1145,7 +1149,7 @@ static void WINAPI XA2M_GetEffectState(IXAudio2MasteringVoice *iface, UINT32 Eff
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, %p\n", This, EffectIndex, pEnabled);
- FAudioVoice_GetEffectState(This->faudio_voice, EffectIndex, (int32_t*)pEnabled);
+ pFAudioVoice_GetEffectState(This->faudio_voice, EffectIndex, (int32_t*)pEnabled);
}
static HRESULT WINAPI XA2M_SetEffectParameters(IXAudio2MasteringVoice *iface,
@@ -1155,7 +1159,7 @@ static HRESULT WINAPI XA2M_SetEffectParameters(IXAudio2MasteringVoice *iface,
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, %p, 0x%x, 0x%x\n", This, EffectIndex, pParameters,
ParametersByteSize, OperationSet);
- return FAudioVoice_SetEffectParameters(This->faudio_voice, EffectIndex,
+ return pFAudioVoice_SetEffectParameters(This->faudio_voice, EffectIndex,
pParameters, ParametersByteSize, OperationSet);
}
@@ -1165,7 +1169,7 @@ static HRESULT WINAPI XA2M_GetEffectParameters(IXAudio2MasteringVoice *iface,
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, %p, 0x%x\n", This, EffectIndex, pParameters,
ParametersByteSize);
- return FAudioVoice_GetEffectParameters(This->faudio_voice, EffectIndex,
+ return pFAudioVoice_GetEffectParameters(This->faudio_voice, EffectIndex,
pParameters, ParametersByteSize);
}
@@ -1174,7 +1178,7 @@ static HRESULT WINAPI XA2M_SetFilterParameters(IXAudio2MasteringVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %p, 0x%x\n", This, pParameters, OperationSet);
- return FAudioVoice_SetFilterParameters(This->faudio_voice, (const FAudioFilterParameters *)pParameters,
+ return pFAudioVoice_SetFilterParameters(This->faudio_voice, (const FAudioFilterParameters *)pParameters,
OperationSet);
}
@@ -1183,7 +1187,7 @@ static void WINAPI XA2M_GetFilterParameters(IXAudio2MasteringVoice *iface,
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %p\n", This, pParameters);
- FAudioVoice_GetFilterParameters(This->faudio_voice, (FAudioFilterParameters *)pParameters);
+ pFAudioVoice_GetFilterParameters(This->faudio_voice, (FAudioFilterParameters *)pParameters);
}
static HRESULT WINAPI XA2M_SetOutputFilterParameters(IXAudio2MasteringVoice *iface,
@@ -1195,7 +1199,7 @@ static HRESULT WINAPI XA2M_SetOutputFilterParameters(IXAudio2MasteringVoice *ifa
TRACE("%p, %p, %p, 0x%x\n", This, pDestinationVoice, pParameters, OperationSet);
- return FAudioVoice_SetOutputFilterParameters(This->faudio_voice,
+ return pFAudioVoice_SetOutputFilterParameters(This->faudio_voice,
dst ? dst->faudio_voice : NULL, (const FAudioFilterParameters *)pParameters, OperationSet);
}
@@ -1208,7 +1212,7 @@ static void WINAPI XA2M_GetOutputFilterParameters(IXAudio2MasteringVoice *iface,
TRACE("%p, %p, %p\n", This, pDestinationVoice, pParameters);
- FAudioVoice_GetOutputFilterParameters(This->faudio_voice,
+ pFAudioVoice_GetOutputFilterParameters(This->faudio_voice,
dst ? dst->faudio_voice : NULL, (FAudioFilterParameters *)pParameters);
}
@@ -1217,14 +1221,14 @@ static HRESULT WINAPI XA2M_SetVolume(IXAudio2MasteringVoice *iface, float Volume
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %f, 0x%x\n", This, Volume, OperationSet);
- return FAudioVoice_SetVolume(This->faudio_voice, Volume, OperationSet);
+ return pFAudioVoice_SetVolume(This->faudio_voice, Volume, OperationSet);
}
static void WINAPI XA2M_GetVolume(IXAudio2MasteringVoice *iface, float *pVolume)
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %p\n", This, pVolume);
- return FAudioVoice_GetVolume(This->faudio_voice, pVolume);
+ return pFAudioVoice_GetVolume(This->faudio_voice, pVolume);
}
static HRESULT WINAPI XA2M_SetChannelVolumes(IXAudio2MasteringVoice *iface, UINT32 Channels,
@@ -1232,7 +1236,7 @@ static HRESULT WINAPI XA2M_SetChannelVolumes(IXAudio2MasteringVoice *iface, UINT
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, %p, 0x%x\n", This, Channels, pVolumes, OperationSet);
- return FAudioVoice_SetChannelVolumes(This->faudio_voice, Channels,
+ return pFAudioVoice_SetChannelVolumes(This->faudio_voice, Channels,
pVolumes, OperationSet);
}
@@ -1241,7 +1245,7 @@ static void WINAPI XA2M_GetChannelVolumes(IXAudio2MasteringVoice *iface, UINT32
{
XA2VoiceImpl *This = impl_from_IXAudio2MasteringVoice(iface);
TRACE("%p, %u, %p\n", This, Channels, pVolumes);
- return FAudioVoice_GetChannelVolumes(This->faudio_voice, Channels,
+ return pFAudioVoice_GetChannelVolumes(This->faudio_voice, Channels,
pVolumes);
}
@@ -1256,7 +1260,7 @@ static HRESULT WINAPI XA2M_SetOutputMatrix(IXAudio2MasteringVoice *iface,
TRACE("%p, %p, %u, %u, %p, 0x%x\n", This, pDestinationVoice,
SourceChannels, DestinationChannels, pLevelMatrix, OperationSet);
- return FAudioVoice_SetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
+ return pFAudioVoice_SetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
SourceChannels, DestinationChannels, pLevelMatrix, OperationSet);
}
@@ -1270,7 +1274,7 @@ static void WINAPI XA2M_GetOutputMatrix(IXAudio2MasteringVoice *iface,
TRACE("%p, %p, %u, %u, %p\n", This, pDestinationVoice,
SourceChannels, DestinationChannels, pLevelMatrix);
- FAudioVoice_GetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
+ pFAudioVoice_GetOutputMatrix(This->faudio_voice, dst ? dst->faudio_voice : NULL,
SourceChannels, DestinationChannels, pLevelMatrix);
}
@@ -1301,7 +1305,7 @@ static void WINAPI XA2M_GetChannelMask(IXAudio2MasteringVoice *iface,
TRACE("%p, %p\n", This, pChannelMask);
- FAudioMasteringVoice_GetChannelMask(This->faudio_voice, pChannelMask);
+ pFAudioMasteringVoice_GetChannelMask(This->faudio_voice, pChannelMask);
}
static const struct IXAudio2MasteringVoiceVtbl XAudio2MasteringVoice_Vtbl = {
@@ -1412,7 +1416,7 @@ static HRESULT WINAPI IXAudio2Impl_QueryInterface(IXAudio2 *iface, REFIID riid,
static ULONG WINAPI IXAudio2Impl_AddRef(IXAudio2 *iface)
{
IXAudio2Impl *This = impl_from_IXAudio2(iface);
- ULONG ref = FAudio_AddRef(This->faudio);
+ ULONG ref = pFAudio_AddRef(This->faudio);
TRACE("(%p)->(): Refcount now %u\n", This, ref);
return ref;
}
@@ -1420,7 +1424,7 @@ static ULONG WINAPI IXAudio2Impl_AddRef(IXAudio2 *iface)
static ULONG WINAPI IXAudio2Impl_Release(IXAudio2 *iface)
{
IXAudio2Impl *This = impl_from_IXAudio2(iface);
- ULONG ref = FAudio_Release(This->faudio);
+ ULONG ref = pFAudio_Release(This->faudio);
TRACE("(%p)->(): Refcount now %u\n", This, ref);
@@ -1570,7 +1574,7 @@ static HRESULT WINAPI IXAudio2Impl_CreateSourceVoice(IXAudio2 *iface,
src->effect_chain = wrap_effect_chain(pEffectChain);
faudio_sends = wrap_voice_sends(pSendList);
- hr = FAudio_CreateSourceVoice(This->faudio, &src->faudio_voice,
+ hr = pFAudio_CreateSourceVoice(This->faudio, &src->faudio_voice,
(FAudioWaveFormatEx*)pSourceFormat, flags, maxFrequencyRatio,
&src->FAudioVoiceCallback_vtbl, faudio_sends,
src->effect_chain);
@@ -1633,7 +1637,7 @@ static HRESULT WINAPI IXAudio2Impl_CreateSubmixVoice(IXAudio2 *iface,
sub->effect_chain = wrap_effect_chain(pEffectChain);
faudio_sends = wrap_voice_sends(pSendList);
- hr = FAudio_CreateSubmixVoice(This->faudio, &sub->faudio_voice, inputChannels,
+ hr = pFAudio_CreateSubmixVoice(This->faudio, &sub->faudio_voice, inputChannels,
inputSampleRate, flags, processingStage, faudio_sends,
sub->effect_chain);
free_voice_sends(faudio_sends);
@@ -1744,9 +1748,9 @@ static HRESULT WINAPI IXAudio2Impl_CreateMasteringVoice(IXAudio2 *iface,
pthread_mutex_unlock(&This->mst.engine_lock);
- FAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
+ pFAudio_SetEngineProcedureEXT(This->faudio, &engine_cb, &This->mst);
- FAudio_CreateMasteringVoice8(This->faudio, &This->mst.faudio_voice, inputChannels,
+ pFAudio_CreateMasteringVoice8(This->faudio, &This->mst.faudio_voice, inputChannels,
inputSampleRate, flags, NULL /* TODO: (uint16_t*)deviceId */,
This->mst.effect_chain, (FAudioStreamCategory)streamCategory);
@@ -1763,7 +1767,7 @@ static HRESULT WINAPI IXAudio2Impl_StartEngine(IXAudio2 *iface)
TRACE("(%p)->()\n", This);
- return FAudio_StartEngine(This->faudio);
+ return pFAudio_StartEngine(This->faudio);
}
static void WINAPI IXAudio2Impl_StopEngine(IXAudio2 *iface)
@@ -1772,7 +1776,7 @@ static void WINAPI IXAudio2Impl_StopEngine(IXAudio2 *iface)
TRACE("(%p)->()\n", This);
- FAudio_StopEngine(This->faudio);
+ pFAudio_StopEngine(This->faudio);
}
static HRESULT WINAPI IXAudio2Impl_CommitChanges(IXAudio2 *iface,
@@ -1783,9 +1787,9 @@ static HRESULT WINAPI IXAudio2Impl_CommitChanges(IXAudio2 *iface,
TRACE("(%p)->(0x%x)\n", This, operationSet);
#ifdef HAVE_FAUDIO_COMMITOPERATIONSET
- return FAudio_CommitOperationSet(This->faudio, operationSet);
+ return pFAudio_CommitOperationSet(This->faudio, operationSet);
#else
- return FAudio_CommitChanges(This->faudio);
+ return pFAudio_CommitChanges(This->faudio);
#endif
}
@@ -1796,7 +1800,7 @@ static void WINAPI IXAudio2Impl_GetPerformanceData(IXAudio2 *iface,
TRACE("(%p)->(%p)\n", This, pPerfData);
- FAudio_GetPerformanceData(This->faudio, (FAudioPerformanceData *)pPerfData);
+ pFAudio_GetPerformanceData(This->faudio, (FAudioPerformanceData *)pPerfData);
}
static void WINAPI IXAudio2Impl_SetDebugConfiguration(IXAudio2 *iface,
@@ -1807,7 +1811,7 @@ static void WINAPI IXAudio2Impl_SetDebugConfiguration(IXAudio2 *iface,
TRACE("(%p)->(%p, %p)\n", This, pDebugConfiguration, pReserved);
- FAudio_SetDebugConfiguration(This->faudio, (FAudioDebugConfiguration *)pDebugConfiguration, pReserved);
+ pFAudio_SetDebugConfiguration(This->faudio, (FAudioDebugConfiguration *)pDebugConfiguration, pReserved);
}
/* XAudio2 2.8 */
@@ -1927,7 +1931,7 @@ static HRESULT WINAPI XAudio2CF_CreateInstance(IClassFactory *iface, IUnknown *p
pthread_cond_init(&object->mst.engine_done, NULL);
pthread_cond_init(&object->mst.engine_ready, NULL);
- FAudioCOMConstructWithCustomAllocatorEXT(
+ pFAudioCOMConstructWithCustomAllocatorEXT(
&object->faudio,
XAUDIO2_VER,
XAudio_Internal_Malloc,
@@ -1935,7 +1939,7 @@ static HRESULT WINAPI XAudio2CF_CreateInstance(IClassFactory *iface, IUnknown *p
XAudio_Internal_Realloc
);
- FAudio_RegisterForCallbacks(object->faudio, &object->FAudioEngineCallback_vtbl);
+ pFAudio_RegisterForCallbacks(object->faudio, &object->FAudioEngineCallback_vtbl);
hr = IXAudio2_QueryInterface(&object->IXAudio2_iface, riid, ppobj);
IXAudio2_Release(&object->IXAudio2_iface);
@@ -1982,7 +1986,7 @@ HRESULT xaudio2_initialize(IXAudio2Impl *This, UINT32 flags, XAUDIO2_PROCESSOR p
{
if(proc != XAUDIO2_ANY_PROCESSOR)
WARN("Processor affinity not implemented in FAudio\n");
- return FAudio_Initialize(This->faudio, flags, FAUDIO_DEFAULT_PROCESSOR);
+ return pFAudio_Initialize(This->faudio, flags, FAUDIO_DEFAULT_PROCESSOR);
}
HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, void **ppv)
diff --git a/dlls/xaudio2_7/xaudio_private.h b/dlls/xaudio2_7/xaudio_private.h
index 46d842bf4c1..35d0410f60f 100644
--- a/dlls/xaudio2_7/xaudio_private.h
+++ b/dlls/xaudio2_7/xaudio_private.h
@@ -23,11 +23,160 @@
#include "xaudio2.h"
#include "xapo.h"
-#include <FAudio.h>
+#include <F3DAudio.h>
+#include <FACT.h>
+#include <FACT3D.h>
#include <FAPO.h>
+#include <FAPOBase.h>
+#include <FAPOFX.h>
+#include <FAudio.h>
+#include <FAudioFX.h>
#include <pthread.h>
+#define MAKE_FUNCPTR(f) extern typeof(f) * p##f DECLSPEC_HIDDEN;
+MAKE_FUNCPTR(FAudio_AddRef)
+#ifdef HAVE_FAUDIO_COMMITOPERATIONSET
+MAKE_FUNCPTR(FAudio_CommitOperationSet)
+#else
+MAKE_FUNCPTR(FAudio_CommitChanges)
+#endif
+MAKE_FUNCPTR(FAudio_CreateMasteringVoice)
+MAKE_FUNCPTR(FAudio_CreateMasteringVoice8)
+MAKE_FUNCPTR(FAudio_CreateSourceVoice)
+MAKE_FUNCPTR(FAudio_CreateSubmixVoice)
+MAKE_FUNCPTR(FAudio_GetDeviceCount)
+MAKE_FUNCPTR(FAudio_GetDeviceDetails)
+MAKE_FUNCPTR(FAudio_GetPerformanceData)
+MAKE_FUNCPTR(FAudio_Initialize)
+MAKE_FUNCPTR(FAudio_RegisterForCallbacks)
+MAKE_FUNCPTR(FAudio_Release)
+MAKE_FUNCPTR(FAudio_SetDebugConfiguration)
+MAKE_FUNCPTR(FAudio_StartEngine)
+MAKE_FUNCPTR(FAudio_StopEngine)
+
+MAKE_FUNCPTR(FAudioVoice_DestroyVoice)
+MAKE_FUNCPTR(FAudioVoice_DisableEffect)
+MAKE_FUNCPTR(FAudioVoice_EnableEffect)
+MAKE_FUNCPTR(FAudioVoice_GetChannelVolumes)
+MAKE_FUNCPTR(FAudioVoice_GetEffectParameters)
+MAKE_FUNCPTR(FAudioVoice_GetEffectState)
+MAKE_FUNCPTR(FAudioVoice_GetFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_GetOutputFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_GetOutputMatrix)
+MAKE_FUNCPTR(FAudioVoice_GetVoiceDetails)
+MAKE_FUNCPTR(FAudioVoice_GetVolume)
+MAKE_FUNCPTR(FAudioVoice_SetChannelVolumes)
+MAKE_FUNCPTR(FAudioVoice_SetEffectChain)
+MAKE_FUNCPTR(FAudioVoice_SetEffectParameters)
+MAKE_FUNCPTR(FAudioVoice_SetFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_SetOutputFilterParameters)
+MAKE_FUNCPTR(FAudioVoice_SetOutputMatrix)
+MAKE_FUNCPTR(FAudioVoice_SetOutputVoices)
+MAKE_FUNCPTR(FAudioVoice_SetVolume)
+
+MAKE_FUNCPTR(FAudioSourceVoice_Discontinuity)
+MAKE_FUNCPTR(FAudioSourceVoice_ExitLoop)
+MAKE_FUNCPTR(FAudioSourceVoice_FlushSourceBuffers)
+MAKE_FUNCPTR(FAudioSourceVoice_GetFrequencyRatio)
+MAKE_FUNCPTR(FAudioSourceVoice_GetState)
+MAKE_FUNCPTR(FAudioSourceVoice_SetFrequencyRatio)
+MAKE_FUNCPTR(FAudioSourceVoice_SetSourceSampleRate)
+MAKE_FUNCPTR(FAudioSourceVoice_Start)
+MAKE_FUNCPTR(FAudioSourceVoice_Stop)
+MAKE_FUNCPTR(FAudioSourceVoice_SubmitSourceBuffer)
+
+MAKE_FUNCPTR(FAudioMasteringVoice_GetChannelMask)
+
+MAKE_FUNCPTR(FAudioCOMConstructWithCustomAllocatorEXT)
+MAKE_FUNCPTR(FAudioCreate)
+MAKE_FUNCPTR(FAudioCreateReverb)
+MAKE_FUNCPTR(FAudioCreateReverb9)
+#ifdef HAVE_FAUDIOCREATEREVERB9WITHCUSTOMALLOCATOREXT
+MAKE_FUNCPTR(FAudioCreateReverb9WithCustomAllocatorEXT)
+#endif
+MAKE_FUNCPTR(FAudioCreateReverbWithCustomAllocatorEXT)
+MAKE_FUNCPTR(FAudioCreateVolumeMeter)
+MAKE_FUNCPTR(FAudioCreateVolumeMeterWithCustomAllocatorEXT)
+#ifdef HAVE_FAUDIOLINKEDVERSION
+MAKE_FUNCPTR(FAudioLinkedVersion)
+#endif
+
+MAKE_FUNCPTR(F3DAudioCalculate)
+MAKE_FUNCPTR(F3DAudioInitialize)
+#ifdef HAVE_F3DAUDIOINITIALIZE8
+MAKE_FUNCPTR(F3DAudioInitialize8)
+#endif
+
+MAKE_FUNCPTR(FACTAudioEngine_AddRef)
+MAKE_FUNCPTR(FACTAudioEngine_CreateInMemoryWaveBank)
+MAKE_FUNCPTR(FACTAudioEngine_CreateSoundBank)
+MAKE_FUNCPTR(FACTAudioEngine_CreateStreamingWaveBank)
+MAKE_FUNCPTR(FACTAudioEngine_DoWork)
+MAKE_FUNCPTR(FACTAudioEngine_GetCategory)
+MAKE_FUNCPTR(FACTAudioEngine_GetFinalMixFormat)
+MAKE_FUNCPTR(FACTAudioEngine_GetGlobalVariable)
+MAKE_FUNCPTR(FACTAudioEngine_GetGlobalVariableIndex)
+MAKE_FUNCPTR(FACTAudioEngine_GetRendererCount)
+MAKE_FUNCPTR(FACTAudioEngine_GetRendererDetails)
+MAKE_FUNCPTR(FACTAudioEngine_Initialize)
+MAKE_FUNCPTR(FACTAudioEngine_Pause)
+MAKE_FUNCPTR(FACTAudioEngine_PrepareWave)
+MAKE_FUNCPTR(FACTAudioEngine_RegisterNotification)
+MAKE_FUNCPTR(FACTAudioEngine_Release)
+MAKE_FUNCPTR(FACTAudioEngine_SetGlobalVariable)
+MAKE_FUNCPTR(FACTAudioEngine_SetVolume)
+MAKE_FUNCPTR(FACTAudioEngine_ShutDown)
+MAKE_FUNCPTR(FACTAudioEngine_Stop)
+MAKE_FUNCPTR(FACTAudioEngine_UnRegisterNotification)
+
+MAKE_FUNCPTR(FACTCreateEngineWithCustomAllocatorEXT)
+
+MAKE_FUNCPTR(FACTCue_Destroy)
+MAKE_FUNCPTR(FACTCue_GetProperties)
+MAKE_FUNCPTR(FACTCue_GetState)
+MAKE_FUNCPTR(FACTCue_GetVariable)
+MAKE_FUNCPTR(FACTCue_GetVariableIndex)
+MAKE_FUNCPTR(FACTCue_Pause)
+MAKE_FUNCPTR(FACTCue_Play)
+MAKE_FUNCPTR(FACTCue_SetMatrixCoefficients)
+MAKE_FUNCPTR(FACTCue_SetVariable)
+MAKE_FUNCPTR(FACTCue_Stop)
+
+MAKE_FUNCPTR(FACTSoundBank_Destroy)
+MAKE_FUNCPTR(FACTSoundBank_GetCueIndex)
+MAKE_FUNCPTR(FACTSoundBank_GetCueProperties)
+MAKE_FUNCPTR(FACTSoundBank_GetNumCues)
+MAKE_FUNCPTR(FACTSoundBank_GetState)
+MAKE_FUNCPTR(FACTSoundBank_Play)
+MAKE_FUNCPTR(FACTSoundBank_Prepare)
+MAKE_FUNCPTR(FACTSoundBank_Stop)
+
+MAKE_FUNCPTR(FACTWave_Destroy)
+MAKE_FUNCPTR(FACTWave_GetProperties)
+MAKE_FUNCPTR(FACTWave_GetState)
+MAKE_FUNCPTR(FACTWave_Pause)
+MAKE_FUNCPTR(FACTWave_Play)
+MAKE_FUNCPTR(FACTWave_SetMatrixCoefficients)
+MAKE_FUNCPTR(FACTWave_SetPitch)
+MAKE_FUNCPTR(FACTWave_SetVolume)
+MAKE_FUNCPTR(FACTWave_Stop)
+
+MAKE_FUNCPTR(FACTWaveBank_Destroy)
+MAKE_FUNCPTR(FACTWaveBank_GetNumWaves)
+MAKE_FUNCPTR(FACTWaveBank_GetState)
+MAKE_FUNCPTR(FACTWaveBank_GetWaveIndex)
+MAKE_FUNCPTR(FACTWaveBank_GetWaveProperties)
+MAKE_FUNCPTR(FACTWaveBank_Play)
+MAKE_FUNCPTR(FACTWaveBank_Prepare)
+MAKE_FUNCPTR(FACTWaveBank_Stop)
+
+MAKE_FUNCPTR(FAPOFX_CreateFXWithCustomAllocatorEXT)
+#undef MAKE_FUNCPTR
+
+extern BOOL load_faudio(void) DECLSPEC_HIDDEN;
+extern void unload_faudio(void) DECLSPEC_HIDDEN;
+
#if XAUDIO2_VER == 0
#define COMPAT_E_INVALID_CALL E_INVALIDARG
#define COMPAT_E_DEVICE_INVALIDATED XAUDIO20_E_DEVICE_INVALIDATED
diff --git a/dlls/xaudio2_8/Makefile.in b/dlls/xaudio2_8/Makefile.in
index 566ddb6b3f1..69aa0d42b81 100644
--- a/dlls/xaudio2_8/Makefile.in
+++ b/dlls/xaudio2_8/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=8
MODULE = xaudio2_8.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
x3daudio.c \
xapo.c \
xapofx.c \
diff --git a/dlls/xaudio2_9/Makefile.in b/dlls/xaudio2_9/Makefile.in
index 86f7b99e5eb..b3256636f4d 100644
--- a/dlls/xaudio2_9/Makefile.in
+++ b/dlls/xaudio2_9/Makefile.in
@@ -2,11 +2,12 @@ EXTRADEFS = -DXAUDIO2_VER=9
MODULE = xaudio2_9.dll
IMPORTS = advapi32 ole32 user32 uuid
PARENTSRC = ../xaudio2_7
-EXTRALIBS = $(FAUDIO_LIBS)
+EXTRALIBS = $(DL_LIBS)
EXTRAINCL = $(FAUDIO_CFLAGS)
C_SRCS = \
compat.c \
+ faudio.c \
x3daudio.c \
xapo.c \
xapofx.c \
--
2.31.0
More information about the wine-devel
mailing list