wine-staging/patches/dsound-EAX/0002-dsound-Add-EAX-v1-constants-and-structs.patch
Sebastian Lackner cd5078fa95 Merge pull request #311 from maharmstone/master
Adds support for Environmental Audio Extensions (EAX).
2015-03-28 21:27:16 +01:00

122 lines
3.4 KiB
Diff

From b95848a7794ff437b58f1a307da8c8fdca6a362f Mon Sep 17 00:00:00 2001
From: Mark Harmstone <mark@harmstone.com>
Date: Sun, 15 Mar 2015 18:04:16 +0000
Subject: dsound: Add EAX v1 constants and structs.
---
dlls/dsound/dsound_eax.h | 89 ++++++++++++++++++++++++++++++++++++++++++++
dlls/dsound/dsound_private.h | 1 +
2 files changed, 90 insertions(+)
create mode 100644 dlls/dsound/dsound_eax.h
diff --git a/dlls/dsound/dsound_eax.h b/dlls/dsound/dsound_eax.h
new file mode 100644
index 0000000..600029f
--- /dev/null
+++ b/dlls/dsound/dsound_eax.h
@@ -0,0 +1,89 @@
+/*
+ * Copyright (c) 2015 Mark Harmstone
+ *
+ * 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
+ */
+
+#ifndef DSOUND_EAX_H_DEFINED
+#define DSOUND_EAX_H_DEFINED
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+DEFINE_GUID(DSPROPSETID_EAX_ReverbProperties, 0x4a4e6fc1, 0xc341, 0x11d1, 0xb7, 0x3a, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00);
+DEFINE_GUID(DSPROPSETID_EAXBUFFER_ReverbProperties, 0x4a4e6fc0, 0xc341, 0x11d1, 0xb7, 0x3a, 0x44, 0x45, 0x53, 0x54, 0x00, 0x00);
+
+typedef enum {
+ DSPROPERTY_EAX_ALL,
+ DSPROPERTY_EAX_ENVIRONMENT,
+ DSPROPERTY_EAX_VOLUME,
+ DSPROPERTY_EAX_DECAYTIME,
+ DSPROPERTY_EAX_DAMPING
+} DSPROPERTY_EAX_REVERBPROPERTY;
+
+typedef struct {
+ unsigned long environment;
+ float fVolume;
+ float fDecayTime_sec;
+ float fDamping;
+} EAX_REVERBPROPERTIES;
+
+enum {
+ EAX_ENVIRONMENT_GENERIC,
+ EAX_ENVIRONMENT_PADDEDCELL,
+ EAX_ENVIRONMENT_ROOM,
+ EAX_ENVIRONMENT_BATHROOM,
+ EAX_ENVIRONMENT_LIVINGROOM,
+ EAX_ENVIRONMENT_STONEROOM,
+ EAX_ENVIRONMENT_AUDITORIUM,
+ EAX_ENVIRONMENT_CONCERTHALL,
+ EAX_ENVIRONMENT_CAVE,
+ EAX_ENVIRONMENT_ARENA,
+ EAX_ENVIRONMENT_HANGAR,
+ EAX_ENVIRONMENT_CARPETEDHALLWAY,
+ EAX_ENVIRONMENT_HALLWAY,
+ EAX_ENVIRONMENT_STONECORRIDOR,
+ EAX_ENVIRONMENT_ALLEY,
+ EAX_ENVIRONMENT_FOREST,
+ EAX_ENVIRONMENT_CITY,
+ EAX_ENVIRONMENT_MOUNTAINS,
+ EAX_ENVIRONMENT_QUARRY,
+ EAX_ENVIRONMENT_PLAIN,
+ EAX_ENVIRONMENT_PARKINGLOT,
+ EAX_ENVIRONMENT_SEWERPIPE,
+ EAX_ENVIRONMENT_UNDERWATER,
+ EAX_ENVIRONMENT_DRUGGED,
+ EAX_ENVIRONMENT_DIZZY,
+ EAX_ENVIRONMENT_PSYCHOTIC,
+ EAX_ENVIRONMENT_COUNT
+};
+
+typedef enum {
+ DSPROPERTY_EAXBUFFER_ALL,
+ DSPROPERTY_EAXBUFFER_REVERBMIX
+} DSPROPERTY_EAXBUFFER_REVERBPROPERTY;
+
+typedef struct {
+ float fMix;
+} EAXBUFFER_REVERBPROPERTIES;
+
+#define EAX_REVERBMIX_USEDISTANCE -1.0f
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
diff --git a/dlls/dsound/dsound_private.h b/dlls/dsound/dsound_private.h
index ed645db..3c7dc7a 100644
--- a/dlls/dsound/dsound_private.h
+++ b/dlls/dsound/dsound_private.h
@@ -29,6 +29,7 @@
#include "mediaobj.h"
#include "mmsystem.h"
#include "uuids.h"
+#include "dsound_eax.h"
#include "wine/list.h"
--
2.3.3