From bec08a8d6b31b40f4a3321d4ce211d1bc76b5d12 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Sun, 28 May 2023 20:36:06 +0800
Subject: [PATCH 01/11] [AL] Added OpenAL binding
---
README.md | 20 +-
build.gradle | 10 +-
.../java/org/overrun/glib/RuntimeHelper.java | 4 +
modules/overrungl/openal/build.gradle | 0
.../main/java/org/overrungl/glib/al/AL.java | 481 ++++++++++++++++++
.../java/org/overrungl/glib/al/Handles.java | 66 +++
.../java/org/overrun/glib/stb/Handles.java | 12 +-
7 files changed, 579 insertions(+), 14 deletions(-)
create mode 100644 modules/overrungl/openal/build.gradle
create mode 100644 modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
create mode 100644 modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
diff --git a/README.md b/README.md
index f34830da..be72c6d9 100644
--- a/README.md
+++ b/README.md
@@ -75,7 +75,7 @@ See [doc/notes](doc/notes/README.md).
## Additional
-OpenGL docs can be found [here](https://docs.gl/).
+Documentations of OpenGL can be found [here](https://docs.gl/).
### Publishing (for internal member)
@@ -103,6 +103,24 @@ natives
│ └─ windows
│ └─ x64
│ └─ glfw3.dll
+│─ openal https://github.com/Over-Run/openal-soft-ci
+│ ├─ linux
+│ │ ├─ arm32
+│ │ │ └─ libopenal.so
+│ │ ├─ arm64
+│ │ │ └─ libopenal.so
+│ │ └─ x64
+│ │ └─ libopenal.so
+│ ├─ os x
+│ │ ├─ arm64
+│ │ │ └─ libopenal.dylib
+│ │ └─ x64
+│ │ └─ libopenal.dylib
+│ └─ windows
+│ ├─ arm64
+│ │ └─ openal.dll
+│ └─ x64
+│ └─ openal.dll
└─ stb https://github.com/Over-Run/stb-ci
├─ linux
│ ├─ arm32
diff --git a/build.gradle b/build.gradle
index 2bd24ff6..891c0201 100644
--- a/build.gradle
+++ b/build.gradle
@@ -70,6 +70,7 @@ enum NativeBinding {
NativePlatform.WIN_64,
NativePlatform.LINUX_64, NativePlatform.LINUX_ARM64,
NativePlatform.MACOS, NativePlatform.MACOS_ARM64),
+ OPENAL("openal", "openal", NativePlatform.ALL),
STB("stb", "stb", NativePlatform.ALL),
private final String name
@@ -103,9 +104,12 @@ enum Artifact {
GLFW("overrungl-glfw", "OverrunGL - GLFW bindings",
"A multi-platform library for OpenGL, OpenGL ES and Vulkan development on the desktop. It provides a simple API for creating windows, contexts and surfaces, receiving input and events.",
":glfw", "Glfw", NativeBinding.GLFW),
- JOML('overrungl-joml', 'OverrunGL - JOML native access',
- 'A Java math library for OpenGL rendering calculations',
- ':joml', 'Joml'),
+ JOML("overrungl-joml", "OverrunGL - JOML native access",
+ "A Java math library for OpenGL rendering calculations",
+ ":joml", "Joml"),
+ OPENAL("overrun-openal", "OverrunGL - OpenAL bindings",
+ "A cross-platform 3D audio API appropriate for use with gaming applications and many other types of audio applications.",
+ ":openal", "Openal", NativeBinding.OPENAL),
OPENGL("overrungl-opengl", "OverrunGL - OpenGL bindings",
"The most widely adopted 2D and 3D graphics API in the industry, bringing thousands of applications to a wide variety of computer platforms.",
":opengl", "Opengl"),
diff --git a/modules/overrungl/core/src/main/java/org/overrun/glib/RuntimeHelper.java b/modules/overrungl/core/src/main/java/org/overrun/glib/RuntimeHelper.java
index 904fa5ca..d3d76e87 100644
--- a/modules/overrungl/core/src/main/java/org/overrun/glib/RuntimeHelper.java
+++ b/modules/overrungl/core/src/main/java/org/overrun/glib/RuntimeHelper.java
@@ -41,6 +41,10 @@
* @since 0.1.0
*/
public final class RuntimeHelper {
+ /**
+ * The version of OverrunGL.
+ */
+ public static final String VERSION = "0.1.0";
/**
* The native linker.
*/
diff --git a/modules/overrungl/openal/build.gradle b/modules/overrungl/openal/build.gradle
new file mode 100644
index 00000000..e69de29b
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
new file mode 100644
index 00000000..fde2e0a5
--- /dev/null
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
@@ -0,0 +1,481 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2023 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package org.overrungl.glib.al;
+
+import static org.overrungl.glib.al.Handles.*;
+
+/**
+ * The OpenAL binding.
+ *
+ * @author squid233
+ * @since 0.1.0
+ */
+public final class AL {
+ /**
+ * No distance model or no buffer
+ */
+ public static final int AL_NONE = 0;
+ /**
+ * Boolean False.
+ */
+ public static final int AL_FALSE = 0;
+ /**
+ * Boolean True.
+ */
+ public static final int AL_TRUE = 1;
+
+ /**
+ * Relative source.
+ * Type: ALboolean
+ * Range: [AL_FALSE, AL_TRUE]
+ * Default: AL_FALSE
+ *
+ * Specifies if the source uses relative coordinates.
+ */
+ public static final int AL_SOURCE_RELATIVE = 0x202;
+
+
+ /**
+ * Inner cone angle, in degrees.
+ * Type: ALint, ALfloat
+ * Range: [0 - 360]
+ * Default: 360
+ *
+ * The angle covered by the inner cone, the area within which the source will
+ * not be attenuated by direction.
+ */
+ public static final int AL_CONE_INNER_ANGLE = 0x1001;
+
+ /**
+ * Outer cone angle, in degrees.
+ * Range: [0 - 360]
+ * Default: 360
+ *
+ * The angle covered by the outer cone, the area outside which the source
+ * will be fully attenuated by direction.
+ */
+ public static final int AL_CONE_OUTER_ANGLE = 0x1002;
+
+ /**
+ * Source pitch.
+ * Type: ALfloat
+ * Range: [0.5 - 2.0]
+ * Default: 1.0
+ *
+ * A multiplier for the sample rate of the source's buffer.
+ */
+ public static final int AL_PITCH = 0x1003;
+
+ /**
+ * Source or listener position.
+ * Type: ALfloat[3], ALint[3]
+ * Default: {0, 0, 0}
+ *
+ * The source or listener location in three-dimensional space.
+ *
+ * OpenAL uses a right-handed coordinate system, like OpenGL, where with a
+ * default view, X points right (thumb), Y points up (index finger), and Z
+ * points towards the viewer/camera (middle finger).
+ *
+ * To change from or to a left-handed coordinate system, negate the Z
+ * component.
+ */
+ public static final int AL_POSITION = 0x1004;
+
+ /**
+ * Source direction.
+ * Type: ALfloat[3], ALint[3]
+ * Default: {0, 0, 0}
+ *
+ * Specifies the current direction in local space. A zero-length vector
+ * specifies an omnidirectional source (cone is ignored).
+ *
+ * To change from or to a left-handed coordinate system, negate the Z
+ * component.
+ */
+ public static final int AL_DIRECTION = 0x1005;
+
+ /**
+ * Source or listener velocity.
+ * Type: ALfloat[3], ALint[3]
+ * Default: {0, 0, 0}
+ *
+ * Specifies the current velocity, relative to the position.
+ *
+ * To change from or to a left-handed coordinate system, negate the Z
+ * component.
+ */
+ public static final int AL_VELOCITY = 0x1006;
+
+ /**
+ * Source looping.
+ * Type: ALboolean
+ * Range: [AL_FALSE, AL_TRUE]
+ * Default: AL_FALSE
+ *
+ * Specifies whether source playback loops.
+ */
+ public static final int AL_LOOPING = 0x1007;
+
+ /**
+ * Source buffer.
+ * Type: ALuint
+ * Range: any valid Buffer ID
+ * Default: AL_NONE
+ *
+ * Specifies the buffer to provide sound samples for a source.
+ */
+ public static final int AL_BUFFER = 0x1009;
+
+ /**
+ * Source or listener gain.
+ * Type: ALfloat
+ * Range: [0.0 - ]
+ *
+ * For sources, an initial linear gain value (before attenuation is applied).
+ * For the listener, an output linear gain adjustment.
+ *
+ * A value of 1.0 means unattenuated. Each division by 2 equals an attenuation
+ * of about -6dB. Each multiplication by 2 equals an amplification of about
+ * +6dB.
+ */
+ public static final int AL_GAIN = 0x100A;
+
+ /**
+ * Minimum source gain.
+ * Type: ALfloat
+ * Range: [0.0 - 1.0]
+ *
+ * The minimum gain allowed for a source, after distance and cone attenuation
+ * are applied (if applicable).
+ */
+ public static final int AL_MIN_GAIN = 0x100D;
+
+ /**
+ * Maximum source gain.
+ * Type: ALfloat
+ * Range: [0.0 - 1.0]
+ *
+ * The maximum gain allowed for a source, after distance and cone attenuation
+ * are applied (if applicable).
+ */
+ public static final int AL_MAX_GAIN = 0x100E;
+
+ /**
+ * Listener orientation.
+ * Type: ALfloat[6]
+ * Default: {0.0, 0.0, -1.0, 0.0, 1.0, 0.0}
+ *
+ * Effectively two three-dimensional vectors. The first vector is the front (or
+ * "at"), and the second is the top (or "up"). Both vectors are relative to the
+ * listener position.
+ *
+ * To change from or to a left-handed coordinate system, negate the Z
+ * component of both vectors.
+ */
+ public static final int AL_ORIENTATION = 0x100F;
+
+ /**
+ * Source state (query only).
+ * Type: ALenum
+ * Range: [AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED]
+ */
+ public static final int AL_SOURCE_STATE = 0x1010;
+
+ /**
+ * Source state values.
+ */
+ public static final int AL_INITIAL = 0x1011,
+ AL_PLAYING = 0x1012,
+ AL_PAUSED = 0x1013,
+ AL_STOPPED = 0x1014;
+
+ /**
+ * Source Buffer Queue size (query only).
+ * Type: ALint
+ *
+ * The number of buffers queued using alSourceQueueBuffers, minus the buffers
+ * removed with alSourceUnqueueBuffers.
+ */
+ public static final int AL_BUFFERS_QUEUED = 0x1015;
+
+ /**
+ * Source Buffer Queue processed count (query only).
+ * Type: ALint
+ *
+ * The number of queued buffers that have been fully processed and can be
+ * removed with alSourceUnqueueBuffers.
+ *
+ * Looping sources will never fully process buffers because they will be set to
+ * play again for when the source loops.
+ */
+ public static final int AL_BUFFERS_PROCESSED = 0x1016;
+
+ /**
+ * Source reference distance.
+ * Type: ALfloat
+ * Range: [0.0 - ]
+ * Default: 1.0
+ *
+ * The distance in units that no distance attenuation occurs.
+ *
+ * At 0.0, no distance attenuation occurs with non-linear attenuation models.
+ */
+ public static final int AL_REFERENCE_DISTANCE = 0x1020;
+
+ /**
+ * Source rolloff factor.
+ * Type: ALfloat
+ * Range: [0.0 - ]
+ * Default: 1.0
+ *
+ * Multiplier to exaggerate or diminish distance attenuation.
+ *
+ * At 0.0, no distance attenuation ever occurs.
+ */
+ public static final int AL_ROLLOFF_FACTOR = 0x1021;
+
+ /**
+ * Outer cone gain.
+ * Type: ALfloat
+ * Range: [0.0 - 1.0]
+ * Default: 0.0
+ *
+ * The gain attenuation applied when the listener is outside the source's
+ * outer cone angle.
+ */
+ public static final int AL_CONE_OUTER_GAIN = 0x1022;
+
+ /**
+ * Source maximum distance.
+ * Type: ALfloat
+ * Range: [0.0 - ]
+ * Default: FLT_MAX
+ *
+ * The distance above which the source is not attenuated any further with a
+ * clamped distance model, or where attenuation reaches 0.0 gain for linear
+ * distance models with a default rolloff factor.
+ */
+ public static final int AL_MAX_DISTANCE = 0x1023;
+
+ /**
+ * Source buffer offset, in seconds
+ */
+ public static final int AL_SEC_OFFSET = 0x1024;
+ /**
+ * Source buffer offset, in sample frames
+ */
+ public static final int AL_SAMPLE_OFFSET = 0x1025;
+ /**
+ * Source buffer offset, in bytes
+ */
+ public static final int AL_BYTE_OFFSET = 0x1026;
+
+ /**
+ * Source type (query only).
+ * Type: ALenum
+ * Range: [AL_STATIC, AL_STREAMING, AL_UNDETERMINED]
+ *
+ * A Source is Static if a Buffer has been attached using AL_BUFFER.
+ *
+ * A Source is Streaming if one or more Buffers have been attached using
+ * alSourceQueueBuffers.
+ *
+ * A Source is Undetermined when it has the NULL buffer attached using
+ * AL_BUFFER.
+ */
+ public static final int AL_SOURCE_TYPE = 0x1027;
+
+ /**
+ * Source type values.
+ */
+ public static final int AL_STATIC = 0x1028,
+ AL_STREAMING = 0x1029,
+ AL_UNDETERMINED = 0x1030;
+
+ /**
+ * Unsigned 8-bit mono buffer format.
+ */
+ public static final int AL_FORMAT_MONO8 = 0x1100;
+ /**
+ * Signed 16-bit mono buffer format.
+ */
+ public static final int AL_FORMAT_MONO16 = 0x1101;
+ /**
+ * Unsigned 8-bit stereo buffer format.
+ */
+ public static final int AL_FORMAT_STEREO8 = 0x1102;
+ /**
+ * Signed 16-bit stereo buffer format.
+ */
+ public static final int AL_FORMAT_STEREO16 = 0x1103;
+
+ /**
+ * Buffer frequency/sample rate (query only).
+ */
+ public static final int AL_FREQUENCY = 0x2001;
+ /**
+ * Buffer bits per sample (query only).
+ */
+ public static final int AL_BITS = 0x2002;
+ /**
+ * Buffer channel count (query only).
+ */
+ public static final int AL_CHANNELS = 0x2003;
+ /**
+ * Buffer data size in bytes (query only).
+ */
+ public static final int AL_SIZE = 0x2004;
+
+ /**
+ * Buffer state. Not for public use.
+ */
+ public static final int AL_UNUSED = 0x2010,
+ AL_PENDING = 0x2011,
+ AL_PROCESSED = 0x2012;
+
+
+ /**
+ * No error.
+ */
+ public static final int AL_NO_ERROR = 0;
+
+ /**
+ * Invalid name (ID) passed to an AL call.
+ */
+ public static final int AL_INVALID_NAME = 0xA001;
+
+ /**
+ * Invalid enumeration passed to AL call.
+ */
+ public static final int AL_INVALID_ENUM = 0xA002;
+
+ /**
+ * Invalid value passed to AL call.
+ */
+ public static final int AL_INVALID_VALUE = 0xA003;
+
+ /**
+ * Illegal AL call.
+ */
+ public static final int AL_INVALID_OPERATION = 0xA004;
+
+ /**
+ * Not enough memory to execute the AL call.
+ */
+ public static final int AL_OUT_OF_MEMORY = 0xA005;
+
+
+ /**
+ * Context string: Vendor name.
+ */
+ public static final int AL_VENDOR = 0xB001;
+ /**
+ * Context string: Version.
+ */
+ public static final int AL_VERSION = 0xB002;
+ /**
+ * Context string: Renderer name.
+ */
+ public static final int AL_RENDERER = 0xB003;
+ /**
+ * Context string: Space-separated extension list.
+ */
+ public static final int AL_EXTENSIONS = 0xB004;
+
+ /**
+ * Doppler scale.
+ * Type: ALfloat
+ * Range: [0.0 - ]
+ * Default: 1.0
+ *
+ * Scale for source and listener velocities.
+ */
+ public static final int AL_DOPPLER_FACTOR = 0xC000;
+
+ /**
+ * Doppler velocity (deprecated).
+ *
+ * A multiplier applied to the Speed of Sound.
+ */
+ public static final int AL_DOPPLER_VELOCITY = 0xC001;
+
+ /**
+ * Speed of Sound, in units per second.
+ * Type: ALfloat
+ * Range: [0.0001 - ]
+ * Default: 343.3
+ *
+ * The speed at which sound waves are assumed to travel, when calculating the
+ * doppler effect from source and listener velocities.
+ */
+ public static final int AL_SPEED_OF_SOUND = 0xC003;
+
+ /**
+ * Distance attenuation model.
+ * Type: ALenum
+ * Range: [AL_NONE, AL_INVERSE_DISTANCE, AL_INVERSE_DISTANCE_CLAMPED,
+ * AL_LINEAR_DISTANCE, AL_LINEAR_DISTANCE_CLAMPED,
+ * AL_EXPONENT_DISTANCE, AL_EXPONENT_DISTANCE_CLAMPED]
+ * Default: AL_INVERSE_DISTANCE_CLAMPED
+ *
+ * The model by which sources attenuate with distance.
+ *
+ * None - No distance attenuation.
+ * Inverse - Doubling the distance halves the source gain.
+ * Linear - Linear gain scaling between the reference and max distances.
+ * Exponent - Exponential gain dropoff.
+ *
+ * Clamped variations work like the non-clamped counterparts, except the
+ * distance calculated is clamped between the reference and max distances.
+ */
+ public static final int AL_DISTANCE_MODEL = 0xD000;
+
+ /**
+ * Distance model values.
+ */
+ public static final int AL_INVERSE_DISTANCE = 0xD001,
+ AL_INVERSE_DISTANCE_CLAMPED = 0xD002,
+ AL_LINEAR_DISTANCE = 0xD003,
+ AL_LINEAR_DISTANCE_CLAMPED = 0xD004,
+ AL_EXPONENT_DISTANCE = 0xD005,
+ AL_EXPONENT_DISTANCE_CLAMPED = 0xD006;
+
+ public static void enable(int capability) {
+ try {
+ alEnable.invokeExact(capability);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void disable(int capability) {
+ try {
+ alDisable.invokeExact(capability);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static boolean isEnabled(int capability) {
+ try {
+ return (boolean) alIsEnabled.invokeExact(capability);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+}
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
new file mode 100644
index 00000000..0d836249
--- /dev/null
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
@@ -0,0 +1,66 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2023 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package org.overrungl.glib.al;
+
+import org.overrun.glib.FunctionDescriptors;
+import org.overrun.glib.RuntimeHelper;
+
+import java.lang.foreign.FunctionDescriptor;
+import java.lang.foreign.MemorySegment;
+import java.lang.foreign.SymbolLookup;
+import java.lang.invoke.MethodHandle;
+
+import static org.overrun.glib.FunctionDescriptors.IV;
+import static org.overrun.glib.FunctionDescriptors.IZ;
+
+/**
+ * The OpenAL method handles.
+ *
+ * @author squid233
+ * @since 0.1.0
+ */
+final class Handles {
+ private static boolean initialized;
+ static SymbolLookup lookup;
+ static MethodHandle
+ alEnable, alDisable, alIsEnabled;
+
+ private static MethodHandle downcall(String name,
+ FunctionDescriptor function) {
+ return RuntimeHelper.downcallThrow(lookup.find(name), function);
+ }
+
+ private static MethodHandle downcall(String name,
+ FunctionDescriptors function) {
+ return RuntimeHelper.downcallThrow(lookup.find(name), function);
+ }
+
+ private static MethodHandle downcallNative(String name,
+ FunctionDescriptors function) {
+ return RuntimeHelper.downcallSafe(lookup.find(name).orElse(MemorySegment.NULL), function);
+ }
+
+ static void create() {
+ if (initialized) return;
+ initialized = true;
+
+ lookup = RuntimeHelper.load("openal", "openal", RuntimeHelper.VERSION);
+ alEnable = downcallNative("alEnable", IV);
+ alDisable = downcallNative("alDisable", IV);
+ alIsEnabled = downcallNative("alIsEnabled", IZ);
+ }
+}
diff --git a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/Handles.java b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/Handles.java
index dccec676..3c3b8100 100644
--- a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/Handles.java
+++ b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/Handles.java
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2022 Overrun Organization
+ * Copyright (c) 2022-2023 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -12,14 +12,6 @@
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- * SOFTWARE.
*/
package org.overrun.glib.stb;
@@ -48,6 +40,6 @@ static MethodHandle downcall(String name,
public static void initialize() {
if (loaded) return;
loaded = true;
- lookup = RuntimeHelper.load("stb", "stb", "0.1.0");
+ lookup = RuntimeHelper.load("stb", "stb", RuntimeHelper.VERSION);
}
}
From c4d3cf16176274162b5cf393c08435ec1c6b7d3c Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Sat, 3 Jun 2023 16:51:25 +0800
Subject: [PATCH 02/11] [AL] AL core functionality
---
doc/notes/0.x/0.1.0.md | 1 +
.../org/overrun/glib/FunctionDescriptors.java | 6 +-
.../org/overrun/glib/util/value/Value3.java | 97 ++
.../overrun/glib/util/value/ValueInt3.java | 38 -
.../main/java/org/overrun/glib/glfw/GLFW.java | 6 +-
.../main/java/org/overrungl/glib/al/AL.java | 968 +++++++++++++++++-
.../java/org/overrungl/glib/al/Handles.java | 96 +-
7 files changed, 1114 insertions(+), 98 deletions(-)
create mode 100644 modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Value3.java
delete mode 100644 modules/overrungl/core/src/main/java/org/overrun/glib/util/value/ValueInt3.java
diff --git a/doc/notes/0.x/0.1.0.md b/doc/notes/0.x/0.1.0.md
index 7126cdad..a7039a4c 100644
--- a/doc/notes/0.x/0.1.0.md
+++ b/doc/notes/0.x/0.1.0.md
@@ -11,6 +11,7 @@ This version includes the following features:
- C memory function
- Growable buffer
- Native memory access for JOML
+- OpenAL
These features are purposed to target:
diff --git a/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java b/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java
index 2925497d..a49ac942 100644
--- a/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java
+++ b/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java
@@ -47,7 +47,7 @@ public enum FunctionDescriptors {
// 1
D, F, I, J, P, p, V,
// 2
- BV, DV, FV, II, IJ, IP, Ip, IV, IZ, JP, JV, JZ, PF,
+ BV, DV, FV, ID, IF, II, IJ, IP, Ip, IV, IZ, JP, JV, JZ, PF,
/**
* Make it doesn't confuse with {@link Math#PI}.
*/
@@ -61,8 +61,8 @@ public enum FunctionDescriptors {
PIJI, PIJP, PIJV, PIPp, PIPV, PPII, PPIP, PPJP, PPPV, SSSV,
// 5
BBBBV, DDDDV, FFFFV, IDDDV, IFFFV, IIDDV, IIFFV, IIFIV, IIIIV, IIIJV, IIIPV, IIJIV, IIJJV, IIPIV, IIPPV, IIZIV, IIZPV,
- IJJIP, IJJJV, IJJPV, IJJZV, IJPIV, IPIIV, IPIPV, IPPIV, ISSSV, PIIIP, PIIPp, PIPII, PIPIp, PIPPV, PPPPI, PPPPV, SSSSV,
- ZZZZV,
+ IJJIP, IJJJV, IJJPV, IJJZV, IJPIV, IPIIV, IPIPV, IPPIV, IPPPV, ISSSV, PIIIP, PIIPp, PIPII, PIPIp, PIPPV, PPPPI, PPPPV,
+ SSSSV, ZZZZV,
// 6
FFFFFV, IBBBBV, IDDDDV, IFFFFV, IIDDDV, IIFFFV, IIIFIV, IIIIIV, IIIIPV, IIIJIV, IIIJJV, IIIPIV, IIIPPP, IIIPPV, IIIPZV,
IIIZIV, IIIZPV, IIJJJV, IIPIIV, IIPIPV, IIPPPP, IIPPPV, IIZIIJ, IJJJJV, IPIPIV, IPIPPV, IPJIIV, IPPIPV, ISSSSV, IZIIPV,
diff --git a/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Value3.java b/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Value3.java
new file mode 100644
index 00000000..d45e01da
--- /dev/null
+++ b/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Value3.java
@@ -0,0 +1,97 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2023 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package org.overrun.glib.util.value;
+
+/**
+ * A value object with 3 objects.
+ *
+ * @param the first type.
+ * @param the second type.
+ * @param the third type.
+ * @param x the first value.
+ * @param y the second value.
+ * @param z the third value.
+ * @author squid233
+ * @since 0.1.0
+ */
+public /* value */ record Value3(T x, U y, V z) {
+ /**
+ * {@return {@link #x}}
+ */
+ public T first() {
+ return x;
+ }
+
+ /**
+ * {@return {@link #y}}
+ */
+ public U second() {
+ return y;
+ }
+
+ /**
+ * {@return {@link #z}}
+ */
+ public V third() {
+ return z;
+ }
+
+ /**
+ * {@return {@link #x}}
+ */
+ public T left() {
+ return x;
+ }
+
+ /**
+ * {@return {@link #y}}
+ */
+ public U middle() {
+ return y;
+ }
+
+ /**
+ * {@return {@link #z}}
+ */
+ public V right() {
+ return z;
+ }
+
+ /**
+ * A value object with 3 integers.
+ *
+ * @param x the first value.
+ * @param y the second value.
+ * @param z the third value.
+ * @author squid233
+ * @since 0.1.0
+ */
+ public record OfInt(int x, int y, int z) {
+ }
+
+ /**
+ * A value object with 3 floats.
+ *
+ * @param x the first value.
+ * @param y the second value.
+ * @param z the third value.
+ * @author squid233
+ * @since 0.1.0
+ */
+ public record OfFloat(float x, float y, float z) {
+ }
+}
diff --git a/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/ValueInt3.java b/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/ValueInt3.java
deleted file mode 100644
index c5465e36..00000000
--- a/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/ValueInt3.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * MIT License
- *
- * Copyright (c) 2022 Overrun Organization
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in all
- * copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
- * SOFTWARE.
- */
-
-package org.overrun.glib.util.value;
-
-/**
- * A value object with 3 integers.
- *
- * @param x the first value.
- * @param y the second value.
- * @param z the third value.
- * @author squid233
- * @since 0.1.0
- */
-// TODO: Replaces with more generic Value3
-public record ValueInt3(int x, int y, int z) {
-}
diff --git a/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java b/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java
index 52bd72a7..98489b28 100644
--- a/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java
+++ b/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java
@@ -20,7 +20,7 @@
import org.overrun.glib.RuntimeHelper;
import org.overrun.glib.util.MemoryStack;
import org.overrun.glib.util.value.Value2;
-import org.overrun.glib.util.value.ValueInt3;
+import org.overrun.glib.util.value.Value3;
import org.overrun.glib.util.value.ValueInt4;
import java.lang.foreign.Arena;
@@ -1032,7 +1032,7 @@ public static void getVersion(int @Nullable [] major, int @Nullable [] minor, in
* @return the major, minor and revision version number
* @see #ngetVersion(MemorySegment, MemorySegment, MemorySegment) ngetVersion
*/
- public static ValueInt3 getVersion() {
+ public static Value3.OfInt getVersion() {
var stack = MemoryStack.stackGet();
long stackPointer = stack.getPointer();
try {
@@ -1040,7 +1040,7 @@ public static ValueInt3 getVersion() {
var pMinor = stack.calloc(JAVA_INT);
var pRev = stack.calloc(JAVA_INT);
ngetVersion(pMajor, pMinor, pRev);
- return new ValueInt3(pMajor.get(JAVA_INT, 0),
+ return new Value3.OfInt(pMajor.get(JAVA_INT, 0),
pMinor.get(JAVA_INT, 0),
pRev.get(JAVA_INT, 0));
} finally {
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
index fde2e0a5..7d03a7ff 100644
--- a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
@@ -16,6 +16,14 @@
package org.overrungl.glib.al;
+import org.overrun.glib.RuntimeHelper;
+import org.overrun.glib.util.MemoryStack;
+import org.overrun.glib.util.value.Value3;
+
+import java.lang.foreign.MemorySegment;
+import java.lang.foreign.SegmentAllocator;
+
+import static java.lang.foreign.ValueLayout.*;
import static org.overrungl.glib.al.Handles.*;
/**
@@ -37,7 +45,6 @@ public final class AL {
* Boolean True.
*/
public static final int AL_TRUE = 1;
-
/**
* Relative source.
* Type: ALboolean
@@ -47,8 +54,6 @@ public final class AL {
* Specifies if the source uses relative coordinates.
*/
public static final int AL_SOURCE_RELATIVE = 0x202;
-
-
/**
* Inner cone angle, in degrees.
* Type: ALint, ALfloat
@@ -59,7 +64,6 @@ public final class AL {
* not be attenuated by direction.
*/
public static final int AL_CONE_INNER_ANGLE = 0x1001;
-
/**
* Outer cone angle, in degrees.
* Range: [0 - 360]
@@ -69,7 +73,6 @@ public final class AL {
* will be fully attenuated by direction.
*/
public static final int AL_CONE_OUTER_ANGLE = 0x1002;
-
/**
* Source pitch.
* Type: ALfloat
@@ -79,7 +82,6 @@ public final class AL {
* A multiplier for the sample rate of the source's buffer.
*/
public static final int AL_PITCH = 0x1003;
-
/**
* Source or listener position.
* Type: ALfloat[3], ALint[3]
@@ -95,7 +97,6 @@ public final class AL {
* component.
*/
public static final int AL_POSITION = 0x1004;
-
/**
* Source direction.
* Type: ALfloat[3], ALint[3]
@@ -108,7 +109,6 @@ public final class AL {
* component.
*/
public static final int AL_DIRECTION = 0x1005;
-
/**
* Source or listener velocity.
* Type: ALfloat[3], ALint[3]
@@ -120,7 +120,6 @@ public final class AL {
* component.
*/
public static final int AL_VELOCITY = 0x1006;
-
/**
* Source looping.
* Type: ALboolean
@@ -130,7 +129,6 @@ public final class AL {
* Specifies whether source playback loops.
*/
public static final int AL_LOOPING = 0x1007;
-
/**
* Source buffer.
* Type: ALuint
@@ -140,7 +138,6 @@ public final class AL {
* Specifies the buffer to provide sound samples for a source.
*/
public static final int AL_BUFFER = 0x1009;
-
/**
* Source or listener gain.
* Type: ALfloat
@@ -154,7 +151,6 @@ public final class AL {
* +6dB.
*/
public static final int AL_GAIN = 0x100A;
-
/**
* Minimum source gain.
* Type: ALfloat
@@ -164,7 +160,6 @@ public final class AL {
* are applied (if applicable).
*/
public static final int AL_MIN_GAIN = 0x100D;
-
/**
* Maximum source gain.
* Type: ALfloat
@@ -174,7 +169,6 @@ public final class AL {
* are applied (if applicable).
*/
public static final int AL_MAX_GAIN = 0x100E;
-
/**
* Listener orientation.
* Type: ALfloat[6]
@@ -188,14 +182,12 @@ public final class AL {
* component of both vectors.
*/
public static final int AL_ORIENTATION = 0x100F;
-
/**
* Source state (query only).
* Type: ALenum
* Range: [AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED]
*/
public static final int AL_SOURCE_STATE = 0x1010;
-
/**
* Source state values.
*/
@@ -203,7 +195,6 @@ public final class AL {
AL_PLAYING = 0x1012,
AL_PAUSED = 0x1013,
AL_STOPPED = 0x1014;
-
/**
* Source Buffer Queue size (query only).
* Type: ALint
@@ -212,7 +203,6 @@ public final class AL {
* removed with alSourceUnqueueBuffers.
*/
public static final int AL_BUFFERS_QUEUED = 0x1015;
-
/**
* Source Buffer Queue processed count (query only).
* Type: ALint
@@ -224,7 +214,6 @@ public final class AL {
* play again for when the source loops.
*/
public static final int AL_BUFFERS_PROCESSED = 0x1016;
-
/**
* Source reference distance.
* Type: ALfloat
@@ -236,7 +225,6 @@ public final class AL {
* At 0.0, no distance attenuation occurs with non-linear attenuation models.
*/
public static final int AL_REFERENCE_DISTANCE = 0x1020;
-
/**
* Source rolloff factor.
* Type: ALfloat
@@ -248,7 +236,6 @@ public final class AL {
* At 0.0, no distance attenuation ever occurs.
*/
public static final int AL_ROLLOFF_FACTOR = 0x1021;
-
/**
* Outer cone gain.
* Type: ALfloat
@@ -259,7 +246,6 @@ public final class AL {
* outer cone angle.
*/
public static final int AL_CONE_OUTER_GAIN = 0x1022;
-
/**
* Source maximum distance.
* Type: ALfloat
@@ -271,7 +257,6 @@ public final class AL {
* distance models with a default rolloff factor.
*/
public static final int AL_MAX_DISTANCE = 0x1023;
-
/**
* Source buffer offset, in seconds
*/
@@ -284,7 +269,6 @@ public final class AL {
* Source buffer offset, in bytes
*/
public static final int AL_BYTE_OFFSET = 0x1026;
-
/**
* Source type (query only).
* Type: ALenum
@@ -299,14 +283,12 @@ public final class AL {
* AL_BUFFER.
*/
public static final int AL_SOURCE_TYPE = 0x1027;
-
/**
* Source type values.
*/
public static final int AL_STATIC = 0x1028,
AL_STREAMING = 0x1029,
AL_UNDETERMINED = 0x1030;
-
/**
* Unsigned 8-bit mono buffer format.
*/
@@ -323,7 +305,6 @@ public final class AL {
* Signed 16-bit stereo buffer format.
*/
public static final int AL_FORMAT_STEREO16 = 0x1103;
-
/**
* Buffer frequency/sample rate (query only).
*/
@@ -340,46 +321,36 @@ public final class AL {
* Buffer data size in bytes (query only).
*/
public static final int AL_SIZE = 0x2004;
-
/**
* Buffer state. Not for public use.
*/
public static final int AL_UNUSED = 0x2010,
AL_PENDING = 0x2011,
AL_PROCESSED = 0x2012;
-
-
/**
* No error.
*/
public static final int AL_NO_ERROR = 0;
-
/**
* Invalid name (ID) passed to an AL call.
*/
public static final int AL_INVALID_NAME = 0xA001;
-
/**
* Invalid enumeration passed to AL call.
*/
public static final int AL_INVALID_ENUM = 0xA002;
-
/**
* Invalid value passed to AL call.
*/
public static final int AL_INVALID_VALUE = 0xA003;
-
/**
* Illegal AL call.
*/
public static final int AL_INVALID_OPERATION = 0xA004;
-
/**
* Not enough memory to execute the AL call.
*/
public static final int AL_OUT_OF_MEMORY = 0xA005;
-
-
/**
* Context string: Vendor name.
*/
@@ -396,7 +367,6 @@ public final class AL {
* Context string: Space-separated extension list.
*/
public static final int AL_EXTENSIONS = 0xB004;
-
/**
* Doppler scale.
* Type: ALfloat
@@ -406,14 +376,12 @@ public final class AL {
* Scale for source and listener velocities.
*/
public static final int AL_DOPPLER_FACTOR = 0xC000;
-
/**
* Doppler velocity (deprecated).
*
* A multiplier applied to the Speed of Sound.
*/
public static final int AL_DOPPLER_VELOCITY = 0xC001;
-
/**
* Speed of Sound, in units per second.
* Type: ALfloat
@@ -424,7 +392,6 @@ public final class AL {
* doppler effect from source and listener velocities.
*/
public static final int AL_SPEED_OF_SOUND = 0xC003;
-
/**
* Distance attenuation model.
* Type: ALenum
@@ -444,7 +411,6 @@ public final class AL {
* distance calculated is clamped between the reference and max distances.
*/
public static final int AL_DISTANCE_MODEL = 0xD000;
-
/**
* Distance model values.
*/
@@ -455,6 +421,10 @@ public final class AL {
AL_EXPONENT_DISTANCE = 0xD005,
AL_EXPONENT_DISTANCE_CLAMPED = 0xD006;
+ static {
+ create();
+ }
+
public static void enable(int capability) {
try {
alEnable.invokeExact(capability);
@@ -478,4 +448,918 @@ public static boolean isEnabled(int capability) {
throw new AssertionError("should not reach here", e);
}
}
+
+ public static void dopplerFactor(float value) {
+ try {
+ alDopplerFactor.invokeExact(value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void dopplerVelocity(float value) {
+ try {
+ alDopplerVelocity.invokeExact(value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void speedOfSound(float value) {
+ try {
+ alSpeedOfSound.invokeExact(value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void distanceModel(int distanceModel) {
+ try {
+ alDistanceModel.invokeExact(distanceModel);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment ngetString(int param) {
+ try {
+ return (MemorySegment) alGetString.invokeExact(param);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static String getString(int param) {
+ return ngetString(param).getUtf8String(0);
+ }
+
+ public static void ngetBooleanv(int param, MemorySegment values) {
+ try {
+ alGetBooleanv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getBooleanv(SegmentAllocator allocator, int param, boolean[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_BYTE, values.length);
+ ngetBooleanv(param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngetIntegerv(int param, MemorySegment values) {
+ try {
+ alGetIntegerv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getIntegerv(SegmentAllocator allocator, int param, int[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
+ ngetIntegerv(param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngetFloatv(int param, MemorySegment values) {
+ try {
+ alGetFloatv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getFloatv(SegmentAllocator allocator, int param, float[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
+ ngetFloatv(param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngetDoublev(int param, MemorySegment values) {
+ try {
+ alGetDoublev.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getDoublev(SegmentAllocator allocator, int param, double[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_DOUBLE, values.length);
+ ngetDoublev(param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static boolean getBoolean(int param) {
+ try {
+ return (boolean) alGetBoolean.invokeExact(param);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static int getInteger(int param) {
+ try {
+ return (int) alGetInteger.invokeExact(param);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getFloat(int param) {
+ try {
+ return (float) alGetFloat.invokeExact(param);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static double getDouble(int param) {
+ try {
+ return (double) alGetDouble.invokeExact(param);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static int getError() {
+ try {
+ return (int) alGetError.invokeExact();
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static boolean nisExtensionPresent(MemorySegment extName) {
+ try {
+ return (boolean) alIsExtensionPresent.invokeExact(extName);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static boolean isExtensionPresent(SegmentAllocator allocator, String extName) {
+ return nisExtensionPresent(allocator.allocateUtf8String(extName));
+ }
+
+ public static MemorySegment ngetProcAddress(MemorySegment fname) {
+ try {
+ return (MemorySegment) alGetProcAddress.invokeExact(fname);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment getProcAddress(SegmentAllocator allocator, String fname) {
+ return ngetProcAddress(allocator.allocateUtf8String(fname));
+ }
+
+ public static int ngetEnumValue(MemorySegment ename) {
+ try {
+ return (int) alGetEnumValue.invokeExact(ename);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static int getEnumValue(SegmentAllocator allocator, String ename) {
+ return ngetEnumValue(allocator.allocateUtf8String(ename));
+ }
+
+ public static void listenerf(int param, float value) {
+ try {
+ alListenerf.invokeExact(param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void listener3f(int param, float value1, float value2, float value3) {
+ try {
+ alListener3f.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nlistenerfv(int param, MemorySegment values) {
+ try {
+ alListenerfv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void listenerfv(SegmentAllocator allocator, int param, float[] values) {
+ nlistenerfv(param, allocator.allocateArray(JAVA_FLOAT, values));
+ }
+
+ public static void listeneri(int param, int value) {
+ try {
+ alListeneri.invokeExact(param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void listener3i(int param, int value1, int value2, int value3) {
+ try {
+ alListener3i.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nlisteneriv(int param, MemorySegment values) {
+ try {
+ alListeneriv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void listeneriv(SegmentAllocator allocator, int param, int[] values) {
+ nlisteneriv(param, allocator.allocateArray(JAVA_INT, values));
+ }
+
+ public static void ngetListenerf(int param, MemorySegment value) {
+ try {
+ alGetListenerf.invokeExact(param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getListenerf(int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_FLOAT);
+ ngetListenerf(param, seg);
+ return seg.get(JAVA_FLOAT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetListener3f(int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ try {
+ alGetListener3f.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static Value3.OfFloat getListener3f(int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg1 = stack.calloc(JAVA_FLOAT);
+ final MemorySegment seg2 = stack.calloc(JAVA_FLOAT);
+ final MemorySegment seg3 = stack.calloc(JAVA_FLOAT);
+ ngetListener3f(param, seg1, seg2, seg3);
+ return new Value3.OfFloat(seg1.get(JAVA_FLOAT, 0), seg2.get(JAVA_FLOAT, 0), seg3.get(JAVA_FLOAT, 0));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetListenerfv(int param, MemorySegment values) {
+ try {
+ alGetListenerfv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getListenerfv(SegmentAllocator allocator, int param, float[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
+ ngetListenerfv(param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngetListeneri(int param, MemorySegment value) {
+ try {
+ alGetListeneri.invokeExact(param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getListeneri(int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_INT);
+ ngetListeneri(param, seg);
+ return seg.get(JAVA_INT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetListener3i(int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ try {
+ alGetListener3i.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static Value3.OfInt getListener3i(int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg1 = stack.calloc(JAVA_INT);
+ final MemorySegment seg2 = stack.calloc(JAVA_INT);
+ final MemorySegment seg3 = stack.calloc(JAVA_INT);
+ ngetListener3i(param, seg1, seg2, seg3);
+ return new Value3.OfInt(seg1.get(JAVA_INT, 0), seg2.get(JAVA_INT, 0), seg3.get(JAVA_INT, 0));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetListeneriv(int param, MemorySegment values) {
+ try {
+ alGetListeneriv.invokeExact(param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getListeneriv(SegmentAllocator allocator, int param, int[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
+ ngetListeneriv(param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngenSources(int n, MemorySegment sources) {
+ try {
+ alGenSources.invokeExact(n, sources);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void genSources(SegmentAllocator allocator, int[] sources) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
+ ngenSources(sources.length, seg);
+ RuntimeHelper.toArray(seg, sources);
+ }
+
+ public static int genSource() {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_INT);
+ ngenSources(1, seg);
+ return seg.get(JAVA_INT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ndeleteSources(int n, MemorySegment sources) {
+ try {
+ alDeleteSources.invokeExact(n, sources);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void deleteSources(SegmentAllocator allocator, int[] sources) {
+ ndeleteSources(sources.length, allocator.allocateArray(JAVA_INT, sources));
+ }
+
+ public static void deleteSource(int source) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ ngenSources(1, stack.ints(source));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static boolean isSource(int source) {
+ try {
+ return (boolean) alIsSource.invokeExact(source);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourcef(int source, int param, float value) {
+ try {
+ alSourcef.invokeExact(source, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void source3f(int source, int param, float value1, float value2, float value3) {
+ try {
+ alSource3f.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nsourcefv(int source, int param, MemorySegment values) {
+ try {
+ alSourcefv.invokeExact(source, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourcefv(SegmentAllocator allocator, int source, int param, float[] values) {
+ nsourcefv(source, param, allocator.allocateArray(JAVA_FLOAT, values));
+ }
+
+ public static void sourcei(int source, int param, int value) {
+ try {
+ alSourcei.invokeExact(source, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void source3i(int source, int param, int value1, int value2, int value3) {
+ try {
+ alSource3i.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nsourceiv(int source, int param, MemorySegment values) {
+ try {
+ alSourceiv.invokeExact(source, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceiv(SegmentAllocator allocator, int source, int param, int[] values) {
+ nsourceiv(source, param, allocator.allocateArray(JAVA_INT, values));
+ }
+
+ public static void ngetSourcef(int source, int param, MemorySegment value) {
+ try {
+ alGetSourcef.invokeExact(source, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getSourcef(int source, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_FLOAT);
+ ngetSourcef(source, param, seg);
+ return seg.get(JAVA_FLOAT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetSource3f(int source, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ try {
+ alGetSource3f.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static Value3.OfFloat getSource3f(int source, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg1 = stack.calloc(JAVA_FLOAT);
+ final MemorySegment seg2 = stack.calloc(JAVA_FLOAT);
+ final MemorySegment seg3 = stack.calloc(JAVA_FLOAT);
+ ngetSource3f(source, param, seg1, seg2, seg3);
+ return new Value3.OfFloat(seg1.get(JAVA_FLOAT, 0), seg2.get(JAVA_FLOAT, 0), seg3.get(JAVA_FLOAT, 0));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetSourcefv(int source, int param, MemorySegment values) {
+ try {
+ alGetSourcefv.invokeExact(source, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getSourcefv(SegmentAllocator allocator, int source, int param, float[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
+ ngetSourcefv(source, param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngetSourcei(int source, int param, MemorySegment value) {
+ try {
+ alGetSourcei.invokeExact(source, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getSourcei(int source, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_INT);
+ ngetSourcei(source, param, seg);
+ return seg.get(JAVA_INT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetSource3i(int source, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ try {
+ alGetSource3i.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static Value3.OfInt getSource3i(int source, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg1 = stack.calloc(JAVA_INT);
+ final MemorySegment seg2 = stack.calloc(JAVA_INT);
+ final MemorySegment seg3 = stack.calloc(JAVA_INT);
+ ngetSource3i(source, param, seg1, seg2, seg3);
+ return new Value3.OfInt(seg1.get(JAVA_INT, 0), seg2.get(JAVA_INT, 0), seg3.get(JAVA_INT, 0));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetSourceiv(int source, int param, MemorySegment values) {
+ try {
+ alGetSourceiv.invokeExact(source, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getSourceiv(SegmentAllocator allocator, int source, int param, int[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
+ ngetSourceiv(source, param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void sourcePlay(int source) {
+ try {
+ alSourcePlay.invokeExact(source);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceStop(int source) {
+ try {
+ alSourceStop.invokeExact(source);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceRewind(int source) {
+ try {
+ alSourceRewind.invokeExact(source);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourcePause(int source) {
+ try {
+ alSourcePause.invokeExact(source);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nsourcePlayv(int n, MemorySegment sources) {
+ try {
+ alSourcePlayv.invokeExact(n, sources);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourcePlayv(SegmentAllocator allocator, int[] sources) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
+ nsourcePlayv(sources.length, seg);
+ RuntimeHelper.toArray(seg, sources);
+ }
+
+ public static void nsourceStopv(int n, MemorySegment sources) {
+ try {
+ alSourceStopv.invokeExact(n, sources);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceStopv(SegmentAllocator allocator, int[] sources) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
+ nsourceStopv(sources.length, seg);
+ RuntimeHelper.toArray(seg, sources);
+ }
+
+ public static void nsourceRewindv(int n, MemorySegment sources) {
+ try {
+ alSourceRewindv.invokeExact(n, sources);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceRewindv(SegmentAllocator allocator, int[] sources) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
+ nsourceRewindv(sources.length, seg);
+ RuntimeHelper.toArray(seg, sources);
+ }
+
+ public static void nsourcePausev(int n, MemorySegment sources) {
+ try {
+ alSourcePausev.invokeExact(n, sources);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourcePausev(SegmentAllocator allocator, int[] sources) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
+ nsourcePausev(sources.length, seg);
+ RuntimeHelper.toArray(seg, sources);
+ }
+
+ public static void nsourceQueueBuffers(int source, int nb, MemorySegment buffers) {
+ try {
+ alSourceQueueBuffers.invokeExact(source, nb, buffers);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceQueueBuffers(SegmentAllocator allocator, int source, int[] buffers) {
+ nsourceQueueBuffers(source, buffers.length, allocator.allocateArray(JAVA_INT, buffers));
+ }
+
+ public static void nsourceUnqueueBuffers(int source, int nb, MemorySegment buffers) {
+ try {
+ alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void sourceUnqueueBuffers(SegmentAllocator allocator, int source, int[] buffers) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, buffers);
+ nsourceUnqueueBuffers(source, buffers.length, seg);
+ RuntimeHelper.toArray(seg, buffers);
+ }
+
+ public static void ngenBuffers(int n, MemorySegment buffers) {
+ try {
+ alGenBuffers.invokeExact(n, buffers);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void genBuffers(SegmentAllocator allocator, int[] buffers) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, buffers.length);
+ ngenBuffers(buffers.length, seg);
+ RuntimeHelper.toArray(seg, buffers);
+ }
+
+ public static int genBuffer() {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_INT);
+ ngenBuffers(1, seg);
+ return seg.get(JAVA_INT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ndeleteBuffers(int n, MemorySegment buffers) {
+ try {
+ alDeleteBuffers.invokeExact(n, buffers);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void deleteBuffers(SegmentAllocator allocator, int[] buffers) {
+ ndeleteBuffers(buffers.length, allocator.allocateArray(JAVA_INT, buffers));
+ }
+
+ public static void deleteBuffer(int buffer) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ ngenBuffers(1, stack.ints(buffer));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static boolean isBuffer(int buffer) {
+ try {
+ return (boolean) alIsBuffer.invokeExact(buffer);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void bufferData(int buffer, int format, MemorySegment data, int size, int sampleRate) {
+ try {
+ alBufferData.invokeExact(buffer, format, data, size, sampleRate);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void bufferf(int buffer, int param, float value) {
+ try {
+ alBufferf.invokeExact(buffer, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void buffer3f(int buffer, int param, float value1, float value2, float value3) {
+ try {
+ alBuffer3f.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nbufferfv(int buffer, int param, MemorySegment values) {
+ try {
+ alBufferfv.invokeExact(buffer, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void bufferfv(SegmentAllocator allocator, int buffer, int param, float[] values) {
+ nbufferfv(buffer, param, allocator.allocateArray(JAVA_FLOAT, values));
+ }
+
+ public static void bufferi(int buffer, int param, int value) {
+ try {
+ alBufferi.invokeExact(buffer, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void buffer3i(int buffer, int param, int value1, int value2, int value3) {
+ try {
+ alBuffer3i.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void nbufferiv(int buffer, int param, MemorySegment values) {
+ try {
+ alBufferiv.invokeExact(buffer, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void bufferiv(SegmentAllocator allocator, int buffer, int param, int[] values) {
+ nbufferiv(buffer, param, allocator.allocateArray(JAVA_INT, values));
+ }
+
+ public static void ngetBufferf(int buffer, int param, MemorySegment value) {
+ try {
+ alGetBufferf.invokeExact(buffer, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getBufferf(int buffer, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_FLOAT);
+ ngetBufferf(buffer, param, seg);
+ return seg.get(JAVA_FLOAT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetBuffer3f(int buffer, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ try {
+ alGetBuffer3f.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static Value3.OfFloat getBuffer3f(int buffer, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg1 = stack.calloc(JAVA_FLOAT);
+ final MemorySegment seg2 = stack.calloc(JAVA_FLOAT);
+ final MemorySegment seg3 = stack.calloc(JAVA_FLOAT);
+ ngetBuffer3f(buffer, param, seg1, seg2, seg3);
+ return new Value3.OfFloat(seg1.get(JAVA_FLOAT, 0), seg2.get(JAVA_FLOAT, 0), seg3.get(JAVA_FLOAT, 0));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetBufferfv(int buffer, int param, MemorySegment values) {
+ try {
+ alGetBufferfv.invokeExact(buffer, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getBufferfv(SegmentAllocator allocator, int buffer, int param, float[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
+ ngetBufferfv(buffer, param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static void ngetBufferi(int buffer, int param, MemorySegment value) {
+ try {
+ alGetBufferi.invokeExact(buffer, param, value);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static float getBufferi(int buffer, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg = stack.calloc(JAVA_INT);
+ ngetBufferi(buffer, param, seg);
+ return seg.get(JAVA_INT, 0);
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetBuffer3i(int buffer, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ try {
+ alGetBuffer3i.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static Value3.OfInt getBuffer3i(int buffer, int param) {
+ final MemoryStack stack = MemoryStack.stackGet();
+ final long stackPointer = stack.getPointer();
+ try {
+ final MemorySegment seg1 = stack.calloc(JAVA_INT);
+ final MemorySegment seg2 = stack.calloc(JAVA_INT);
+ final MemorySegment seg3 = stack.calloc(JAVA_INT);
+ ngetBuffer3i(buffer, param, seg1, seg2, seg3);
+ return new Value3.OfInt(seg1.get(JAVA_INT, 0), seg2.get(JAVA_INT, 0), seg3.get(JAVA_INT, 0));
+ } finally {
+ stack.setPointer(stackPointer);
+ }
+ }
+
+ public static void ngetBufferiv(int buffer, int param, MemorySegment values) {
+ try {
+ alGetBufferiv.invokeExact(buffer, param, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getBufferiv(SegmentAllocator allocator, int buffer, int param, int[] values) {
+ final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
+ ngetBufferiv(buffer, param, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
}
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
index 0d836249..b1abafc0 100644
--- a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
@@ -20,12 +20,11 @@
import org.overrun.glib.RuntimeHelper;
import java.lang.foreign.FunctionDescriptor;
-import java.lang.foreign.MemorySegment;
import java.lang.foreign.SymbolLookup;
import java.lang.invoke.MethodHandle;
-import static org.overrun.glib.FunctionDescriptors.IV;
-import static org.overrun.glib.FunctionDescriptors.IZ;
+import static org.overrun.glib.FunctionDescriptors.*;
+import static org.overrun.glib.FunctionDescriptors.FV;
/**
* The OpenAL method handles.
@@ -37,7 +36,15 @@ final class Handles {
private static boolean initialized;
static SymbolLookup lookup;
static MethodHandle
- alEnable, alDisable, alIsEnabled;
+ alEnable, alDisable, alIsEnabled, alDopplerFactor, alDopplerVelocity, alSpeedOfSound, alDistanceModel, alGetString,
+ alGetBooleanv, alGetIntegerv, alGetFloatv, alGetDoublev, alGetBoolean, alGetInteger, alGetFloat, alGetDouble, alGetError,
+ alIsExtensionPresent, alGetProcAddress, alGetEnumValue, alListenerf, alListener3f, alListenerfv, alListeneri, alListener3i,
+ alListeneriv, alGetListenerf, alGetListener3f, alGetListenerfv, alGetListeneri, alGetListener3i, alGetListeneriv,
+ alGenSources, alDeleteSources, alIsSource, alSourcef, alSource3f, alSourcefv, alSourcei, alSource3i, alSourceiv,
+ alGetSourcef, alGetSource3f, alGetSourcefv, alGetSourcei, alGetSource3i, alGetSourceiv, alSourcePlay, alSourceStop,
+ alSourceRewind, alSourcePause, alSourcePlayv, alSourceStopv, alSourceRewindv, alSourcePausev, alSourceQueueBuffers,
+ alSourceUnqueueBuffers, alGenBuffers, alDeleteBuffers, alIsBuffer, alBufferData, alBufferf, alBuffer3f, alBufferfv,
+ alBufferi, alBuffer3i, alBufferiv, alGetBufferf, alGetBuffer3f, alGetBufferfv, alGetBufferi, alGetBuffer3i, alGetBufferiv;
private static MethodHandle downcall(String name,
FunctionDescriptor function) {
@@ -49,18 +56,83 @@ private static MethodHandle downcall(String name,
return RuntimeHelper.downcallThrow(lookup.find(name), function);
}
- private static MethodHandle downcallNative(String name,
- FunctionDescriptors function) {
- return RuntimeHelper.downcallSafe(lookup.find(name).orElse(MemorySegment.NULL), function);
- }
-
static void create() {
if (initialized) return;
initialized = true;
lookup = RuntimeHelper.load("openal", "openal", RuntimeHelper.VERSION);
- alEnable = downcallNative("alEnable", IV);
- alDisable = downcallNative("alDisable", IV);
- alIsEnabled = downcallNative("alIsEnabled", IZ);
+ alEnable = downcall("alEnable", IV);
+ alDisable = downcall("alDisable", IV);
+ alIsEnabled = downcall("alIsEnabled", IZ);
+ alDopplerFactor = downcall("alDopplerFactor", FV);
+ alDopplerVelocity = downcall("alDopplerVelocity", FV);
+ alSpeedOfSound = downcall("alSpeedOfSound", FV);
+ alDistanceModel = downcall("alDistanceModel", IV);
+ alGetString = downcall("alGetString", Ip);
+ alGetBooleanv = downcall("alGetBooleanv", IPV);
+ alGetIntegerv = downcall("alGetIntegerv", IPV);
+ alGetFloatv = downcall("alGetFloatv", IPV);
+ alGetDoublev = downcall("alGetDoublev", IPV);
+ alGetBoolean = downcall("alGetBoolean", IZ);
+ alGetInteger = downcall("alGetInteger", II);
+ alGetFloat = downcall("alGetFloat", IF);
+ alGetDouble = downcall("alGetDouble", ID);
+ alGetError = downcall("alGetError", I);
+ alIsExtensionPresent = downcall("alIsExtensionPresent", PZ);
+ alGetProcAddress = downcall("alGetProcAddress", PP);
+ alGetEnumValue = downcall("alGetEnumValue", fd_PI);
+ alListenerf = downcall("alListenerf", IFV);
+ alListener3f = downcall("alListener3f", IFFFV);
+ alListenerfv = downcall("alListenerfv", IPV);
+ alListeneri = downcall("alListeneri", IIV);
+ alListener3i = downcall("alListener3i", IIIIV);
+ alListeneriv = downcall("alListeneriv", IPV);
+ alGetListenerf = downcall("alGetListenerf", IPV);
+ alGetListener3f = downcall("alGetListener3f", IPPPV);
+ alGetListenerfv = downcall("alGetListenerfv", IPV);
+ alGetListeneri = downcall("alGetListeneri", IPV);
+ alGetListener3i = downcall("alGetListener3i", IPPPV);
+ alGetListeneriv = downcall("alGetListeneriv", IPV);
+ alGenSources = downcall("alGenSources", IPV);
+ alDeleteSources = downcall("alDeleteSources", IPV);
+ alIsSource = downcall("alIsSource", IZ);
+ alSourcef = downcall("alSourcef", IIFV);
+ alSource3f = downcall("alSource3f", IIFFFV);
+ alSourcefv = downcall("alSourcefv", IIPV);
+ alSourcei = downcall("alSourcei", IIIV);
+ alSource3i = downcall("alSource3i", IIIIIV);
+ alSourceiv = downcall("alSourceiv", IIPV);
+ alGetSourcef = downcall("alGetSourcef", IIPV);
+ alGetSource3f = downcall("alGetSource3f", IIPPPV);
+ alGetSourcefv = downcall("alGetSourcefv", IIPV);
+ alGetSourcei = downcall("alGetSourcei", IIPV);
+ alGetSource3i = downcall("alGetSource3i", IIPPPV);
+ alGetSourceiv = downcall("alGetSourceiv", IIPV);
+ alSourcePlay = downcall("alSourcePlay", IV);
+ alSourceStop = downcall("alSourceStop", IV);
+ alSourceRewind = downcall("alSourceRewind", IV);
+ alSourcePause = downcall("alSourcePause", IV);
+ alSourcePlayv = downcall("alSourcePlayv", IPV);
+ alSourceStopv = downcall("alSourceStopv", IPV);
+ alSourceRewindv = downcall("alSourceRewindv", IPV);
+ alSourcePausev = downcall("alSourcePausev", IPV);
+ alSourceQueueBuffers = downcall("alSourceQueueBuffers", IIPV);
+ alSourceUnqueueBuffers = downcall("alSourceUnqueueBuffers", IIPV);
+ alGenBuffers = downcall("alGenBuffers", IPV);
+ alDeleteBuffers = downcall("alDeleteBuffers", IPV);
+ alIsBuffer = downcall("alIsBuffer", IZ);
+ alBufferData = downcall("alBufferData", IIPIIV);
+ alBufferf = downcall("alBufferf", IIFV);
+ alBuffer3f = downcall("alBuffer3f", IIFFFV);
+ alBufferfv = downcall("alBufferfv", IIPV);
+ alBufferi = downcall("alBufferi", IIIV);
+ alBuffer3i = downcall("alBuffer3i", IIIIIV);
+ alBufferiv = downcall("alBufferiv", IIPV);
+ alGetBufferf = downcall("alGetBufferf", IIPV);
+ alGetBuffer3f = downcall("alGetBuffer3f", IIPPPV);
+ alGetBufferfv = downcall("alGetBufferfv", IIPV);
+ alGetBufferi = downcall("alGetBufferi", IIPV);
+ alGetBuffer3i = downcall("alGetBuffer3i", IIPPPV);
+ alGetBufferiv = downcall("alGetBufferiv", IIPV);
}
}
From 9eb8d2d542c270a103dfc56dd8fd1b6238b87c20 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Sat, 10 Jun 2023 21:28:39 +0800
Subject: [PATCH 03/11] [AL] ALC
---
.../org/overrun/glib/FunctionDescriptors.java | 10 +-
.../main/java/org/overrun/glib/glfw/GLFW.java | 8 +-
.../main/java/org/overrungl/glib/al/AL.java | 253 ++++++++++++-
.../main/java/org/overrungl/glib/al/ALC.java | 350 ++++++++++++++++++
.../java/org/overrungl/glib/al/Handles.java | 48 ++-
.../org/overrun/glib/stb/STBEasyFont.java | 6 +-
.../java/org/overrun/glib/stb/STBImage.java | 10 +-
.../org/overrun/glib/stb/STBImageResize.java | 10 +-
.../org/overrun/glib/stb/STBImageWrite.java | 10 +-
.../java/org/overrun/glib/stb/STBPerlin.java | 6 +-
10 files changed, 672 insertions(+), 39 deletions(-)
create mode 100644 modules/overrungl/openal/src/main/java/org/overrungl/glib/al/ALC.java
diff --git a/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java b/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java
index a49ac942..b3dc3af0 100644
--- a/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java
+++ b/modules/overrungl/core/src/main/java/org/overrun/glib/FunctionDescriptors.java
@@ -54,15 +54,15 @@ public enum FunctionDescriptors {
fd_PI("PI"),
PJ, PP, Pp, PV, PZ, SV, ZV,
// 3
- DDV, FFV, FZV, IDV, IFV, III, IIJ, IIP, IIp, IIV, IIZ, IJV, IPI, IPP, IPp, IPV, IPZ, ISV, JIV, JJP, PFV, PII, PIV, PJP,
- PPI, PPP, PPp, PPV, SSV,
+ DDV, FFV, FZV, IDV, IFV, III, IIJ, IIP, IIp, IIV, IIZ, IJV, IPI, IPP, IPp, IPV, IPZ, ISV, JIV, JJP, PFV, PII, PIp, PIV,
+ PJP, PPI, PPP, PPp, PPV, PPZ, SSV,
// 4
BBBV, DDDV, FFFV, IDDV, IFFV, IIDV, IIFV, IIII, IIIV, IIJV, IIPI, IIPV, IJJV, IPIV, IPPV, IPPZ, ISSV, PDDV, PIIP, PIIV,
- PIJI, PIJP, PIJV, PIPp, PIPV, PPII, PPIP, PPJP, PPPV, SSSV,
+ PIJI, PIJP, PIJV, PIPp, PIPV, PPII, PPIP, PPIV, PPJP, PPPV, SSSV,
// 5
BBBBV, DDDDV, FFFFV, IDDDV, IFFFV, IIDDV, IIFFV, IIFIV, IIIIV, IIIJV, IIIPV, IIJIV, IIJJV, IIPIV, IIPPV, IIZIV, IIZPV,
- IJJIP, IJJJV, IJJPV, IJJZV, IJPIV, IPIIV, IPIPV, IPPIV, IPPPV, ISSSV, PIIIP, PIIPp, PIPII, PIPIp, PIPPV, PPPPI, PPPPV,
- SSSSV, ZZZZV,
+ IJJIP, IJJJV, IJJPV, IJJZV, IJPIV, IPIIV, IPIPV, IPPIV, IPPPV, ISSSV, PIIIP, PIIPp, PIIPV, PIPII, PIPIp, PIPPV, PPPPI,
+ PPPPV, SSSSV, ZZZZV,
// 6
FFFFFV, IBBBBV, IDDDDV, IFFFFV, IIDDDV, IIFFFV, IIIFIV, IIIIIV, IIIIPV, IIIJIV, IIIJJV, IIIPIV, IIIPPP, IIIPPV, IIIPZV,
IIIZIV, IIIZPV, IIJJJV, IIPIIV, IIPIPV, IIPPPP, IIPPPV, IIZIIJ, IJJJJV, IPIPIV, IPIPPV, IPJIIV, IPPIPV, ISSSSV, IZIIPV,
diff --git a/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java b/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java
index 98489b28..71a2a1f9 100644
--- a/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java
+++ b/modules/overrungl/glfw/src/main/java/org/overrun/glib/glfw/GLFW.java
@@ -37,6 +37,10 @@
* @since 0.1.0
*/
public final class GLFW {
+ static {
+ create();
+ }
+
/**
* The major version number of the GLFW header.
*
@@ -845,10 +849,6 @@ public final class GLFW {
*/
public static final int DONT_CARE = -1;
- static {
- create();
- }
-
private GLFW() {
throw new IllegalStateException("Do not construct instance");
}
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
index 7d03a7ff..6cd50c16 100644
--- a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/AL.java
@@ -33,6 +33,10 @@
* @since 0.1.0
*/
public final class AL {
+ static {
+ create();
+ }
+
/**
* No distance model or no buffer
*/
@@ -421,10 +425,6 @@ public final class AL {
AL_EXPONENT_DISTANCE = 0xD005,
AL_EXPONENT_DISTANCE_CLAMPED = 0xD006;
- static {
- create();
- }
-
public static void enable(int capability) {
try {
alEnable.invokeExact(capability);
@@ -581,6 +581,12 @@ public static double getDouble(int param) {
}
}
+ /**
+ * Obtain the first error generated in the AL context since the last call to
+ * this function.
+ *
+ * @return the error code
+ */
public static int getError() {
try {
return (int) alGetError.invokeExact();
@@ -589,6 +595,12 @@ public static int getError() {
}
}
+ /**
+ * Query for the presence of an extension on the AL context.
+ *
+ * @param extName the name of the extension
+ * @return the presence of the given extension
+ */
public static boolean nisExtensionPresent(MemorySegment extName) {
try {
return (boolean) alIsExtensionPresent.invokeExact(extName);
@@ -597,10 +609,24 @@ public static boolean nisExtensionPresent(MemorySegment extName) {
}
}
+ /**
+ * Query for the presence of an extension on the AL context.
+ *
+ * @param extName the name of the extension
+ * @return the presence of the given extension
+ * @see #nisExtensionPresent(MemorySegment) nisExtensionPresent
+ */
public static boolean isExtensionPresent(SegmentAllocator allocator, String extName) {
return nisExtensionPresent(allocator.allocateUtf8String(extName));
}
+ /**
+ * Retrieve the address of a function.
+ * The returned function may be context-specific.
+ *
+ * @param fname the name of the function
+ * @return the address of the given function
+ */
public static MemorySegment ngetProcAddress(MemorySegment fname) {
try {
return (MemorySegment) alGetProcAddress.invokeExact(fname);
@@ -609,10 +635,24 @@ public static MemorySegment ngetProcAddress(MemorySegment fname) {
}
}
+ /**
+ * Retrieve the address of a function.
+ * The returned function may be context-specific.
+ *
+ * @param fname the name of the function
+ * @return the address of the given function
+ * @see #ngetProcAddress(MemorySegment) ngetProcAddress
+ */
public static MemorySegment getProcAddress(SegmentAllocator allocator, String fname) {
return ngetProcAddress(allocator.allocateUtf8String(fname));
}
+ /**
+ * Retrieve the value of an enum. The returned value may be context-specific.
+ *
+ * @param ename the name of the enum
+ * @return the value of the given enum
+ */
public static int ngetEnumValue(MemorySegment ename) {
try {
return (int) alGetEnumValue.invokeExact(ename);
@@ -621,6 +661,13 @@ public static int ngetEnumValue(MemorySegment ename) {
}
}
+ /**
+ * Retrieve the value of an enum. The returned value may be context-specific.
+ *
+ * @param ename the name of the enum
+ * @return the value of the given enum
+ * @see #ngetEnumValue(MemorySegment) ngetEnumValue
+ */
public static int getEnumValue(SegmentAllocator allocator, String ename) {
return ngetEnumValue(allocator.allocateUtf8String(ename));
}
@@ -793,6 +840,12 @@ public static void getListeneriv(SegmentAllocator allocator, int param, int[] va
RuntimeHelper.toArray(seg, values);
}
+ /**
+ * Create source objects.
+ *
+ * @param n the count of the objects.
+ * @param sources a buffer that retrieves the objects.
+ */
public static void ngenSources(int n, MemorySegment sources) {
try {
alGenSources.invokeExact(n, sources);
@@ -801,12 +854,25 @@ public static void ngenSources(int n, MemorySegment sources) {
}
}
+ /**
+ * Create source objects.
+ *
+ * @param allocator the allocator of the buffer.
+ * @param sources an array that retrieves the objects.
+ * @see #ngenSources(int, MemorySegment) ngenSources
+ */
public static void genSources(SegmentAllocator allocator, int[] sources) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
ngenSources(sources.length, seg);
RuntimeHelper.toArray(seg, sources);
}
+ /**
+ * Create a source object.
+ *
+ * @return the object.
+ * @see #ngenSources(int, MemorySegment) ngenSources
+ */
public static int genSource() {
final MemoryStack stack = MemoryStack.stackGet();
final long stackPointer = stack.getPointer();
@@ -819,6 +885,12 @@ public static int genSource() {
}
}
+ /**
+ * Delete source objects.
+ *
+ * @param n the count of the objects.
+ * @param sources the objects.
+ */
public static void ndeleteSources(int n, MemorySegment sources) {
try {
alDeleteSources.invokeExact(n, sources);
@@ -827,10 +899,23 @@ public static void ndeleteSources(int n, MemorySegment sources) {
}
}
+ /**
+ * Delete source objects.
+ *
+ * @param allocator the allocator of the buffer.
+ * @param sources the objects.
+ * @see #ndeleteSources(int, MemorySegment) ndeleteSources
+ */
public static void deleteSources(SegmentAllocator allocator, int[] sources) {
ndeleteSources(sources.length, allocator.allocateArray(JAVA_INT, sources));
}
+ /**
+ * Delete a source object.
+ *
+ * @param source the object.
+ * @see #ndeleteSources(int, MemorySegment) ndeleteSources
+ */
public static void deleteSource(int source) {
final MemoryStack stack = MemoryStack.stackGet();
final long stackPointer = stack.getPointer();
@@ -841,6 +926,12 @@ public static void deleteSource(int source) {
}
}
+ /**
+ * Verify an ID is for a valid source.
+ *
+ * @param source an ID of a source
+ * @return the result
+ */
public static boolean isSource(int source) {
try {
return (boolean) alIsSource.invokeExact(source);
@@ -1017,6 +1108,11 @@ public static void getSourceiv(SegmentAllocator allocator, int source, int param
RuntimeHelper.toArray(seg, values);
}
+ /**
+ * Play, restart, or resume a source, setting its state to {@link #AL_PLAYING}.
+ *
+ * @param source the ID of the source
+ */
public static void sourcePlay(int source) {
try {
alSourcePlay.invokeExact(source);
@@ -1025,6 +1121,11 @@ public static void sourcePlay(int source) {
}
}
+ /**
+ * Stop a source, setting its state to {@link #AL_STOPPED} if playing or paused.
+ *
+ * @param source the ID of the source
+ */
public static void sourceStop(int source) {
try {
alSourceStop.invokeExact(source);
@@ -1033,6 +1134,11 @@ public static void sourceStop(int source) {
}
}
+ /**
+ * Rewind a source, setting its state to {@link #AL_INITIAL}.
+ *
+ * @param source the ID of the source
+ */
public static void sourceRewind(int source) {
try {
alSourceRewind.invokeExact(source);
@@ -1041,6 +1147,11 @@ public static void sourceRewind(int source) {
}
}
+ /**
+ * Pause a source, setting its state to {@link #AL_PAUSED} if playing.
+ *
+ * @param source the ID of the source
+ */
public static void sourcePause(int source) {
try {
alSourcePause.invokeExact(source);
@@ -1049,6 +1160,12 @@ public static void sourcePause(int source) {
}
}
+ /**
+ * Play, restart, or resume a list of sources atomically.
+ *
+ * @param n the count of the sources
+ * @param sources the sources
+ */
public static void nsourcePlayv(int n, MemorySegment sources) {
try {
alSourcePlayv.invokeExact(n, sources);
@@ -1057,12 +1174,25 @@ public static void nsourcePlayv(int n, MemorySegment sources) {
}
}
+ /**
+ * Play, restart, or resume a list of sources atomically.
+ *
+ * @param allocator the allocator of the sources
+ * @param sources the sources
+ * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
+ */
public static void sourcePlayv(SegmentAllocator allocator, int[] sources) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
nsourcePlayv(sources.length, seg);
RuntimeHelper.toArray(seg, sources);
}
+ /**
+ * Stop a list of sources atomically.
+ *
+ * @param n the count of the sources
+ * @param sources the sources
+ */
public static void nsourceStopv(int n, MemorySegment sources) {
try {
alSourceStopv.invokeExact(n, sources);
@@ -1071,12 +1201,25 @@ public static void nsourceStopv(int n, MemorySegment sources) {
}
}
+ /**
+ * Stop a list of sources atomically.
+ *
+ * @param allocator the allocator of the sources
+ * @param sources the sources
+ * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
+ */
public static void sourceStopv(SegmentAllocator allocator, int[] sources) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
nsourceStopv(sources.length, seg);
RuntimeHelper.toArray(seg, sources);
}
+ /**
+ * Rewind a list of sources atomically.
+ *
+ * @param n the count of the sources
+ * @param sources the sources
+ */
public static void nsourceRewindv(int n, MemorySegment sources) {
try {
alSourceRewindv.invokeExact(n, sources);
@@ -1085,12 +1228,25 @@ public static void nsourceRewindv(int n, MemorySegment sources) {
}
}
+ /**
+ * Rewind a list of sources atomically.
+ *
+ * @param allocator the allocator of the sources
+ * @param sources the sources
+ * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
+ */
public static void sourceRewindv(SegmentAllocator allocator, int[] sources) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
nsourceRewindv(sources.length, seg);
RuntimeHelper.toArray(seg, sources);
}
+ /**
+ * Pause a list of sources atomically.
+ *
+ * @param n the count of the sources
+ * @param sources the sources
+ */
public static void nsourcePausev(int n, MemorySegment sources) {
try {
alSourcePausev.invokeExact(n, sources);
@@ -1099,12 +1255,26 @@ public static void nsourcePausev(int n, MemorySegment sources) {
}
}
+ /**
+ * Pause a list of sources atomically.
+ *
+ * @param allocator the allocator of the sources
+ * @param sources the sources
+ * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
+ */
public static void sourcePausev(SegmentAllocator allocator, int[] sources) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
nsourcePausev(sources.length, seg);
RuntimeHelper.toArray(seg, sources);
}
+ /**
+ * Queue buffers onto a source
+ *
+ * @param source the source
+ * @param nb the count of the buffers
+ * @param buffers the buffers
+ */
public static void nsourceQueueBuffers(int source, int nb, MemorySegment buffers) {
try {
alSourceQueueBuffers.invokeExact(source, nb, buffers);
@@ -1113,10 +1283,24 @@ public static void nsourceQueueBuffers(int source, int nb, MemorySegment buffers
}
}
+ /**
+ * Queue buffers onto a source
+ *
+ * @param allocator the allocator of the buffers
+ * @param source the source
+ * @param buffers the buffers
+ */
public static void sourceQueueBuffers(SegmentAllocator allocator, int source, int[] buffers) {
nsourceQueueBuffers(source, buffers.length, allocator.allocateArray(JAVA_INT, buffers));
}
+ /**
+ * Unqueue processed buffers from a source
+ *
+ * @param source the source
+ * @param nb the count of the buffers
+ * @param buffers the buffers
+ */
public static void nsourceUnqueueBuffers(int source, int nb, MemorySegment buffers) {
try {
alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
@@ -1125,12 +1309,25 @@ public static void nsourceUnqueueBuffers(int source, int nb, MemorySegment buffe
}
}
+ /**
+ * Unqueue processed buffers from a source
+ *
+ * @param allocator the allocator of the buffers
+ * @param source the source
+ * @param buffers the buffers
+ */
public static void sourceUnqueueBuffers(SegmentAllocator allocator, int source, int[] buffers) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, buffers);
nsourceUnqueueBuffers(source, buffers.length, seg);
RuntimeHelper.toArray(seg, buffers);
}
+ /**
+ * Create buffer objects.
+ *
+ * @param n the count of the objects.
+ * @param buffers a buffer that retrieves the objects.
+ */
public static void ngenBuffers(int n, MemorySegment buffers) {
try {
alGenBuffers.invokeExact(n, buffers);
@@ -1139,12 +1336,25 @@ public static void ngenBuffers(int n, MemorySegment buffers) {
}
}
+ /**
+ * Create buffer objects.
+ *
+ * @param allocator the allocator of the buffer.
+ * @param buffers an array that retrieves the objects.
+ * @see #ngenBuffers(int, MemorySegment) ngenBuffers
+ */
public static void genBuffers(SegmentAllocator allocator, int[] buffers) {
final MemorySegment seg = allocator.allocateArray(JAVA_INT, buffers.length);
ngenBuffers(buffers.length, seg);
RuntimeHelper.toArray(seg, buffers);
}
+ /**
+ * Create a buffer object.
+ *
+ * @return the object.
+ * @see #ngenBuffers(int, MemorySegment) ngenBuffers
+ */
public static int genBuffer() {
final MemoryStack stack = MemoryStack.stackGet();
final long stackPointer = stack.getPointer();
@@ -1157,6 +1367,12 @@ public static int genBuffer() {
}
}
+ /**
+ * Delete buffer objects.
+ *
+ * @param n the count of the objects.
+ * @param buffers the objects.
+ */
public static void ndeleteBuffers(int n, MemorySegment buffers) {
try {
alDeleteBuffers.invokeExact(n, buffers);
@@ -1165,10 +1381,23 @@ public static void ndeleteBuffers(int n, MemorySegment buffers) {
}
}
+ /**
+ * Delete buffer objects.
+ *
+ * @param allocator the allocator of the buffer.
+ * @param buffers the objects.
+ * @see #ndeleteBuffers(int, MemorySegment) ndeleteBuffers
+ */
public static void deleteBuffers(SegmentAllocator allocator, int[] buffers) {
ndeleteBuffers(buffers.length, allocator.allocateArray(JAVA_INT, buffers));
}
+ /**
+ * Delete a buffer object.
+ *
+ * @param buffer the object.
+ * @see #ndeleteBuffers(int, MemorySegment) ndeleteBuffers
+ */
public static void deleteBuffer(int buffer) {
final MemoryStack stack = MemoryStack.stackGet();
final long stackPointer = stack.getPointer();
@@ -1179,6 +1408,12 @@ public static void deleteBuffer(int buffer) {
}
}
+ /**
+ * Verify an ID is a valid buffer (including the NULL buffer).
+ *
+ * @param buffer an ID of a buffer
+ * @return the result
+ */
public static boolean isBuffer(int buffer) {
try {
return (boolean) alIsBuffer.invokeExact(buffer);
@@ -1187,6 +1422,16 @@ public static boolean isBuffer(int buffer) {
}
}
+ /**
+ * Copies data into the buffer, interpreting it using the specified format and
+ * sample-rate.
+ *
+ * @param buffer the buffer ID
+ * @param format the data format
+ * @param data the data
+ * @param size the data size
+ * @param sampleRate the sample-rate
+ */
public static void bufferData(int buffer, int format, MemorySegment data, int size, int sampleRate) {
try {
alBufferData.invokeExact(buffer, format, data, size, sampleRate);
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/ALC.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/ALC.java
new file mode 100644
index 00000000..ba2e8e6d
--- /dev/null
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/ALC.java
@@ -0,0 +1,350 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2023 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package org.overrungl.glib.al;
+
+import org.overrun.glib.RuntimeHelper;
+
+import java.lang.foreign.MemorySegment;
+import java.lang.foreign.SegmentAllocator;
+import java.lang.foreign.ValueLayout;
+
+import static org.overrungl.glib.al.Handles.*;
+
+/**
+ * The OpenAL context binding.
+ *
+ * @author squid233
+ * @since 0.1.0
+ */
+public final class ALC {
+ static {
+ create();
+ }
+
+ /**
+ * Boolean False.
+ */
+ public static final int ALC_FALSE = 0;
+ /**
+ * Boolean True.
+ */
+ public static final int ALC_TRUE = 1;
+ /**
+ * Context attribute: Hz.
+ */
+ public static final int ALC_FREQUENCY = 0x1007;
+ /**
+ * Context attribute: Hz.
+ */
+ public static final int ALC_REFRESH = 0x1008;
+ /**
+ * Context attribute: AL_TRUE or AL_FALSE synchronous context?
+ */
+ public static final int ALC_SYNC = 0x1009;
+ /**
+ * Context attribute: requested Mono (3D) Sources.
+ */
+ public static final int ALC_MONO_SOURCES = 0x1010;
+ /**
+ * Context attribute: requested Stereo Sources.
+ */
+ public static final int ALC_STEREO_SOURCES = 0x1011;
+ /**
+ * No error.
+ */
+ public static final int ALC_NO_ERROR = 0;
+ /**
+ * Invalid device handle.
+ */
+ public static final int ALC_INVALID_DEVICE = 0xA001;
+ /**
+ * Invalid context handle.
+ */
+ public static final int ALC_INVALID_CONTEXT = 0xA002;
+ /**
+ * Invalid enumeration passed to an ALC call.
+ */
+ public static final int ALC_INVALID_ENUM = 0xA003;
+ /**
+ * Invalid value passed to an ALC call.
+ */
+ public static final int ALC_INVALID_VALUE = 0xA004;
+
+ /**
+ * Out of memory.
+ */
+ public static final int ALC_OUT_OF_MEMORY = 0xA005;
+ /**
+ * Runtime ALC major version.
+ */
+ public static final int ALC_MAJOR_VERSION = 0x1000;
+ /**
+ * Runtime ALC minor version.
+ */
+ public static final int ALC_MINOR_VERSION = 0x1001;
+ /**
+ * Context attribute list size.
+ */
+ public static final int ALC_ATTRIBUTES_SIZE = 0x1002;
+ /**
+ * Context attribute list properties.
+ */
+ public static final int ALC_ALL_ATTRIBUTES = 0x1003;
+ /**
+ * String for the default device specifier.
+ */
+ public static final int ALC_DEFAULT_DEVICE_SPECIFIER = 0x1004;
+ /**
+ * Device specifier string.
+ *
+ * If device handle is NULL, it is instead a null-character separated list of
+ * strings of known device specifiers (list ends with an empty string).
+ */
+ public static final int ALC_DEVICE_SPECIFIER = 0x1005;
+ /**
+ * String for space-separated list of ALC extensions.
+ */
+ public static final int ALC_EXTENSIONS = 0x1006;
+ /**
+ * Capture extension
+ */
+ public static final int ALC_EXT_CAPTURE = 1;
+ /**
+ * Capture device specifier string.
+ *
+ * If device handle is NULL, it is instead a null-character separated list of
+ * strings of known capture device specifiers (list ends with an empty string).
+ */
+ public static final int ALC_CAPTURE_DEVICE_SPECIFIER = 0x310;
+ /**
+ * String for the default capture device specifier.
+ */
+ public static final int ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER = 0x311;
+ /**
+ * Number of sample frames available for capture.
+ */
+ public static final int ALC_CAPTURE_SAMPLES = 0x312;
+ /**
+ * Enumerate All extension
+ */
+ public static final int ALC_ENUMERATE_ALL_EXT = 1;
+ /**
+ * String for the default extended device specifier.
+ */
+ public static final int ALC_DEFAULT_ALL_DEVICES_SPECIFIER = 0x1012;
+ /**
+ * Device's extended specifier string.
+ *
+ * If device handle is NULL, it is instead a null-character separated list of
+ * strings of known extended device specifiers (list ends with an empty string).
+ */
+ public static final int ALC_ALL_DEVICES_SPECIFIER = 0x1013;
+
+ public static MemorySegment ncreateContext(MemorySegment device, MemorySegment attrlist) {
+ try {
+ return (MemorySegment) alcCreateContext.invokeExact(device, attrlist);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment createContext(SegmentAllocator allocator, MemorySegment device, int[] attrlist) {
+ return ncreateContext(device, allocator.allocateArray(ValueLayout.JAVA_INT, attrlist));
+ }
+
+ public static boolean makeContextCurrent(MemorySegment context) {
+ try {
+ return (boolean) alcMakeContextCurrent.invokeExact(context);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void processContext(MemorySegment context) {
+ try {
+ alcProcessContext.invokeExact(context);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void suspendContext(MemorySegment context) {
+ try {
+ alcSuspendContext.invokeExact(context);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void destroyContext(MemorySegment context) {
+ try {
+ alcDestroyContext.invokeExact(context);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment getCurrentContext() {
+ try {
+ return (MemorySegment) alcGetCurrentContext.invokeExact();
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment getContextsDevice(MemorySegment context) {
+ try {
+ return (MemorySegment) alcGetContextsDevice.invokeExact(context);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment nopenDevice(MemorySegment deviceName) {
+ try {
+ return (MemorySegment) alcOpenDevice.invokeExact(deviceName);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment openDevice(SegmentAllocator allocator, String deviceName) {
+ return nopenDevice(allocator.allocateUtf8String(deviceName));
+ }
+
+ public static boolean closeDevice(MemorySegment device) {
+ try {
+ return (boolean) alcCloseDevice.invokeExact(device);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static int getError(MemorySegment device) {
+ try {
+ return (int) alcGetError.invokeExact(device);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static boolean nisExtensionPresent(MemorySegment device, MemorySegment extName) {
+ try {
+ return (boolean) alcIsExtensionPresent.invokeExact(device, extName);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static boolean isExtensionPresent(SegmentAllocator allocator, MemorySegment device, String extName) {
+ return nisExtensionPresent(device, allocator.allocateUtf8String(extName));
+ }
+
+ public static MemorySegment ngetProcAddress(MemorySegment device, MemorySegment funcName) {
+ try {
+ return (MemorySegment) alcGetProcAddress.invokeExact(device, funcName);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment getProcAddress(SegmentAllocator allocator, MemorySegment device, String funcName) {
+ return ngetProcAddress(device, allocator.allocateUtf8String(funcName));
+ }
+
+ public static int ngetEnumValue(MemorySegment device, MemorySegment enumName) {
+ try {
+ return (int) alcGetEnumValue.invokeExact(device, enumName);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static int getEnumValue(SegmentAllocator allocator, MemorySegment device, String enumName) {
+ return ngetEnumValue(device, allocator.allocateUtf8String(enumName));
+ }
+
+ public static MemorySegment ngetString(MemorySegment device, int param) {
+ try {
+ return (MemorySegment) alcGetString.invokeExact(device, param);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static String getString(MemorySegment device, int param) {
+ return ngetString(device, param).getUtf8String(0);
+ }
+
+ public static void ngetIntegerv(MemorySegment device, int param, int size, MemorySegment values) {
+ try {
+ alcGetIntegerv.invokeExact(device, param, size, values);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void getIntegerv(SegmentAllocator allocator, MemorySegment device, int param, int[] values) {
+ final MemorySegment seg = allocator.allocateArray(ValueLayout.JAVA_INT, values.length);
+ ngetIntegerv(device, param, values.length, seg);
+ RuntimeHelper.toArray(seg, values);
+ }
+
+ public static MemorySegment ncaptureOpenDevice(MemorySegment deviceName, int frequency, int format, int bufferSize) {
+ try {
+ return (MemorySegment) alcCaptureOpenDevice.invokeExact(deviceName, frequency, format, bufferSize);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static MemorySegment captureOpenDevice(SegmentAllocator allocator, String deviceName, int frequency, int format, int bufferSize) {
+ return ncaptureOpenDevice(allocator.allocateUtf8String(deviceName), frequency, format, bufferSize);
+ }
+
+ public static boolean captureCloseDevice(MemorySegment device) {
+ try {
+ return (boolean) alcCaptureCloseDevice.invokeExact(device);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void captureStart(MemorySegment device) {
+ try {
+ alcCaptureStart.invokeExact(device);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void captureStop(MemorySegment device) {
+ try {
+ alcCaptureStop.invokeExact(device);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+
+ public static void captureSamples(MemorySegment device, MemorySegment buffer, int samples) {
+ try {
+ alcCaptureSamples.invokeExact(device, buffer, samples);
+ } catch (Throwable e) {
+ throw new AssertionError("should not reach here", e);
+ }
+ }
+}
diff --git a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
index b1abafc0..6c0ab07f 100644
--- a/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
+++ b/modules/overrungl/openal/src/main/java/org/overrungl/glib/al/Handles.java
@@ -35,6 +35,9 @@
final class Handles {
private static boolean initialized;
static SymbolLookup lookup;
+ /**
+ * AL
+ */
static MethodHandle
alEnable, alDisable, alIsEnabled, alDopplerFactor, alDopplerVelocity, alSpeedOfSound, alDistanceModel, alGetString,
alGetBooleanv, alGetIntegerv, alGetFloatv, alGetDoublev, alGetBoolean, alGetInteger, alGetFloat, alGetDouble, alGetError,
@@ -45,6 +48,13 @@ final class Handles {
alSourceRewind, alSourcePause, alSourcePlayv, alSourceStopv, alSourceRewindv, alSourcePausev, alSourceQueueBuffers,
alSourceUnqueueBuffers, alGenBuffers, alDeleteBuffers, alIsBuffer, alBufferData, alBufferf, alBuffer3f, alBufferfv,
alBufferi, alBuffer3i, alBufferiv, alGetBufferf, alGetBuffer3f, alGetBufferfv, alGetBufferi, alGetBuffer3i, alGetBufferiv;
+ /**
+ * ALC
+ */
+ static MethodHandle
+ alcCreateContext, alcMakeContextCurrent, alcProcessContext, alcSuspendContext, alcDestroyContext, alcGetCurrentContext,
+ alcGetContextsDevice, alcOpenDevice, alcCloseDevice, alcGetError, alcIsExtensionPresent, alcGetProcAddress, alcGetEnumValue,
+ alcGetString, alcGetIntegerv, alcCaptureOpenDevice, alcCaptureCloseDevice, alcCaptureStart, alcCaptureStop, alcCaptureSamples;
private static MethodHandle downcall(String name,
FunctionDescriptor function) {
@@ -56,11 +66,7 @@ private static MethodHandle downcall(String name,
return RuntimeHelper.downcallThrow(lookup.find(name), function);
}
- static void create() {
- if (initialized) return;
- initialized = true;
-
- lookup = RuntimeHelper.load("openal", "openal", RuntimeHelper.VERSION);
+ private static void createAL() {
alEnable = downcall("alEnable", IV);
alDisable = downcall("alDisable", IV);
alIsEnabled = downcall("alIsEnabled", IZ);
@@ -135,4 +141,36 @@ static void create() {
alGetBuffer3i = downcall("alGetBuffer3i", IIPPPV);
alGetBufferiv = downcall("alGetBufferiv", IIPV);
}
+
+ private static void createALC() {
+ alcCreateContext = downcall("alcCreateContext", PPP);
+ alcMakeContextCurrent = downcall("alcMakeContextCurrent", PZ);
+ alcProcessContext = downcall("alcProcessContext", PV);
+ alcSuspendContext = downcall("alcSuspendContext", PV);
+ alcDestroyContext = downcall("alcDestroyContext", PV);
+ alcGetCurrentContext = downcall("alcGetCurrentContext", P);
+ alcGetContextsDevice = downcall("alcGetContextsDevice", PP);
+ alcOpenDevice = downcall("alcOpenDevice", PP);
+ alcCloseDevice = downcall("alcCloseDevice", PZ);
+ alcGetError = downcall("alcGetError", fd_PI);
+ alcIsExtensionPresent = downcall("alcIsExtensionPresent", PPZ);
+ alcGetProcAddress = downcall("alcGetProcAddress", PPP);
+ alcGetEnumValue = downcall("alcGetEnumValue", PPI);
+ alcGetString = downcall("alcGetString", PIp);
+ alcGetIntegerv = downcall("alcGetIntegerv", PIIPV);
+ alcCaptureOpenDevice = downcall("alcCaptureOpenDevice", PIIIP);
+ alcCaptureCloseDevice = downcall("alcCaptureCloseDevice", PZ);
+ alcCaptureStart = downcall("alcCaptureStart", PV);
+ alcCaptureStop = downcall("alcCaptureStop", PV);
+ alcCaptureSamples = downcall("alcCaptureSamples", PPIV);
+ }
+
+ static void create() {
+ if (initialized) return;
+ initialized = true;
+
+ lookup = RuntimeHelper.load("openal", "openal", RuntimeHelper.VERSION);
+ createAL();
+ createALC();
+ }
}
diff --git a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBEasyFont.java b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBEasyFont.java
index 4014e922..13472dcc 100644
--- a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBEasyFont.java
+++ b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBEasyFont.java
@@ -57,14 +57,14 @@
* @since 0.1.0
*/
public final class STBEasyFont {
- private static MethodHandle
- stb_easy_font_draw_segs, stb_easy_font_get_spacing, stb_easy_font_spacing, stb_easy_font_print, stb_easy_font_width, stb_easy_font_height;
-
static {
initialize();
create();
}
+ private static MethodHandle
+ stb_easy_font_draw_segs, stb_easy_font_get_spacing, stb_easy_font_spacing, stb_easy_font_print, stb_easy_font_width, stb_easy_font_height;
+
private STBEasyFont() {
//no instance
}
diff --git a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImage.java b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImage.java
index a302e9d7..3765463a 100644
--- a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImage.java
+++ b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImage.java
@@ -37,6 +37,11 @@
* @since 0.1.0
*/
public final class STBImage {
+ static {
+ initialize();
+ create();
+ }
+
private static MethodHandle
stbi_convert_iphone_png_to_rgb, stbi_convert_iphone_png_to_rgb_thread, stbi_failure_reason, stbi_hdr_to_ldr_gamma,
stbi_hdr_to_ldr_scale, stbi_image_free, stbi_info, stbi_info_from_callbacks, stbi_info_from_file, stbi_info_from_memory,
@@ -60,11 +65,6 @@ public final class STBImage {
RGB = 3,
RGB_ALPHA = 4;
- static {
- initialize();
- create();
- }
-
private static void create() {
stbi_convert_iphone_png_to_rgb = downcall("stbi_convert_iphone_png_to_rgb", IV);
stbi_convert_iphone_png_to_rgb_thread = downcall("stbi_convert_iphone_png_to_rgb_thread", IV);
diff --git a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageResize.java b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageResize.java
index 30e229fa..67990cb1 100644
--- a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageResize.java
+++ b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageResize.java
@@ -34,16 +34,16 @@
* @since 0.1.0
*/
public final class STBImageResize {
- private static MethodHandle
- stbir_resize, stbir_resize_float, stbir_resize_float_generic, stbir_resize_region, stbir_resize_subpixel,
- stbir_resize_uint16_generic, stbir_resize_uint8, stbir_resize_uint8_generic, stbir_resize_uint8_srgb,
- stbir_resize_uint8_srgb_edgemode;
-
static {
initialize();
create();
}
+ private static MethodHandle
+ stbir_resize, stbir_resize_float, stbir_resize_float_generic, stbir_resize_region, stbir_resize_subpixel,
+ stbir_resize_uint16_generic, stbir_resize_uint8, stbir_resize_uint8_generic, stbir_resize_uint8_srgb,
+ stbir_resize_uint8_srgb_edgemode;
+
private static void create() {
stbir_resize = downcall("stbir_resize", PIIIPIIIIIIIIIIIIPI);
stbir_resize_float = downcall("stbir_resize_float", PIIIPIIIII);
diff --git a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageWrite.java b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageWrite.java
index 89914110..adbf4e75 100644
--- a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageWrite.java
+++ b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBImageWrite.java
@@ -35,6 +35,11 @@
* @since 0.1.0
*/
public final class STBImageWrite {
+ static {
+ initialize();
+ create();
+ }
+
private static MethodHandle
stbi_flip_vertically_on_write, stbi_get_write_force_png_filter, stbi_get_write_png_compression_level,
stbi_get_write_tga_with_rle, stbi_set_write_force_png_filter, stbi_set_write_png_compression_level,
@@ -42,11 +47,6 @@ public final class STBImageWrite {
stbi_write_jpg, stbi_write_jpg_to_func, stbi_write_png, stbi_write_png_to_func, stbi_write_png_to_mem,
stbi_write_tga, stbi_write_tga_to_func, stbi_zlib_compress;
- static {
- initialize();
- create();
- }
-
private static void create() {
stbi_flip_vertically_on_write = downcall("stbi_flip_vertically_on_write", IV);
stbi_get_write_force_png_filter = downcall("stbi_get_write_force_png_filter", I);
diff --git a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBPerlin.java b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBPerlin.java
index d20e8bbc..a0005626 100644
--- a/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBPerlin.java
+++ b/modules/overrungl/stb/src/main/java/org/overrun/glib/stb/STBPerlin.java
@@ -29,14 +29,14 @@
* @since 0.1.0
*/
public final class STBPerlin {
- private static MethodHandle
- stb_perlin_noise3, stb_perlin_noise3_seed, stb_perlin_ridge_noise3, stb_perlin_fbm_noise3, stb_perlin_turbulence_noise3, stb_perlin_noise3_wrap_nonpow2;
-
static {
initialize();
create();
}
+ private static MethodHandle
+ stb_perlin_noise3, stb_perlin_noise3_seed, stb_perlin_ridge_noise3, stb_perlin_fbm_noise3, stb_perlin_turbulence_noise3, stb_perlin_noise3_wrap_nonpow2;
+
private static void create() {
stb_perlin_noise3 = downcall("stb_perlin_noise3", FFFIIIF);
stb_perlin_noise3_seed = downcall("stb_perlin_noise3_seed", FFFIIIIF);
From 26a32f7dcdd6363057dfca85cf9c1b4c6529a90b Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Thu, 15 Jun 2023 13:31:44 +0800
Subject: [PATCH 04/11] Add missing Pair.java
---
.../org/overrun/glib/util/value/Pair.java | 114 ++++++++++++++++++
1 file changed, 114 insertions(+)
diff --git a/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Pair.java b/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Pair.java
index e69de29b..65b83d38 100644
--- a/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Pair.java
+++ b/modules/overrungl/core/src/main/java/org/overrun/glib/util/value/Pair.java
@@ -0,0 +1,114 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2023 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package org.overrun.glib.util.value;
+
+/**
+ * A pair of the same type objects.
+ *
+ * @param the type.
+ * @param x the first value.
+ * @param y the second value.
+ * @author squid233
+ * @since 0.1.0
+ */
+public /* value */ record Pair(T x, T y) {
+ /**
+ * {@return {@link #x}}
+ */
+ public T first() {
+ return x;
+ }
+
+ /**
+ * {@return {@link #y}}
+ */
+ public T second() {
+ return y;
+ }
+
+ /**
+ * {@return {@link #x}}
+ */
+ public T left() {
+ return x;
+ }
+
+ /**
+ * {@return {@link #y}}
+ */
+ public T right() {
+ return y;
+ }
+
+ /**
+ * {@return {@link #x}}
+ */
+ public T key() {
+ return x;
+ }
+
+ /**
+ * {@return {@link #y}}
+ */
+ public T value() {
+ return y;
+ }
+
+ /**
+ * A pair of integers.
+ *
+ * @param x the first value.
+ * @param y the second value.
+ * @author squid233
+ * @since 0.1.0
+ */
+ public record OfInt(int x, int y) {
+ }
+
+ /**
+ * A pair of longs.
+ *
+ * @param x the first value.
+ * @param y the second value.
+ * @author squid233
+ * @since 0.1.0
+ */
+ public record OfLong(long x, long y) {
+ }
+
+ /**
+ * A pair of floats.
+ *
+ * @param x the first value.
+ * @param y the second value.
+ * @author squid233
+ * @since 0.1.0
+ */
+ public record OfFloat(float x, float y) {
+ }
+
+ /**
+ * A pair of doubles.
+ *
+ * @param x the first value.
+ * @param y the second value.
+ * @author squid233
+ * @since 0.1.0
+ */
+ public record OfDouble(double x, double y) {
+ }
+}
From 5259f8e85fccce449aedf20b60bb5c156a290965 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Mon, 31 Jul 2023 23:00:49 +0800
Subject: [PATCH 05/11] [OpenAL] Move directory
---
modules/{overrungl/openal => overrungl.openal}/build.gradle.kts | 0
.../src/main/java/overrungl/openal/AL.java | 0
.../src/main/java/overrungl/openal/ALC.java | 0
.../src/main/java/overrungl/openal/Handles.java | 0
4 files changed, 0 insertions(+), 0 deletions(-)
rename modules/{overrungl/openal => overrungl.openal}/build.gradle.kts (100%)
rename modules/{overrungl/openal => overrungl.openal}/src/main/java/overrungl/openal/AL.java (100%)
rename modules/{overrungl/openal => overrungl.openal}/src/main/java/overrungl/openal/ALC.java (100%)
rename modules/{overrungl/openal => overrungl.openal}/src/main/java/overrungl/openal/Handles.java (100%)
diff --git a/modules/overrungl/openal/build.gradle.kts b/modules/overrungl.openal/build.gradle.kts
similarity index 100%
rename from modules/overrungl/openal/build.gradle.kts
rename to modules/overrungl.openal/build.gradle.kts
diff --git a/modules/overrungl/openal/src/main/java/overrungl/openal/AL.java b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
similarity index 100%
rename from modules/overrungl/openal/src/main/java/overrungl/openal/AL.java
rename to modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
diff --git a/modules/overrungl/openal/src/main/java/overrungl/openal/ALC.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
similarity index 100%
rename from modules/overrungl/openal/src/main/java/overrungl/openal/ALC.java
rename to modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
diff --git a/modules/overrungl/openal/src/main/java/overrungl/openal/Handles.java b/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
similarity index 100%
rename from modules/overrungl/openal/src/main/java/overrungl/openal/Handles.java
rename to modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
From 24203732620da427fe12bc312e263d0b22bcf856 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Mon, 31 Jul 2023 23:08:50 +0800
Subject: [PATCH 06/11] [OpenAL] Fix import
---
.../src/main/java/overrungl/openal/AL.java | 151 +++++++++---------
.../src/main/java/overrungl/openal/ALC.java | 46 +++---
.../main/java/overrungl/openal/Handles.java | 5 +-
3 files changed, 103 insertions(+), 99 deletions(-)
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
index 145dafe5..97cb6b46 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
@@ -16,7 +16,7 @@
package overrungl.openal;
-import overrungl.RuntimeHelper;
+import overrungl.internal.RuntimeHelper;
import overrungl.util.MemoryStack;
import overrungl.util.value.Triplet;
@@ -24,6 +24,7 @@
import java.lang.foreign.SegmentAllocator;
import static java.lang.foreign.ValueLayout.*;
+import static overrungl.openal.Handles.*;
/**
* The OpenAL binding.
@@ -33,7 +34,7 @@
*/
public final class AL {
static {
- Handles.create();
+ create();
}
/**
@@ -426,7 +427,7 @@ public final class AL {
public static void enable(int capability) {
try {
- Handles.alEnable.invokeExact(capability);
+ alEnable.invokeExact(capability);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -434,7 +435,7 @@ public static void enable(int capability) {
public static void disable(int capability) {
try {
- Handles.alDisable.invokeExact(capability);
+ alDisable.invokeExact(capability);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -442,7 +443,7 @@ public static void disable(int capability) {
public static boolean isEnabled(int capability) {
try {
- return (boolean) Handles.alIsEnabled.invokeExact(capability);
+ return (boolean) alIsEnabled.invokeExact(capability);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -450,7 +451,7 @@ public static boolean isEnabled(int capability) {
public static void dopplerFactor(float value) {
try {
- Handles.alDopplerFactor.invokeExact(value);
+ alDopplerFactor.invokeExact(value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -458,7 +459,7 @@ public static void dopplerFactor(float value) {
public static void dopplerVelocity(float value) {
try {
- Handles.alDopplerVelocity.invokeExact(value);
+ alDopplerVelocity.invokeExact(value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -466,7 +467,7 @@ public static void dopplerVelocity(float value) {
public static void speedOfSound(float value) {
try {
- Handles.alSpeedOfSound.invokeExact(value);
+ alSpeedOfSound.invokeExact(value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -474,7 +475,7 @@ public static void speedOfSound(float value) {
public static void distanceModel(int distanceModel) {
try {
- Handles.alDistanceModel.invokeExact(distanceModel);
+ alDistanceModel.invokeExact(distanceModel);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -482,7 +483,7 @@ public static void distanceModel(int distanceModel) {
public static MemorySegment ngetString(int param) {
try {
- return (MemorySegment) Handles.alGetString.invokeExact(param);
+ return (MemorySegment) alGetString.invokeExact(param);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -494,7 +495,7 @@ public static String getString(int param) {
public static void ngetBooleanv(int param, MemorySegment values) {
try {
- Handles.alGetBooleanv.invokeExact(param, values);
+ alGetBooleanv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -508,7 +509,7 @@ public static void getBooleanv(SegmentAllocator allocator, int param, boolean[]
public static void ngetIntegerv(int param, MemorySegment values) {
try {
- Handles.alGetIntegerv.invokeExact(param, values);
+ alGetIntegerv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -522,7 +523,7 @@ public static void getIntegerv(SegmentAllocator allocator, int param, int[] valu
public static void ngetFloatv(int param, MemorySegment values) {
try {
- Handles.alGetFloatv.invokeExact(param, values);
+ alGetFloatv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -536,7 +537,7 @@ public static void getFloatv(SegmentAllocator allocator, int param, float[] valu
public static void ngetDoublev(int param, MemorySegment values) {
try {
- Handles.alGetDoublev.invokeExact(param, values);
+ alGetDoublev.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -550,7 +551,7 @@ public static void getDoublev(SegmentAllocator allocator, int param, double[] va
public static boolean getBoolean(int param) {
try {
- return (boolean) Handles.alGetBoolean.invokeExact(param);
+ return (boolean) alGetBoolean.invokeExact(param);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -558,7 +559,7 @@ public static boolean getBoolean(int param) {
public static int getInteger(int param) {
try {
- return (int) Handles.alGetInteger.invokeExact(param);
+ return (int) alGetInteger.invokeExact(param);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -566,7 +567,7 @@ public static int getInteger(int param) {
public static float getFloat(int param) {
try {
- return (float) Handles.alGetFloat.invokeExact(param);
+ return (float) alGetFloat.invokeExact(param);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -574,7 +575,7 @@ public static float getFloat(int param) {
public static double getDouble(int param) {
try {
- return (double) Handles.alGetDouble.invokeExact(param);
+ return (double) alGetDouble.invokeExact(param);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -588,7 +589,7 @@ public static double getDouble(int param) {
*/
public static int getError() {
try {
- return (int) Handles.alGetError.invokeExact();
+ return (int) alGetError.invokeExact();
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -602,7 +603,7 @@ public static int getError() {
*/
public static boolean nisExtensionPresent(MemorySegment extName) {
try {
- return (boolean) Handles.alIsExtensionPresent.invokeExact(extName);
+ return (boolean) alIsExtensionPresent.invokeExact(extName);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -628,7 +629,7 @@ public static boolean isExtensionPresent(SegmentAllocator allocator, String extN
*/
public static MemorySegment ngetProcAddress(MemorySegment fname) {
try {
- return (MemorySegment) Handles.alGetProcAddress.invokeExact(fname);
+ return (MemorySegment) alGetProcAddress.invokeExact(fname);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -654,7 +655,7 @@ public static MemorySegment getProcAddress(SegmentAllocator allocator, String fn
*/
public static int ngetEnumValue(MemorySegment ename) {
try {
- return (int) Handles.alGetEnumValue.invokeExact(ename);
+ return (int) alGetEnumValue.invokeExact(ename);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -673,7 +674,7 @@ public static int getEnumValue(SegmentAllocator allocator, String ename) {
public static void listenerf(int param, float value) {
try {
- Handles.alListenerf.invokeExact(param, value);
+ alListenerf.invokeExact(param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -681,7 +682,7 @@ public static void listenerf(int param, float value) {
public static void listener3f(int param, float value1, float value2, float value3) {
try {
- Handles.alListener3f.invokeExact(param, value1, value2, value3);
+ alListener3f.invokeExact(param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -689,7 +690,7 @@ public static void listener3f(int param, float value1, float value2, float value
public static void nlistenerfv(int param, MemorySegment values) {
try {
- Handles.alListenerfv.invokeExact(param, values);
+ alListenerfv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -701,7 +702,7 @@ public static void listenerfv(SegmentAllocator allocator, int param, float[] val
public static void listeneri(int param, int value) {
try {
- Handles.alListeneri.invokeExact(param, value);
+ alListeneri.invokeExact(param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -709,7 +710,7 @@ public static void listeneri(int param, int value) {
public static void listener3i(int param, int value1, int value2, int value3) {
try {
- Handles.alListener3i.invokeExact(param, value1, value2, value3);
+ alListener3i.invokeExact(param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -717,7 +718,7 @@ public static void listener3i(int param, int value1, int value2, int value3) {
public static void nlisteneriv(int param, MemorySegment values) {
try {
- Handles.alListeneriv.invokeExact(param, values);
+ alListeneriv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -729,7 +730,7 @@ public static void listeneriv(SegmentAllocator allocator, int param, int[] value
public static void ngetListenerf(int param, MemorySegment value) {
try {
- Handles.alGetListenerf.invokeExact(param, value);
+ alGetListenerf.invokeExact(param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -749,7 +750,7 @@ public static float getListenerf(int param) {
public static void ngetListener3f(int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
try {
- Handles.alGetListener3f.invokeExact(param, value1, value2, value3);
+ alGetListener3f.invokeExact(param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -771,7 +772,7 @@ public static Triplet.OfFloat getListener3f(int param) {
public static void ngetListenerfv(int param, MemorySegment values) {
try {
- Handles.alGetListenerfv.invokeExact(param, values);
+ alGetListenerfv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -785,7 +786,7 @@ public static void getListenerfv(SegmentAllocator allocator, int param, float[]
public static void ngetListeneri(int param, MemorySegment value) {
try {
- Handles.alGetListeneri.invokeExact(param, value);
+ alGetListeneri.invokeExact(param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -805,7 +806,7 @@ public static float getListeneri(int param) {
public static void ngetListener3i(int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
try {
- Handles.alGetListener3i.invokeExact(param, value1, value2, value3);
+ alGetListener3i.invokeExact(param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -827,7 +828,7 @@ public static Triplet.OfInt getListener3i(int param) {
public static void ngetListeneriv(int param, MemorySegment values) {
try {
- Handles.alGetListeneriv.invokeExact(param, values);
+ alGetListeneriv.invokeExact(param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -847,7 +848,7 @@ public static void getListeneriv(SegmentAllocator allocator, int param, int[] va
*/
public static void ngenSources(int n, MemorySegment sources) {
try {
- Handles.alGenSources.invokeExact(n, sources);
+ alGenSources.invokeExact(n, sources);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -892,7 +893,7 @@ public static int genSource() {
*/
public static void ndeleteSources(int n, MemorySegment sources) {
try {
- Handles.alDeleteSources.invokeExact(n, sources);
+ alDeleteSources.invokeExact(n, sources);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -933,7 +934,7 @@ public static void deleteSource(int source) {
*/
public static boolean isSource(int source) {
try {
- return (boolean) Handles.alIsSource.invokeExact(source);
+ return (boolean) alIsSource.invokeExact(source);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -941,7 +942,7 @@ public static boolean isSource(int source) {
public static void sourcef(int source, int param, float value) {
try {
- Handles.alSourcef.invokeExact(source, param, value);
+ alSourcef.invokeExact(source, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -949,7 +950,7 @@ public static void sourcef(int source, int param, float value) {
public static void source3f(int source, int param, float value1, float value2, float value3) {
try {
- Handles.alSource3f.invokeExact(source, param, value1, value2, value3);
+ alSource3f.invokeExact(source, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -957,7 +958,7 @@ public static void source3f(int source, int param, float value1, float value2, f
public static void nsourcefv(int source, int param, MemorySegment values) {
try {
- Handles.alSourcefv.invokeExact(source, param, values);
+ alSourcefv.invokeExact(source, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -969,7 +970,7 @@ public static void sourcefv(SegmentAllocator allocator, int source, int param, f
public static void sourcei(int source, int param, int value) {
try {
- Handles.alSourcei.invokeExact(source, param, value);
+ alSourcei.invokeExact(source, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -977,7 +978,7 @@ public static void sourcei(int source, int param, int value) {
public static void source3i(int source, int param, int value1, int value2, int value3) {
try {
- Handles.alSource3i.invokeExact(source, param, value1, value2, value3);
+ alSource3i.invokeExact(source, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -985,7 +986,7 @@ public static void source3i(int source, int param, int value1, int value2, int v
public static void nsourceiv(int source, int param, MemorySegment values) {
try {
- Handles.alSourceiv.invokeExact(source, param, values);
+ alSourceiv.invokeExact(source, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -997,7 +998,7 @@ public static void sourceiv(SegmentAllocator allocator, int source, int param, i
public static void ngetSourcef(int source, int param, MemorySegment value) {
try {
- Handles.alGetSourcef.invokeExact(source, param, value);
+ alGetSourcef.invokeExact(source, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1017,7 +1018,7 @@ public static float getSourcef(int source, int param) {
public static void ngetSource3f(int source, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
try {
- Handles.alGetSource3f.invokeExact(source, param, value1, value2, value3);
+ alGetSource3f.invokeExact(source, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1039,7 +1040,7 @@ public static Triplet.OfFloat getSource3f(int source, int param) {
public static void ngetSourcefv(int source, int param, MemorySegment values) {
try {
- Handles.alGetSourcefv.invokeExact(source, param, values);
+ alGetSourcefv.invokeExact(source, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1053,7 +1054,7 @@ public static void getSourcefv(SegmentAllocator allocator, int source, int param
public static void ngetSourcei(int source, int param, MemorySegment value) {
try {
- Handles.alGetSourcei.invokeExact(source, param, value);
+ alGetSourcei.invokeExact(source, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1073,7 +1074,7 @@ public static float getSourcei(int source, int param) {
public static void ngetSource3i(int source, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
try {
- Handles.alGetSource3i.invokeExact(source, param, value1, value2, value3);
+ alGetSource3i.invokeExact(source, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1095,7 +1096,7 @@ public static Triplet.OfInt getSource3i(int source, int param) {
public static void ngetSourceiv(int source, int param, MemorySegment values) {
try {
- Handles.alGetSourceiv.invokeExact(source, param, values);
+ alGetSourceiv.invokeExact(source, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1114,7 +1115,7 @@ public static void getSourceiv(SegmentAllocator allocator, int source, int param
*/
public static void sourcePlay(int source) {
try {
- Handles.alSourcePlay.invokeExact(source);
+ alSourcePlay.invokeExact(source);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1127,7 +1128,7 @@ public static void sourcePlay(int source) {
*/
public static void sourceStop(int source) {
try {
- Handles.alSourceStop.invokeExact(source);
+ alSourceStop.invokeExact(source);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1140,7 +1141,7 @@ public static void sourceStop(int source) {
*/
public static void sourceRewind(int source) {
try {
- Handles.alSourceRewind.invokeExact(source);
+ alSourceRewind.invokeExact(source);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1153,7 +1154,7 @@ public static void sourceRewind(int source) {
*/
public static void sourcePause(int source) {
try {
- Handles.alSourcePause.invokeExact(source);
+ alSourcePause.invokeExact(source);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1167,7 +1168,7 @@ public static void sourcePause(int source) {
*/
public static void nsourcePlayv(int n, MemorySegment sources) {
try {
- Handles.alSourcePlayv.invokeExact(n, sources);
+ alSourcePlayv.invokeExact(n, sources);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1194,7 +1195,7 @@ public static void sourcePlayv(SegmentAllocator allocator, int[] sources) {
*/
public static void nsourceStopv(int n, MemorySegment sources) {
try {
- Handles.alSourceStopv.invokeExact(n, sources);
+ alSourceStopv.invokeExact(n, sources);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1221,7 +1222,7 @@ public static void sourceStopv(SegmentAllocator allocator, int[] sources) {
*/
public static void nsourceRewindv(int n, MemorySegment sources) {
try {
- Handles.alSourceRewindv.invokeExact(n, sources);
+ alSourceRewindv.invokeExact(n, sources);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1248,7 +1249,7 @@ public static void sourceRewindv(SegmentAllocator allocator, int[] sources) {
*/
public static void nsourcePausev(int n, MemorySegment sources) {
try {
- Handles.alSourcePausev.invokeExact(n, sources);
+ alSourcePausev.invokeExact(n, sources);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1276,7 +1277,7 @@ public static void sourcePausev(SegmentAllocator allocator, int[] sources) {
*/
public static void nsourceQueueBuffers(int source, int nb, MemorySegment buffers) {
try {
- Handles.alSourceQueueBuffers.invokeExact(source, nb, buffers);
+ alSourceQueueBuffers.invokeExact(source, nb, buffers);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1302,7 +1303,7 @@ public static void sourceQueueBuffers(SegmentAllocator allocator, int source, in
*/
public static void nsourceUnqueueBuffers(int source, int nb, MemorySegment buffers) {
try {
- Handles.alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
+ alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1329,7 +1330,7 @@ public static void sourceUnqueueBuffers(SegmentAllocator allocator, int source,
*/
public static void ngenBuffers(int n, MemorySegment buffers) {
try {
- Handles.alGenBuffers.invokeExact(n, buffers);
+ alGenBuffers.invokeExact(n, buffers);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1374,7 +1375,7 @@ public static int genBuffer() {
*/
public static void ndeleteBuffers(int n, MemorySegment buffers) {
try {
- Handles.alDeleteBuffers.invokeExact(n, buffers);
+ alDeleteBuffers.invokeExact(n, buffers);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1415,7 +1416,7 @@ public static void deleteBuffer(int buffer) {
*/
public static boolean isBuffer(int buffer) {
try {
- return (boolean) Handles.alIsBuffer.invokeExact(buffer);
+ return (boolean) alIsBuffer.invokeExact(buffer);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1433,7 +1434,7 @@ public static boolean isBuffer(int buffer) {
*/
public static void bufferData(int buffer, int format, MemorySegment data, int size, int sampleRate) {
try {
- Handles.alBufferData.invokeExact(buffer, format, data, size, sampleRate);
+ alBufferData.invokeExact(buffer, format, data, size, sampleRate);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1441,7 +1442,7 @@ public static void bufferData(int buffer, int format, MemorySegment data, int si
public static void bufferf(int buffer, int param, float value) {
try {
- Handles.alBufferf.invokeExact(buffer, param, value);
+ alBufferf.invokeExact(buffer, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1449,7 +1450,7 @@ public static void bufferf(int buffer, int param, float value) {
public static void buffer3f(int buffer, int param, float value1, float value2, float value3) {
try {
- Handles.alBuffer3f.invokeExact(buffer, param, value1, value2, value3);
+ alBuffer3f.invokeExact(buffer, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1457,7 +1458,7 @@ public static void buffer3f(int buffer, int param, float value1, float value2, f
public static void nbufferfv(int buffer, int param, MemorySegment values) {
try {
- Handles.alBufferfv.invokeExact(buffer, param, values);
+ alBufferfv.invokeExact(buffer, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1469,7 +1470,7 @@ public static void bufferfv(SegmentAllocator allocator, int buffer, int param, f
public static void bufferi(int buffer, int param, int value) {
try {
- Handles.alBufferi.invokeExact(buffer, param, value);
+ alBufferi.invokeExact(buffer, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1477,7 +1478,7 @@ public static void bufferi(int buffer, int param, int value) {
public static void buffer3i(int buffer, int param, int value1, int value2, int value3) {
try {
- Handles.alBuffer3i.invokeExact(buffer, param, value1, value2, value3);
+ alBuffer3i.invokeExact(buffer, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1485,7 +1486,7 @@ public static void buffer3i(int buffer, int param, int value1, int value2, int v
public static void nbufferiv(int buffer, int param, MemorySegment values) {
try {
- Handles.alBufferiv.invokeExact(buffer, param, values);
+ alBufferiv.invokeExact(buffer, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1497,7 +1498,7 @@ public static void bufferiv(SegmentAllocator allocator, int buffer, int param, i
public static void ngetBufferf(int buffer, int param, MemorySegment value) {
try {
- Handles.alGetBufferf.invokeExact(buffer, param, value);
+ alGetBufferf.invokeExact(buffer, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1517,7 +1518,7 @@ public static float getBufferf(int buffer, int param) {
public static void ngetBuffer3f(int buffer, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
try {
- Handles.alGetBuffer3f.invokeExact(buffer, param, value1, value2, value3);
+ alGetBuffer3f.invokeExact(buffer, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1539,7 +1540,7 @@ public static Triplet.OfFloat getBuffer3f(int buffer, int param) {
public static void ngetBufferfv(int buffer, int param, MemorySegment values) {
try {
- Handles.alGetBufferfv.invokeExact(buffer, param, values);
+ alGetBufferfv.invokeExact(buffer, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1553,7 +1554,7 @@ public static void getBufferfv(SegmentAllocator allocator, int buffer, int param
public static void ngetBufferi(int buffer, int param, MemorySegment value) {
try {
- Handles.alGetBufferi.invokeExact(buffer, param, value);
+ alGetBufferi.invokeExact(buffer, param, value);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1573,7 +1574,7 @@ public static float getBufferi(int buffer, int param) {
public static void ngetBuffer3i(int buffer, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
try {
- Handles.alGetBuffer3i.invokeExact(buffer, param, value1, value2, value3);
+ alGetBuffer3i.invokeExact(buffer, param, value1, value2, value3);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -1595,7 +1596,7 @@ public static Triplet.OfInt getBuffer3i(int buffer, int param) {
public static void ngetBufferiv(int buffer, int param, MemorySegment values) {
try {
- Handles.alGetBufferiv.invokeExact(buffer, param, values);
+ alGetBufferiv.invokeExact(buffer, param, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
index 8cd1ff1c..5fa23bed 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
@@ -16,12 +16,14 @@
package overrungl.openal;
-import overrungl.RuntimeHelper;
+import overrungl.internal.RuntimeHelper;
import java.lang.foreign.MemorySegment;
import java.lang.foreign.SegmentAllocator;
import java.lang.foreign.ValueLayout;
+import static overrungl.openal.Handles.*;
+
/**
* The OpenAL context binding.
*
@@ -30,7 +32,7 @@
*/
public final class ALC {
static {
- Handles.create();
+ create();
}
/**
@@ -154,7 +156,7 @@ public final class ALC {
public static MemorySegment ncreateContext(MemorySegment device, MemorySegment attrlist) {
try {
- return (MemorySegment) Handles.alcCreateContext.invokeExact(device, attrlist);
+ return (MemorySegment) alcCreateContext.invokeExact(device, attrlist);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -166,7 +168,7 @@ public static MemorySegment createContext(SegmentAllocator allocator, MemorySegm
public static boolean makeContextCurrent(MemorySegment context) {
try {
- return (boolean) Handles.alcMakeContextCurrent.invokeExact(context);
+ return (boolean) alcMakeContextCurrent.invokeExact(context);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -174,7 +176,7 @@ public static boolean makeContextCurrent(MemorySegment context) {
public static void processContext(MemorySegment context) {
try {
- Handles.alcProcessContext.invokeExact(context);
+ alcProcessContext.invokeExact(context);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -182,7 +184,7 @@ public static void processContext(MemorySegment context) {
public static void suspendContext(MemorySegment context) {
try {
- Handles.alcSuspendContext.invokeExact(context);
+ alcSuspendContext.invokeExact(context);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -190,7 +192,7 @@ public static void suspendContext(MemorySegment context) {
public static void destroyContext(MemorySegment context) {
try {
- Handles.alcDestroyContext.invokeExact(context);
+ alcDestroyContext.invokeExact(context);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -198,7 +200,7 @@ public static void destroyContext(MemorySegment context) {
public static MemorySegment getCurrentContext() {
try {
- return (MemorySegment) Handles.alcGetCurrentContext.invokeExact();
+ return (MemorySegment) alcGetCurrentContext.invokeExact();
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -206,7 +208,7 @@ public static MemorySegment getCurrentContext() {
public static MemorySegment getContextsDevice(MemorySegment context) {
try {
- return (MemorySegment) Handles.alcGetContextsDevice.invokeExact(context);
+ return (MemorySegment) alcGetContextsDevice.invokeExact(context);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -214,7 +216,7 @@ public static MemorySegment getContextsDevice(MemorySegment context) {
public static MemorySegment nopenDevice(MemorySegment deviceName) {
try {
- return (MemorySegment) Handles.alcOpenDevice.invokeExact(deviceName);
+ return (MemorySegment) alcOpenDevice.invokeExact(deviceName);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -226,7 +228,7 @@ public static MemorySegment openDevice(SegmentAllocator allocator, String device
public static boolean closeDevice(MemorySegment device) {
try {
- return (boolean) Handles.alcCloseDevice.invokeExact(device);
+ return (boolean) alcCloseDevice.invokeExact(device);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -234,7 +236,7 @@ public static boolean closeDevice(MemorySegment device) {
public static int getError(MemorySegment device) {
try {
- return (int) Handles.alcGetError.invokeExact(device);
+ return (int) alcGetError.invokeExact(device);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -242,7 +244,7 @@ public static int getError(MemorySegment device) {
public static boolean nisExtensionPresent(MemorySegment device, MemorySegment extName) {
try {
- return (boolean) Handles.alcIsExtensionPresent.invokeExact(device, extName);
+ return (boolean) alcIsExtensionPresent.invokeExact(device, extName);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -254,7 +256,7 @@ public static boolean isExtensionPresent(SegmentAllocator allocator, MemorySegme
public static MemorySegment ngetProcAddress(MemorySegment device, MemorySegment funcName) {
try {
- return (MemorySegment) Handles.alcGetProcAddress.invokeExact(device, funcName);
+ return (MemorySegment) alcGetProcAddress.invokeExact(device, funcName);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -266,7 +268,7 @@ public static MemorySegment getProcAddress(SegmentAllocator allocator, MemorySeg
public static int ngetEnumValue(MemorySegment device, MemorySegment enumName) {
try {
- return (int) Handles.alcGetEnumValue.invokeExact(device, enumName);
+ return (int) alcGetEnumValue.invokeExact(device, enumName);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -278,7 +280,7 @@ public static int getEnumValue(SegmentAllocator allocator, MemorySegment device,
public static MemorySegment ngetString(MemorySegment device, int param) {
try {
- return (MemorySegment) Handles.alcGetString.invokeExact(device, param);
+ return (MemorySegment) alcGetString.invokeExact(device, param);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -290,7 +292,7 @@ public static String getString(MemorySegment device, int param) {
public static void ngetIntegerv(MemorySegment device, int param, int size, MemorySegment values) {
try {
- Handles.alcGetIntegerv.invokeExact(device, param, size, values);
+ alcGetIntegerv.invokeExact(device, param, size, values);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -304,7 +306,7 @@ public static void getIntegerv(SegmentAllocator allocator, MemorySegment device,
public static MemorySegment ncaptureOpenDevice(MemorySegment deviceName, int frequency, int format, int bufferSize) {
try {
- return (MemorySegment) Handles.alcCaptureOpenDevice.invokeExact(deviceName, frequency, format, bufferSize);
+ return (MemorySegment) alcCaptureOpenDevice.invokeExact(deviceName, frequency, format, bufferSize);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -316,7 +318,7 @@ public static MemorySegment captureOpenDevice(SegmentAllocator allocator, String
public static boolean captureCloseDevice(MemorySegment device) {
try {
- return (boolean) Handles.alcCaptureCloseDevice.invokeExact(device);
+ return (boolean) alcCaptureCloseDevice.invokeExact(device);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -324,7 +326,7 @@ public static boolean captureCloseDevice(MemorySegment device) {
public static void captureStart(MemorySegment device) {
try {
- Handles.alcCaptureStart.invokeExact(device);
+ alcCaptureStart.invokeExact(device);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -332,7 +334,7 @@ public static void captureStart(MemorySegment device) {
public static void captureStop(MemorySegment device) {
try {
- Handles.alcCaptureStop.invokeExact(device);
+ alcCaptureStop.invokeExact(device);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
@@ -340,7 +342,7 @@ public static void captureStop(MemorySegment device) {
public static void captureSamples(MemorySegment device, MemorySegment buffer, int samples) {
try {
- Handles.alcCaptureSamples.invokeExact(device, buffer, samples);
+ alcCaptureSamples.invokeExact(device, buffer, samples);
} catch (Throwable e) {
throw new AssertionError("should not reach here", e);
}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java b/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
index 8cb13d41..0fbef737 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
@@ -17,7 +17,8 @@
package overrungl.openal;
import overrungl.FunctionDescriptors;
-import overrungl.RuntimeHelper;
+import overrungl.OverrunGL;
+import overrungl.internal.RuntimeHelper;
import java.lang.foreign.FunctionDescriptor;
import java.lang.foreign.SymbolLookup;
@@ -168,7 +169,7 @@ static void create() {
if (initialized) return;
initialized = true;
- lookup = RuntimeHelper.load("openal", "openal", RuntimeHelper.VERSION);
+ lookup = RuntimeHelper.load("openal", "openal", OverrunGL.VERSION);
createAL();
createALC();
}
From 4ee6050fbaa235d71d4188d551bf655040254c82 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Tue, 1 Aug 2023 16:35:43 +0800
Subject: [PATCH 07/11] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index 03d55cfe..33a8bd37 100644
--- a/README.md
+++ b/README.md
@@ -151,7 +151,7 @@ natives
│ │ │ └─ libopenal.so
│ │ └─ x64
│ │ └─ libopenal.so
-│ ├─ os x
+│ ├─ macos
│ │ ├─ arm64
│ │ │ └─ libopenal.dylib
│ │ └─ x64
From d31a11838d639879cb0b09954e861472eba28be5 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Sun, 5 Jan 2025 18:40:46 +0800
Subject: [PATCH 08/11] feat(api): [openal] Update generator
---
buildSrc/src/main/kotlin/natives.kt | 6 +
doc/internal/README.md | 1 +
.../src/main/kotlin/overrungl/MemoryStack.kt | 5 +-
generators/openal/build.gradle.kts | 25 +
.../src/main/kotlin/overrungl/openal/AL.kt | 771 ++++++
.../src/main/kotlin/overrungl/openal/ALC.kt | 243 ++
.../overrungl/openal/OpenALGenerator.kt | 77 +
.../overrungl/opengl/InstanceDowncall.kt | 1 +
.../overrungl/opengl/OpenGLGenerator.kt | 9 -
.../main/kotlin/overrungl/gen/CodeReplacer.kt | 12 +-
.../kotlin/overrungl/gen/StaticDowncall.kt | 2 +-
.../src/main/kotlin/overrungl/gen/Struct.kt | 3 +-
.../src/main/kotlin/overrungl/gen/Upcall.kt | 3 +-
.../java/overrungl/FunctionDescriptors.java | 0
.../src/main/java/overrungl/OverrunGL.java | 6 +-
.../overrungl/OverrunGLConfigurations.java | 6 +-
modules/overrungl.openal/build.gradle.kts | 26 +
.../src/main/java/overrungl/openal/AL.java | 2090 +++++++----------
.../src/main/java/overrungl/openal/ALC.java | 440 ++--
.../java/overrungl/openal/ALInternal.java | 50 +
settings.gradle.kts | 17 +
21 files changed, 2299 insertions(+), 1494 deletions(-)
create mode 100644 generators/openal/build.gradle.kts
create mode 100644 generators/openal/src/main/kotlin/overrungl/openal/AL.kt
create mode 100644 generators/openal/src/main/kotlin/overrungl/openal/ALC.kt
create mode 100644 generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt
delete mode 100644 modules/overrungl.core/src/main/java/overrungl/FunctionDescriptors.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALInternal.java
diff --git a/buildSrc/src/main/kotlin/natives.kt b/buildSrc/src/main/kotlin/natives.kt
index f6501742..2330d886 100644
--- a/buildSrc/src/main/kotlin/natives.kt
+++ b/buildSrc/src/main/kotlin/natives.kt
@@ -45,6 +45,7 @@ enum class NativeBinding(
) {
GLFW("glfw", "glfw", NativePlatform.enumEntries),
NFD("nfd", "nfd", NativePlatform.enumEntries),
+ OPENAL("openal", "openal", NativePlatform.enumEntries),
STB("stb", "stb", NativePlatform.enumEntries),
}
@@ -73,6 +74,11 @@ enum class Artifact(
"A tiny, neat C library that portably invokes native file open and save dialogs.",
":nfd"
),
+ OPENAL(
+ "OverrunGL - OpenAL bindings",
+ "A cross-platform 3D audio API appropriate for use with gaming applications and many other types of audio applications.",
+ ":openal"
+ ),
OPENGL(
"OverrunGL - OpenGL bindings",
"The most widely adopted 2D and 3D graphics API in the industry, bringing thousands of applications to a wide variety of computer platforms.",
diff --git a/doc/internal/README.md b/doc/internal/README.md
index dd32b061..502a9fdb 100644
--- a/doc/internal/README.md
+++ b/doc/internal/README.md
@@ -8,6 +8,7 @@ To publish this library, you need a GPG key and the write permission of Maven Ce
- [glfw](https://github.com/Over-Run/glfw-ci)
- [nfd](https://github.com/Over-Run/nfd-ci)
+- [openal](https://github.com/Over-Run/openal-ci)
- [stb](https://github.com/Over-Run/stb-ci)
### Packing Natives
diff --git a/generators/core/src/main/kotlin/overrungl/MemoryStack.kt b/generators/core/src/main/kotlin/overrungl/MemoryStack.kt
index 68e5f491..7e1e0e2a 100644
--- a/generators/core/src/main/kotlin/overrungl/MemoryStack.kt
+++ b/generators/core/src/main/kotlin/overrungl/MemoryStack.kt
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2024 Overrun Organization
+ * Copyright (c) 2024-2025 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -19,6 +19,7 @@ package overrungl
import overrungl.gen.formatter_off
import overrungl.gen.formatter_on
import overrungl.gen.replaceCode
+import overrungl.gen.writeString
import java.nio.file.Files
import kotlin.io.path.Path
@@ -59,7 +60,7 @@ fun memoryStack() {
sb.appendLine(formatter_on)
- Files.writeString(path, replaceCode(src, sb.toString()))
+ writeString(path, replaceCode(src, sb.toString()))
}
private enum class Type {
diff --git a/generators/openal/build.gradle.kts b/generators/openal/build.gradle.kts
new file mode 100644
index 00000000..0d69bca5
--- /dev/null
+++ b/generators/openal/build.gradle.kts
@@ -0,0 +1,25 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+plugins {
+ id("generator.conventions")
+}
+
+dependencies {
+ implementation(project(":generators"))
+}
+
+registerGenerateTask("overrungl.openal.OpenALGeneratorKt", ":openal")
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/AL.kt b/generators/openal/src/main/kotlin/overrungl/openal/AL.kt
new file mode 100644
index 00000000..4703445e
--- /dev/null
+++ b/generators/openal/src/main/kotlin/overrungl/openal/AL.kt
@@ -0,0 +1,771 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.openal
+
+import overrungl.gen.StaticDowncall
+import overrungl.gen.void
+import overrungl.gen.void_ptr
+
+fun AL() {
+ StaticDowncall(alPackage, "AL", alLookup) {
+ //region fields
+ ALenum("AL_NONE" to "0", "No distance model or no buffer")
+ ALenum("AL_FALSE" to "0", "Boolean False.")
+ ALenum("AL_TRUE" to "1", "Boolean True.")
+
+ ALenum(
+ "AL_SOURCE_RELATIVE" to "0x202",
+ """
+ Relative source.
+ - Type: ALboolean
+ - Range: \[AL_FALSE, AL_TRUE\]
+ - Default: AL_FALSE
+
+ Specifies if the source uses relative coordinates.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_CONE_INNER_ANGLE" to "0x1001",
+ """
+ Inner cone angle, in degrees.
+ - Type: ALint, ALfloat
+ - Range: \[0 - 360\]
+ - Default: 360
+
+ The angle covered by the inner cone, the area within which the source will
+ not be attenuated by direction.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_CONE_OUTER_ANGLE" to "0x1002",
+ """
+ Outer cone angle, in degrees.
+ - Range: \[0 - 360\]
+ - Default: 360
+
+ The angle covered by the outer cone, the area outside of which the source
+ will be fully attenuated by direction.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_PITCH" to "0x1003",
+ """
+ Source pitch.
+ - Type: ALfloat
+ - Range: \[0.5 - 2.0\]
+ - Default: 1.0
+
+ A multiplier for the sample rate of the source's buffer.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_POSITION" to "0x1004",
+ """
+ Source or listener position.
+ - Type: ALfloat\[3\], ALint\[3\]
+ - Default: {0, 0, 0}
+
+ The source or listener location in three dimensional space.
+
+ OpenAL uses a right handed coordinate system, like OpenGL, where with a
+ default view, X points right (thumb), Y points up (index finger), and Z
+ points towards the viewer/camera (middle finger).
+
+ To change from or to a left handed coordinate system, negate the Z
+ component.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_DIRECTION" to "0x1005",
+ """
+ Source direction.
+ - Type: ALfloat\[3\], ALint\[3\]
+ - Default: {0, 0, 0}
+
+ Specifies the current direction in local space. A zero-length vector
+ specifies an omni-directional source (cone is ignored).
+
+ To change from or to a left handed coordinate system, negate the Z
+ component.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_VELOCITY" to "0x1006",
+ """
+ Source or listener velocity.
+ - Type: ALfloat\[3\], ALint\[3]\
+ - Default: {0, 0, 0}
+
+ Specifies the current velocity, relative to the position.
+
+ To change from or to a left handed coordinate system, negate the Z
+ component.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_LOOPING" to "0x1007",
+ """
+ Source looping.
+ - Type: ALboolean
+ - Range: \[AL_FALSE, AL_TRUE\]
+ - Default: AL_FALSE
+
+ Specifies whether source playback loops.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_BUFFER" to "0x1009",
+ """
+ Source buffer.
+ - Type: ALuint
+ - Range: any valid Buffer ID
+ - Default: AL_NONE
+
+ Specifies the buffer to provide sound samples for a source.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_GAIN" to "0x100A",
+ """
+ Source or listener gain.
+ - Type: ALfloat
+ - Range: \[0.0 - \]
+
+ For sources, an initial linear gain value (before attenuation is applied).
+ For the listener, an output linear gain adjustment.
+
+ A value of 1.0 means unattenuated. Each division by 2 equals an attenuation
+ of about -6dB. Each multiplication by 2 equals an amplification of about
+ +6dB.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_MIN_GAIN" to "0x100D",
+ """
+ Minimum source gain.
+ - Type: ALfloat
+ - Range: \[0.0 - 1.0\]
+
+ The minimum gain allowed for a source, after distance and cone attenuation
+ are applied (if applicable).
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_MAX_GAIN" to "0x100E",
+ """
+ Maximum source gain.
+ - Type: ALfloat
+ - Range: \[0.0 - 1.0\]
+
+ The maximum gain allowed for a source, after distance and cone attenuation
+ are applied (if applicable).
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_ORIENTATION" to "0x100F",
+ """
+ Listener orientation.
+ - Type: ALfloat\[6\]
+ - Default: {0.0, 0.0, -1.0, 0.0, 1.0, 0.0}
+
+ Effectively two three dimensional vectors. The first vector is the front (or
+ "at") and the second is the top (or "up"). Both vectors are relative to the
+ listener position.
+
+ To change from or to a left handed coordinate system, negate the Z
+ component of both vectors.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_SOURCE_STATE" to "0x1010",
+ """
+ Source state (query only).
+ - Type: ALenum
+ - Range: \[AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED\]
+ """.trimIndent()
+ )
+
+ ALenum("Source state values.") {
+ "AL_INITIAL"("0x1011")
+ "AL_PLAYING"("0x1012")
+ "AL_PAUSED"("0x1013")
+ "AL_STOPPED"("0x1014")
+ }
+
+ ALenum(
+ "AL_BUFFERS_QUEUED" to "0x1015",
+ """
+ Source Buffer Queue size (query only).
+ - Type: ALint
+
+ The number of buffers queued using alSourceQueueBuffers, minus the buffers
+ removed with alSourceUnqueueBuffers.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_BUFFERS_PROCESSED" to "0x1016",
+ """
+ Source Buffer Queue processed count (query only).
+ - Type: ALint
+
+ The number of queued buffers that have been fully processed, and can be
+ removed with alSourceUnqueueBuffers.
+
+ Looping sources will never fully process buffers because they will be set to
+ play again for when the source loops.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_REFERENCE_DISTANCE" to "0x1020",
+ """
+ Source reference distance.
+ - Type: ALfloat
+ - Range: \[0.0 - \]
+ - Default: 1.0
+
+ The distance in units that no distance attenuation occurs.
+
+ At 0.0, no distance attenuation occurs with non-linear attenuation models.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_ROLLOFF_FACTOR" to "0x1021",
+ """
+ Source rolloff factor.
+ - Type: ALfloat
+ - Range: \[0.0 - \]
+ - Default: 1.0
+
+ Multiplier to exaggerate or diminish distance attenuation.
+
+ At 0.0, no distance attenuation ever occurs.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_CONE_OUTER_GAIN" to "0x1022",
+ """
+ Outer cone gain.
+ - Type: ALfloat
+ - Range: \[0.0 - 1.0\]
+ - Default: 0.0
+
+ The gain attenuation applied when the listener is outside of the source's
+ outer cone angle.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_MAX_DISTANCE" to "0x1023",
+ """
+ Source maximum distance.
+ - Type: ALfloat
+ - Range: \[0.0 - \]
+ - Default: FLT_MAX
+
+ The distance above which the source is not attenuated any further with a
+ clamped distance model, or where attenuation reaches 0.0 gain for linear
+ distance models with a default rolloff factor.
+ """.trimIndent()
+ )
+
+ ALenum("AL_SEC_OFFSET" to "0x1024", "Source buffer offset, in seconds")
+ ALenum("AL_SAMPLE_OFFSET" to "0x1025", "Source buffer offset, in sample frames")
+ ALenum("AL_BYTE_OFFSET" to "0x1026", "Source buffer offset, in bytes")
+
+ ALenum(
+ "AL_SOURCE_TYPE" to "0x1027",
+ """
+ Source type (query only).
+ - Type: ALenum
+ - Range: \[AL_STATIC, AL_STREAMING, AL_UNDETERMINED\]
+
+ A Source is Static if a Buffer has been attached using AL_BUFFER.
+
+ A Source is Streaming if one or more Buffers have been attached using
+ alSourceQueueBuffers.
+
+ A Source is Undetermined when it has the NULL buffer attached using
+ AL_BUFFER.
+ """.trimIndent()
+ )
+
+ ALenum("Source type values.") {
+ "AL_STATIC"("0x1028")
+ "AL_STREAMING"("0x1029")
+ "AL_UNDETERMINED"("0x1030")
+ }
+
+ ALenum("AL_FORMAT_MONO8" to "0x1100", "Unsigned 8-bit mono buffer format.")
+ ALenum("AL_FORMAT_MONO16" to "0x1101", "Signed 16-bit mono buffer format.")
+ ALenum("AL_FORMAT_STEREO8" to "0x1102", "Unsigned 8-bit stereo buffer format.")
+ ALenum("AL_FORMAT_STEREO16" to "0x1103", "Signed 16-bit stereo buffer format.")
+
+ ALenum("AL_FREQUENCY" to "0x2001", "Buffer frequency/sample rate (query only).")
+ ALenum("AL_BITS" to "0x2002", "Buffer bits per sample (query only).")
+ ALenum("AL_CHANNELS" to "0x2003", "Buffer channel count (query only).")
+ ALenum("AL_SIZE" to "0x2004", "Buffer data size in bytes (query only).")
+
+ ALenum("Buffer state. Not for public use.") {
+ "AL_UNUSED"("0x2010")
+ "AL_PENDING"("0x2011")
+ "AL_PROCESSED"("0x2012")
+ }
+
+ ALenum("AL_NO_ERROR" to "0", "No error.")
+ ALenum("AL_INVALID_NAME" to "0xA001", "Invalid name (ID) passed to an AL call.")
+ ALenum("AL_INVALID_ENUM" to "0xA002", "Invalid enumeration passed to AL call.")
+ ALenum("AL_INVALID_VALUE" to "0xA003", "Invalid value passed to AL call.")
+ ALenum("AL_INVALID_OPERATION" to "0xA004", "Illegal AL call.")
+ ALenum("AL_OUT_OF_MEMORY" to "0xA005", "Not enough memory to execute the AL call.")
+
+ ALenum("AL_VENDOR" to "0xB001", "Context string: Vendor name.")
+ ALenum("AL_VERSION" to "0xB002", "Context string: Version.")
+ ALenum("AL_RENDERER" to "0xB003", "Context string: Renderer name.")
+ ALenum("AL_EXTENSIONS" to "0xB004", "Context string: Space-separated extension list.")
+
+ ALenum(
+ "AL_DOPPLER_FACTOR" to "0xC000",
+ """
+ Doppler scale.
+ - Type: ALfloat
+ - Range: \[0.0 - \]
+ - Default: 1.0
+
+ Scale for source and listener velocities.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_DOPPLER_VELOCITY" to "0xC001",
+ """
+ Doppler velocity (deprecated).
+
+ A multiplier applied to the Speed of Sound.
+ """.trimIndent()
+ )
+ ALenum(
+ "AL_SPEED_OF_SOUND" to "0xC003",
+ """
+ Speed of Sound, in units per second.
+ - Type: ALfloat
+ - Range: \[0.0001 - \]
+ - Default: 343.3
+
+ The speed at which sound waves are assumed to travel, when calculating the
+ doppler effect from source and listener velocities.
+ """.trimIndent()
+ )
+
+ ALenum(
+ "AL_DISTANCE_MODEL" to "0xD000",
+ """
+ Distance attenuation model.
+ - Type: ALenum
+ - Range: \[AL_NONE, AL_INVERSE_DISTANCE, AL_INVERSE_DISTANCE_CLAMPED,
+ AL_LINEAR_DISTANCE, AL_LINEAR_DISTANCE_CLAMPED,
+ AL_EXPONENT_DISTANCE, AL_EXPONENT_DISTANCE_CLAMPED\]
+ - Default: AL_INVERSE_DISTANCE_CLAMPED
+
+ The model by which sources attenuate with distance.
+
+ - None - No distance attenuation.
+ - Inverse - Doubling the distance halves the source gain.
+ - Linear - Linear gain scaling between the reference and max distances.
+ - Exponent - Exponential gain dropoff.
+
+ Clamped variations work like the non-clamped counterparts, except the
+ distance calculated is clamped between the reference and max distances.
+ """.trimIndent()
+ )
+
+ ALenum("Distance model values.") {
+ "AL_INVERSE_DISTANCE"("0xD001")
+ "AL_INVERSE_DISTANCE_CLAMPED"("0xD002")
+ "AL_LINEAR_DISTANCE"("0xD003")
+ "AL_LINEAR_DISTANCE_CLAMPED"("0xD004")
+ "AL_EXPONENT_DISTANCE"("0xD005")
+ "AL_EXPONENT_DISTANCE_CLAMPED"("0xD006")
+ }
+ //endregion
+
+ //region functions
+ "alEnable"(void, ALenum("capability"), entrypoint = "alEnable")
+ "alDisable"(void, ALenum("capability"), entrypoint = "alDisable")
+ "alIsEnabled"(ALboolean, ALenum("capability"), entrypoint = "alIsEnabled")
+
+ "alDopplerFactor"(void, ALfloat("value"), entrypoint = "alDopplerFactor")
+ "alDopplerVelocity"(void, ALfloat("value"), entrypoint = "alDopplerVelocity")
+ "alSpeedOfSound"(void, ALfloat("value"), entrypoint = "alSpeedOfSound")
+ "alDistanceModel"(void, ALenum("distanceModel"), entrypoint = "alDistanceModel")
+
+ +"alGetString_"(const_ALchar_ptr, ALenum("param"), entrypoint = "alGetString").overload(name = "alGetString")
+ "alGetBooleanv"(void, ALenum("param"), ALboolean_ptr("values").ref(), entrypoint = "alGetBooleanv")
+ +"alGetIntegerv"(void, ALenum("param"), ALint_ptr("values").ref(), entrypoint = "alGetIntegerv").overload()
+ +"alGetFloatv"(void, ALenum("param"), ALfloat_ptr("values").ref(), entrypoint = "alGetFloatv").overload()
+ +"alGetDoublev"(void, ALenum("param"), ALdouble_ptr("values").ref(), entrypoint = "alGetDoublev").overload()
+ "alGetBoolean"(ALboolean, ALenum("param"), entrypoint = "alGetBoolean")
+ "alGetInteger"(ALint, ALenum("param"), entrypoint = "alGetInteger")
+ "alGetFloat"(ALfloat, ALenum("param"), entrypoint = "alGetFloat")
+ "alGetDouble"(ALdouble, ALenum("param"), entrypoint = "alGetDouble")
+
+ "alGetError"(
+ ALenum,
+ entrypoint = "alGetError",
+ javadoc = """
+ Obtain the first error generated in the AL context since the last call to
+ this function.
+ """.trimIndent()
+ )
+
+ +"alIsExtensionPresent"(
+ ALboolean,
+ const_ALchar_ptr("extname"),
+ entrypoint = "alIsExtensionPresent",
+ javadoc = "Query for the presence of an extension on the AL context."
+ ).overload()
+
+ +"alGetProcAddress"(
+ void_ptr,
+ const_ALchar_ptr("fname"),
+ entrypoint = "alGetProcAddress",
+ javadoc = """
+ Retrieve the address of a function. The returned function may be context-
+ specific.
+ """.trimIndent()
+ ).overload()
+
+ +"alGetEnumValue"(
+ ALenum,
+ const_ALchar_ptr("ename"),
+ entrypoint = "alGetEnumValue",
+ javadoc = "Retrieve the value of an enum. The returned value may be context-specific."
+ ).overload()
+
+ "alListenerf"(void, ALenum("param"), ALfloat("value"), entrypoint = "alListenerf")
+ "alListener3f"(
+ void,
+ ALenum("param"),
+ ALfloat("value1"),
+ ALfloat("value2"),
+ ALfloat("value3"),
+ entrypoint = "alListener3f"
+ )
+ "alListenerfv"(void, ALenum("param"), const_ALfloat_ptr("values"), entrypoint = "alListenerfv")
+ "alListeneri"(void, ALenum("param"), ALint("value"), entrypoint = "alListeneri")
+ "alListener3i"(
+ void,
+ ALenum("param"),
+ ALint("value1"),
+ ALint("value2"),
+ ALint("value3"),
+ entrypoint = "alListener3i"
+ )
+ "alListeneriv"(void, ALenum("param"), const_ALint_ptr("values"), entrypoint = "alListeneriv")
+
+ +"alGetListenerf"(void, ALenum("param"), ALfloat_ptr("value").ref(), entrypoint = "alGetListenerf").overload()
+ +"alGetListener3f"(
+ void,
+ ALenum("param"),
+ ALfloat_ptr("value1").ref(),
+ ALfloat_ptr("value2").ref(),
+ ALfloat_ptr("value3").ref(),
+ entrypoint = "alGetListener3f"
+ ).overload()
+ +"alGetListenerfv"(
+ void,
+ ALenum("param"),
+ ALfloat_ptr("values").ref(),
+ entrypoint = "alGetListenerfv"
+ ).overload()
+ +"alGetListeneri"(void, ALenum("param"), ALint_ptr("value").ref(), entrypoint = "alGetListeneri").overload()
+ +"alGetListener3i"(
+ void,
+ ALenum("param"),
+ ALint_ptr("value1").ref(),
+ ALint_ptr("value2").ref(),
+ ALint_ptr("value3").ref(),
+ entrypoint = "alGetListener3i"
+ ).overload()
+ +"alGetListeneriv"(void, ALenum("param"), ALint_ptr("values").ref(), entrypoint = "alGetListeneriv").overload()
+
+ "alGenSources"(
+ void,
+ ALsizei("n"),
+ ALuint_ptr("sources").ref(),
+ entrypoint = "alGenSources",
+ javadoc = "Create source objects."
+ )
+ "alDeleteSources"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alDeleteSources",
+ javadoc = "Delete source objects."
+ )
+ "alIsSource"(
+ ALboolean,
+ ALuint("source"),
+ entrypoint = "alIsSource",
+ javadoc = "Verify an ID is for a valid source."
+ )
+
+ "alSourcef"(void, ALuint("source"), ALenum("param"), ALfloat("value"), entrypoint = "alSourcef")
+ "alSource3f"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat("value1"),
+ ALfloat("value2"),
+ ALfloat("value3"),
+ entrypoint = "alSource3f"
+ )
+ "alSourcefv"(void, ALuint("source"), ALenum("param"), const_ALfloat_ptr("values"), entrypoint = "alSourcefv")
+ "alSourcei"(void, ALuint("source"), ALenum("param"), ALint("value"), entrypoint = "alSourcei")
+ "alSource3i"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint("value1"),
+ ALint("value2"),
+ ALint("value3"),
+ entrypoint = "alSource3i"
+ )
+ "alSourceiv"(void, ALuint("source"), ALenum("param"), const_ALint_ptr("values"), entrypoint = "alSourceiv")
+
+ +"alGetSourcef"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat_ptr("value").ref(),
+ entrypoint = "alGetSourcef"
+ ).overload()
+ +"alGetSource3f"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat_ptr("value1").ref(),
+ ALfloat_ptr("value2").ref(),
+ ALfloat_ptr("value3").ref(),
+ entrypoint = "alGetSource3f"
+ ).overload()
+ +"alGetSourcefv"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat_ptr("values").ref(),
+ entrypoint = "alGetSourcefv"
+ ).overload()
+ +"alGetSourcei"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint_ptr("value").ref(),
+ entrypoint = "alGetSourcei"
+ ).overload()
+ +"alGetSource3i"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint_ptr("value1").ref(),
+ ALint_ptr("value2").ref(),
+ ALint_ptr("value3").ref(),
+ entrypoint = "alGetSource3i"
+ ).overload()
+ +"alGetSourceiv"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint_ptr("values").ref(),
+ entrypoint = "alGetSourceiv"
+ ).overload()
+
+ "alSourcePlay"(
+ void,
+ ALuint("source"),
+ entrypoint = "alSourcePlay",
+ javadoc = "Play, restart, or resume a source, setting its state to AL_PLAYING."
+ )
+ "alSourceStop"(
+ void,
+ ALuint("source"),
+ entrypoint = "alSourceStop",
+ javadoc = "Stop a source, setting its state to AL_STOPPED if playing or paused."
+ )
+ "alSourceRewind"(
+ void,
+ ALuint("source"),
+ entrypoint = "alSourceRewind",
+ javadoc = "Rewind a source, setting its state to AL_INITIAL."
+ )
+ "alSourcePause"(
+ void,
+ ALuint("source"),
+ entrypoint = "alSourcePause",
+ javadoc = "Pause a source, setting its state to AL_PAUSED if playing."
+ )
+
+ "alSourcePlayv"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourcePlayv",
+ javadoc = "Play, restart, or resume a list of sources atomically."
+ )
+ "alSourceStopv"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourceStopv",
+ javadoc = "Stop a list of sources atomically."
+ )
+ "alSourceRewindv"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourceRewindv",
+ javadoc = "Rewind a list of sources atomically."
+ )
+ "alSourcePausev"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourcePausev",
+ javadoc = "Pause a list of sources atomically."
+ )
+
+ "alSourceQueueBuffers"(
+ void,
+ ALuint("source"),
+ ALsizei("nb"),
+ const_ALuint_ptr("buffers"),
+ entrypoint = "alSourceQueueBuffers",
+ javadoc = "Queue buffers onto a source"
+ )
+ "alSourceUnqueueBuffers"(
+ void,
+ ALuint("source"),
+ ALsizei("nb"),
+ ALuint_ptr("buffers").ref(),
+ entrypoint = "alSourceUnqueueBuffers",
+ javadoc = "Unqueue processed buffers from a source"
+ )
+
+ "alGenBuffers"(
+ void,
+ ALsizei("n"),
+ ALuint_ptr("buffers").ref(),
+ entrypoint = "alGenBuffers",
+ javadoc = "Create buffer objects"
+ )
+ "alDeleteBuffers"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("buffers"),
+ entrypoint = "alDeleteBuffers",
+ javadoc = "Delete buffer objects"
+ )
+ "alIsBuffer"(
+ ALboolean,
+ ALuint("source"),
+ entrypoint = "alIsBuffer",
+ javadoc = "Verify an ID is a valid buffer (including the NULL buffer)"
+ )
+
+ "alBufferData"(
+ void,
+ ALuint("buffer"),
+ ALenum("format"),
+ const_ALvoid_ptr("data"),
+ ALsizei("size"),
+ ALsizei("samplerate"),
+ entrypoint = "alBufferData",
+ javadoc = """
+ Copies data into the buffer, interpreting it using the specified format and
+ samplerate.
+ """.trimIndent()
+ )
+
+ "alBufferf"(void, ALuint("buffer"), ALenum("param"), ALfloat("value"), entrypoint = "alBufferf")
+ "alBuffer3f"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat("value1"),
+ ALfloat("value2"),
+ ALfloat("value3"),
+ entrypoint = "alBuffer3f"
+ )
+ "alBufferfv"(void, ALuint("buffer"), ALenum("param"), const_ALfloat_ptr("values"), entrypoint = "alBufferfv")
+ "alBufferi"(void, ALuint("buffer"), ALenum("param"), ALint("value"), entrypoint = "alBufferi")
+ "alBuffer3i"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint("value1"),
+ ALint("value2"),
+ ALint("value3"),
+ entrypoint = "alBuffer3i"
+ )
+ "alBufferiv"(void, ALuint("buffer"), ALenum("param"), const_ALint_ptr("values"), entrypoint = "alBufferiv")
+
+ +"alGetBufferf"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat_ptr("value").ref(),
+ entrypoint = "alGetBufferf"
+ ).overload()
+ +"alGetBuffer3f"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat_ptr("value1").ref(),
+ ALfloat_ptr("value2").ref(),
+ ALfloat_ptr("value3").ref(),
+ entrypoint = "alGetBuffer3f"
+ ).overload()
+ +"alGetBufferfv"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat_ptr("values").ref(),
+ entrypoint = "alGetBufferfv"
+ ).overload()
+ +"alGetBufferi"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint_ptr("value").ref(),
+ entrypoint = "alGetBufferi"
+ ).overload()
+ +"alGetBuffer3i"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint_ptr("value1").ref(),
+ ALint_ptr("value2").ref(),
+ ALint_ptr("value3").ref(),
+ entrypoint = "alGetBuffer3i"
+ ).overload()
+ +"alGetBufferiv"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint_ptr("values").ref(),
+ entrypoint = "alGetBufferiv"
+ ).overload()
+ //endregion
+ }
+}
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt b/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt
new file mode 100644
index 00000000..77782676
--- /dev/null
+++ b/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt
@@ -0,0 +1,243 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.openal
+
+import overrungl.gen.StaticDowncall
+import overrungl.gen.void
+
+fun ALC() {
+ StaticDowncall(alPackage, "ALC", alLookup) {
+ //region fields
+ ALCenum("ALC_FALSE" to "0", "Boolean False.")
+ ALCenum("ALC_TRUE" to "1", "Boolean True.")
+
+ ALCenum("ALC_FREQUENCY" to "0x1007", "Context attribute: <int> Hz.")
+ ALCenum("ALC_REFRESH" to "0x1008", "Context attribute: <int> Hz.")
+ ALCenum("ALC_SYNC" to "0x1009", "Context attribute: AL_TRUE or AL_FALSE synchronous context?")
+ ALCenum("ALC_MONO_SOURCES" to "0x1010", "Context attribute: <int> requested Mono (3D) Sources.")
+ ALCenum("ALC_STEREO_SOURCES" to "0x1011", "Context attribute: <int> requested Stereo Sources.")
+
+ ALCenum("ALC_NO_ERROR" to "0", "No error.")
+ ALCenum("ALC_INVALID_DEVICE" to "0xA001", "Invalid device handle.")
+ ALCenum("ALC_INVALID_CONTEXT" to "0xA002", "Invalid context handle.")
+ ALCenum("ALC_INVALID_ENUM" to "0xA003", "Invalid enumeration passed to an ALC call.")
+ ALCenum("ALC_INVALID_VALUE" to "0xA004", "Invalid value passed to an ALC call.")
+ ALCenum("ALC_OUT_OF_MEMORY" to "0xA005", "Out of memory.")
+
+ ALCenum("ALC_MAJOR_VERSION" to "0x1000", "Runtime ALC major version.")
+ ALCenum("ALC_MINOR_VERSION" to "0x1001", "Runtime ALC minor version.")
+
+ ALCenum("ALC_ATTRIBUTES_SIZE" to "0x1002", "Context attribute list size.")
+ ALCenum("ALC_ALL_ATTRIBUTES" to "0x1003", "Context attribute list properties.")
+ ALCenum("ALC_DEFAULT_DEVICE_SPECIFIER" to "0x1004", "String for the default device specifier.")
+ ALCenum(
+ "ALC_DEVICE_SPECIFIER" to "0x1005",
+ """
+ Device specifier string.
+
+ If device handle is NULL, it is instead a null-character separated list of
+ strings of known device specifiers (list ends with an empty string).
+ """.trimIndent()
+ )
+ ALCenum("ALC_EXTENSIONS" to "0x1006", "String for space-separated list of ALC extensions.")
+
+ ALCenum("ALC_EXT_CAPTURE" to "1", "Capture extension")
+ ALCenum(
+ "ALC_CAPTURE_DEVICE_SPECIFIER" to "0x310",
+ """
+ Capture device specifier string.
+
+ If device handle is NULL, it is instead a null-character separated list of
+ strings of known capture device specifiers (list ends with an empty string).
+ """.trimIndent()
+ )
+ ALCenum("ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER" to "0x311", "String for the default capture device specifier.")
+ ALCenum("ALC_CAPTURE_SAMPLES" to "0x312", "Number of sample frames available for capture.")
+
+ ALCenum("ALC_ENUMERATE_ALL_EXT" to "1", "Enumerate All extension")
+ ALCenum("ALC_DEFAULT_ALL_DEVICES_SPECIFIER" to "0x1012", "String for the default extended device specifier.")
+ ALCenum(
+ "ALC_ALL_DEVICES_SPECIFIER" to "0x1013",
+ """
+ Device's extended specifier string.
+
+ If device handle is NULL, it is instead a null-character separated list of
+ strings of known extended device specifiers (list ends with an empty string).
+ """.trimIndent()
+ )
+ //endregion
+
+ //region functions
+ "alcCreateContext"(
+ ALCcontext_ptr,
+ ALCdevice_ptr("device"),
+ const_ALCint_ptr("attrlist"),
+ entrypoint = "alcCreateContext",
+ javadoc = "Create and attach a context to the given device."
+ )
+ "alcMakeContextCurrent"(
+ ALCboolean,
+ ALCcontext_ptr("context"),
+ entrypoint = "alcMakeContextCurrent",
+ javadoc = """
+ Makes the given context the active process-wide context. Passing NULL clears
+ the active context.
+ """.trimIndent()
+ )
+ "alcProcessContext"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alcProcessContext",
+ javadoc = "Resumes processing updates for the given context."
+ )
+ "alcSuspendContext"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alcSuspendContext",
+ javadoc = "Suspends updates for the given context."
+ )
+ "alcDestroyContext"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alcDestroyContext",
+ javadoc = "Remove a context from its device and destroys it."
+ )
+ "alcGetCurrentContext"(
+ ALCcontext_ptr,
+ entrypoint = "alcGetCurrentContext",
+ javadoc = "Returns the currently active context."
+ )
+ "alcGetContextsDevice"(
+ ALCdevice_ptr,
+ ALCcontext_ptr("context"),
+ entrypoint = "alcGetContextsDevice",
+ javadoc = "Returns the device that a particular context is attached to."
+ )
+
+ +"alcOpenDevice"(
+ ALCdevice_ptr,
+ const_ALCchar_ptr("devicename"),
+ entrypoint = "alcOpenDevice",
+ javadoc = "Opens the named playback device."
+ ).overload()
+ "alcCloseDevice"(
+ ALCboolean,
+ ALCdevice_ptr("device"),
+ entrypoint = "alcCloseDevice",
+ javadoc = "Closes the given playback device."
+ )
+
+ "alcGetError"(
+ ALCenum,
+ ALCdevice_ptr("device"),
+ entrypoint = "alcGetError",
+ javadoc = "Obtain the most recent Device error."
+ )
+
+ +"alcIsExtensionPresent"(
+ ALCboolean,
+ ALCdevice_ptr("device"),
+ const_ALCchar_ptr("extname"),
+ entrypoint = "alcIsExtensionPresent",
+ javadoc = """
+ Query for the presence of an extension on the device. Pass a NULL device to
+ query a device-inspecific extension.
+ """.trimIndent()
+ ).overload()
+ +"alcGetProcAddress"(
+ ALCvoid_ptr,
+ ALCdevice_ptr("device"),
+ const_ALCchar_ptr("funcname"),
+ entrypoint = "alcGetProcAddress",
+ javadoc = """
+ Retrieve the address of a function. Given a non-NULL device, the returned
+ function may be device-specific.
+ """.trimIndent()
+ ).overload()
+ +"alcGetEnumValue"(
+ ALCenum,
+ ALCdevice_ptr("device"),
+ const_ALCchar_ptr("enumname"),
+ entrypoint = "alcGetEnumValue",
+ javadoc = """
+ Retrieve the value of an enum. Given a non-NULL device, the returned value
+ may be device-specific.
+ """.trimIndent()
+ ).overload()
+
+ +"alcGetString_"(
+ const_ALCchar_ptr,
+ ALCdevice_ptr("device"),
+ ALCenum("param"),
+ entrypoint = "alcGetString",
+ javadoc = """
+ Returns information about the device, and error strings.
+ """.trimIndent()
+ ).overload(name = "alcGetString")
+ "alcGetIntegerv"(
+ void,
+ ALCdevice_ptr("device"),
+ ALCenum("param"),
+ ALCsizei("size"),
+ ALCint_ptr("values"),
+ entrypoint = "alcGetIntegerv",
+ javadoc = """
+ Returns information about the device and the version of OpenAL.
+ """.trimIndent()
+ )
+
+ +"alcCaptureOpenDevice"(
+ ALCdevice_ptr,
+ const_ALCchar_ptr("devicename"),
+ ALCuint("frequency"),
+ ALCenum("format"),
+ ALCsizei("buffersize"),
+ entrypoint = "alcCaptureOpenDevice",
+ javadoc = """
+ Opens the named capture device with the given frequency, format, and buffer
+ size.
+ """.trimIndent()
+ ).overload()
+ "alcCaptureCloseDevice"(
+ ALCboolean,
+ ALCdevice_ptr("device"),
+ entrypoint = "alcCaptureCloseDevice",
+ javadoc = "Closes the given capture device."
+ )
+ "alcCaptureStart"(
+ void,
+ ALCdevice_ptr("device"),
+ entrypoint = "alcCaptureStart",
+ javadoc = "Starts capturing samples into the device buffer."
+ )
+ "alcCaptureStop"(
+ void,
+ ALCdevice_ptr("device"),
+ entrypoint = "alcCaptureStop",
+ javadoc = "Stops capturing samples. Samples in the device buffer remain available."
+ )
+ "alcCaptureSamples"(
+ void,
+ ALCdevice_ptr("device"),
+ ALCvoid_ptr("buffer"),
+ ALCsizei("samples"),
+ entrypoint = "alcCaptureSamples",
+ javadoc = "Reads samples from the device buffer."
+ )
+ //endregion
+ }
+}
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt b/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt
new file mode 100644
index 00000000..a909fdca
--- /dev/null
+++ b/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt
@@ -0,0 +1,77 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.openal
+
+import overrungl.gen.*
+
+val ALboolean = jboolean c "ALboolean"
+val ALchar = char c "ALchar"
+val ALbyte = char c "ALbyte"
+val ALubyte = uchar c "ALubyte"
+val ALshort = short c "ALshort"
+val ALushort = ushort c "ALushort"
+val ALint = int c "ALint"
+val ALuint = uint c "ALuint"
+val ALsizei = int c "ALsizei"
+val ALenum = int c "ALenum"
+val ALfloat = float c "ALfloat"
+val ALdouble = double c "ALdouble"
+
+val ALboolean_ptr = address c "ALboolean *"
+val ALint_ptr = jint_array c "ALint *"
+val ALuint_ptr = jint_array c "ALuint *"
+val ALfloat_ptr = jfloat_array c "ALfloat *"
+val ALdouble_ptr = jdouble_array c "ALdouble *"
+
+val const_ALvoid_ptr = address c "const ALvoid *"
+val const_ALchar_ptr = string_u8 c "const ALchar*"
+val const_ALint_ptr = address c "const ALint *"
+val const_ALuint_ptr = address c "const ALuint *"
+val const_ALfloat_ptr = address c "const ALfloat *"
+
+
+val ALCdevice_ptr = address c "ALCdevice *"
+val ALCcontext_ptr = address c "ALCcontext *"
+
+val ALCboolean = jboolean c "ALCboolean"
+val ALCchar = char c "ALCchar"
+val ALCbyte = char c "ALCbyte"
+val ALCubyte = uchar c "ALCubyte"
+val ALCshort = short c "ALCshort"
+val ALCushort = ushort c "ALCushort"
+val ALCint = int c "ALCint"
+val ALCuint = uint c "ALCuint"
+val ALCsizei = int c "ALCsizei"
+val ALCenum = int c "ALCenum"
+val ALCfloat = float c "ALCfloat"
+val ALCdouble = double c "ALCdouble"
+
+val ALCvoid_ptr = address c "ALCvoid *"
+val ALCint_ptr = jint_array c "ALCint *"
+
+val const_ALCvoid_ptr = address c "const ALCvoid *"
+val const_ALCchar_ptr = string_u8 c "const ALCchar*"
+val const_ALCint_ptr = address c "const ALCint *"
+
+
+const val alPackage = "overrungl.openal"
+const val alLookup = "ALInternal.lookup()"
+
+fun main() {
+ AL()
+ ALC()
+}
diff --git a/generators/opengl/src/main/kotlin/overrungl/opengl/InstanceDowncall.kt b/generators/opengl/src/main/kotlin/overrungl/opengl/InstanceDowncall.kt
index 5ec96035..b73d69fc 100644
--- a/generators/opengl/src/main/kotlin/overrungl/opengl/InstanceDowncall.kt
+++ b/generators/opengl/src/main/kotlin/overrungl/opengl/InstanceDowncall.kt
@@ -19,6 +19,7 @@ package overrungl.opengl
import com.palantir.javapoet.TypeName
import overrungl.gen.CustomTypeSpec
import overrungl.gen.commentedFileHeader
+import overrungl.gen.writeString
import kotlin.io.path.Path
class InstanceDowncall(
diff --git a/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt b/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt
index 771dd706..c37b35a1 100644
--- a/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt
+++ b/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt
@@ -21,12 +21,9 @@ import org.w3c.dom.Element
import org.w3c.dom.Node
import org.w3c.dom.Text
import overrungl.gen.*
-import java.nio.file.Files
-import java.nio.file.Path
import javax.xml.parsers.DocumentBuilderFactory
import kotlin.io.path.Path
import kotlin.io.path.createDirectories
-import kotlin.io.path.exists
// gl.xml updated: 2025/01/01
@@ -1005,9 +1002,3 @@ data class GLFeature(val number: String, val requires: List) {
}
data class GLExtension(val name: String, val requires: List)
-
-// do not write if contents are equal
-internal fun writeString(path: Path, content: String) {
- if (path.exists() && Files.readString(path) == content) return
- Files.writeString(path, content)
-}
diff --git a/generators/src/main/kotlin/overrungl/gen/CodeReplacer.kt b/generators/src/main/kotlin/overrungl/gen/CodeReplacer.kt
index 24a958d6..cbcb0e1b 100644
--- a/generators/src/main/kotlin/overrungl/gen/CodeReplacer.kt
+++ b/generators/src/main/kotlin/overrungl/gen/CodeReplacer.kt
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2024 Overrun Organization
+ * Copyright (c) 2024-2025 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -16,8 +16,18 @@
package overrungl.gen
+import java.nio.file.Files
+import java.nio.file.Path
+import kotlin.io.path.exists
+
fun replaceCode(originalCode: String, replacingCode: String): String {
check(originalCode.indexOf(GENERATOR_BEGIN) != -1 && originalCode.indexOf(GENERATOR_END) != -1) { "Generator region not found" }
val split = originalCode.split(GENERATOR_BEGIN, GENERATOR_END)
return "${split[0]}$GENERATOR_BEGIN\n$replacingCode $GENERATOR_END${split[2]}"
}
+
+// do not write if contents are equal
+fun writeString(path: Path, content: String) {
+ if (path.exists() && Files.readString(path) == content) return
+ Files.writeString(path, content)
+}
diff --git a/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt b/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt
index ad04672c..44c6dd95 100644
--- a/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt
+++ b/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt
@@ -266,7 +266,7 @@ class StaticDowncall(
sb.appendLine(formatter_on)
- Files.writeString(path, replaceCode(Files.readString(path), sb.toString()))
+ writeString(path, replaceCode(Files.readString(path), sb.toString()))
}
}
diff --git a/generators/src/main/kotlin/overrungl/gen/Struct.kt b/generators/src/main/kotlin/overrungl/gen/Struct.kt
index 99046d98..b1005c9e 100644
--- a/generators/src/main/kotlin/overrungl/gen/Struct.kt
+++ b/generators/src/main/kotlin/overrungl/gen/Struct.kt
@@ -18,7 +18,6 @@ package overrungl.gen
import com.palantir.javapoet.ArrayTypeName
import com.palantir.javapoet.ClassName
-import java.nio.file.Files
import kotlin.io.path.Path
class Struct(
@@ -403,7 +402,7 @@ class Struct(
doLast.invoke(sb)
sb.appendLine("}")
- Files.writeString(Path(packageName.replace('.', '/'), "$name.java"), sb.toString())
+ writeString(Path(packageName.replace('.', '/'), "$name.java"), sb.toString())
}
}
diff --git a/generators/src/main/kotlin/overrungl/gen/Upcall.kt b/generators/src/main/kotlin/overrungl/gen/Upcall.kt
index 51d79fdd..d74a0e9b 100644
--- a/generators/src/main/kotlin/overrungl/gen/Upcall.kt
+++ b/generators/src/main/kotlin/overrungl/gen/Upcall.kt
@@ -18,7 +18,6 @@ package overrungl.gen
import com.palantir.javapoet.ClassName
import com.palantir.javapoet.TypeName
-import java.nio.file.Files
import kotlin.io.path.Path
fun generateUpcallType(packageName: String, name: String): CustomTypeSpec {
@@ -312,7 +311,7 @@ class Upcall(
sb.appendLine("}")
- Files.writeString(path, sb.toString())
+ writeString(path, sb.toString())
}
}
diff --git a/modules/overrungl.core/src/main/java/overrungl/FunctionDescriptors.java b/modules/overrungl.core/src/main/java/overrungl/FunctionDescriptors.java
deleted file mode 100644
index e69de29b..00000000
diff --git a/modules/overrungl.core/src/main/java/overrungl/OverrunGL.java b/modules/overrungl.core/src/main/java/overrungl/OverrunGL.java
index 61a0ba6d..f553135c 100644
--- a/modules/overrungl.core/src/main/java/overrungl/OverrunGL.java
+++ b/modules/overrungl.core/src/main/java/overrungl/OverrunGL.java
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2023-2024 Overrun Organization
+ * Copyright (c) 2023-2025 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -42,6 +42,10 @@ public final class OverrunGL {
* The version of NFD native libraries.
*/
public static final String NFD_VERSION = "1.2.1.0";
+ /**
+ * The version of OpenAL native libraries.
+ */
+ public static final String OPENAL_VERSION = "0.1.0.0";
/**
* The version of STB native libraries.
*/
diff --git a/modules/overrungl.core/src/main/java/overrungl/OverrunGLConfigurations.java b/modules/overrungl.core/src/main/java/overrungl/OverrunGLConfigurations.java
index 5e797321..ec78674a 100644
--- a/modules/overrungl.core/src/main/java/overrungl/OverrunGLConfigurations.java
+++ b/modules/overrungl.core/src/main/java/overrungl/OverrunGLConfigurations.java
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2022-2024 Overrun Organization
+ * Copyright (c) 2022-2025 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -57,6 +57,10 @@ public final class OverrunGLConfigurations {
* The default value is {@code null}.
*/
public static final Entry, SymbolLookup>> NFD_SYMBOL_LOOKUP = new Entry<>(() -> null);
+ /// The symbol lookup of OpenAL. The returned value must not be null.
+ ///
+ /// The default value is `null`.
+ public static final Entry, SymbolLookup>> OPENAL_SYMBOL_LOOKUP = new Entry<>(() -> null);
/**
* The symbol lookup of STB.
* The returned value must not be null.
diff --git a/modules/overrungl.openal/build.gradle.kts b/modules/overrungl.openal/build.gradle.kts
index e69de29b..afe3afbc 100644
--- a/modules/overrungl.openal/build.gradle.kts
+++ b/modules/overrungl.openal/build.gradle.kts
@@ -0,0 +1,26 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+plugins {
+ id("module.conventions")
+ id("submodule.conventions")
+}
+
+overrunglModule {
+ artifactName = "overrungl-openal"
+ publishInfo = Artifact.OPENAL
+ nativeBinding = NativeBinding.OPENAL
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
index 97cb6b46..e524208b 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2023 Overrun Organization
+ * Copyright (c) 2023-2025 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -16,15 +16,16 @@
package overrungl.openal;
+import overrungl.annotation.CType;
+import overrungl.annotation.Out;
import overrungl.internal.RuntimeHelper;
+import overrungl.util.Marshal;
import overrungl.util.MemoryStack;
-import overrungl.util.value.Triplet;
+import overrungl.util.Unmarshal;
-import java.lang.foreign.MemorySegment;
-import java.lang.foreign.SegmentAllocator;
-
-import static java.lang.foreign.ValueLayout.*;
-import static overrungl.openal.Handles.*;
+import java.lang.foreign.FunctionDescriptor;
+import java.lang.foreign.ValueLayout;
+import java.lang.invoke.MethodHandle;
/**
* The OpenAL binding.
@@ -33,1578 +34,1161 @@
* @since 0.1.0
*/
public final class AL {
- static {
- create();
- }
-
- /**
- * No distance model or no buffer
- */
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ ///No distance model or no buffer
public static final int AL_NONE = 0;
- /**
- * Boolean False.
- */
+ ///Boolean False.
public static final int AL_FALSE = 0;
- /**
- * Boolean True.
- */
+ ///Boolean True.
public static final int AL_TRUE = 1;
- /**
- * Relative source.
- * Type: ALboolean
- * Range: [AL_FALSE, AL_TRUE]
- * Default: AL_FALSE
- *
- * Specifies if the source uses relative coordinates.
- */
+ ///Relative source.
+ ///- Type: ALboolean
+ ///- Range: \[AL_FALSE, AL_TRUE\]
+ ///- Default: AL_FALSE
+ ///
+ ///Specifies if the source uses relative coordinates.
public static final int AL_SOURCE_RELATIVE = 0x202;
- /**
- * Inner cone angle, in degrees.
- * Type: ALint, ALfloat
- * Range: [0 - 360]
- * Default: 360
- *
- * The angle covered by the inner cone, the area within which the source will
- * not be attenuated by direction.
- */
+ ///Inner cone angle, in degrees.
+ ///- Type: ALint, ALfloat
+ ///- Range: \[0 - 360\]
+ ///- Default: 360
+ ///
+ ///The angle covered by the inner cone, the area within which the source will
+ ///not be attenuated by direction.
public static final int AL_CONE_INNER_ANGLE = 0x1001;
- /**
- * Outer cone angle, in degrees.
- * Range: [0 - 360]
- * Default: 360
- *
- * The angle covered by the outer cone, the area outside which the source
- * will be fully attenuated by direction.
- */
+ ///Outer cone angle, in degrees.
+ ///- Range: \[0 - 360\]
+ ///- Default: 360
+ ///
+ ///The angle covered by the outer cone, the area outside of which the source
+ ///will be fully attenuated by direction.
public static final int AL_CONE_OUTER_ANGLE = 0x1002;
- /**
- * Source pitch.
- * Type: ALfloat
- * Range: [0.5 - 2.0]
- * Default: 1.0
- *
- * A multiplier for the sample rate of the source's buffer.
- */
+ ///Source pitch.
+ ///- Type: ALfloat
+ ///- Range: \[0.5 - 2.0\]
+ ///- Default: 1.0
+ ///
+ ///A multiplier for the sample rate of the source's buffer.
public static final int AL_PITCH = 0x1003;
- /**
- * Source or listener position.
- * Type: ALfloat[3], ALint[3]
- * Default: {0, 0, 0}
- *
- * The source or listener location in three-dimensional space.
- *
- * OpenAL uses a right-handed coordinate system, like OpenGL, where with a
- * default view, X points right (thumb), Y points up (index finger), and Z
- * points towards the viewer/camera (middle finger).
- *
- * To change from or to a left-handed coordinate system, negate the Z
- * component.
- */
+ ///Source or listener position.
+ ///- Type: ALfloat\[3\], ALint\[3\]
+ ///- Default: {0, 0, 0}
+ ///
+ ///The source or listener location in three dimensional space.
+ ///
+ ///OpenAL uses a right handed coordinate system, like OpenGL, where with a
+ ///default view, X points right (thumb), Y points up (index finger), and Z
+ ///points towards the viewer/camera (middle finger).
+ ///
+ ///To change from or to a left handed coordinate system, negate the Z
+ ///component.
public static final int AL_POSITION = 0x1004;
- /**
- * Source direction.
- * Type: ALfloat[3], ALint[3]
- * Default: {0, 0, 0}
- *
- * Specifies the current direction in local space. A zero-length vector
- * specifies an omnidirectional source (cone is ignored).
- *
- * To change from or to a left-handed coordinate system, negate the Z
- * component.
- */
+ ///Source direction.
+ ///- Type: ALfloat\[3\], ALint\[3\]
+ ///- Default: {0, 0, 0}
+ ///
+ ///Specifies the current direction in local space. A zero-length vector
+ ///specifies an omni-directional source (cone is ignored).
+ ///
+ ///To change from or to a left handed coordinate system, negate the Z
+ ///component.
public static final int AL_DIRECTION = 0x1005;
- /**
- * Source or listener velocity.
- * Type: ALfloat[3], ALint[3]
- * Default: {0, 0, 0}
- *
- * Specifies the current velocity, relative to the position.
- *
- * To change from or to a left-handed coordinate system, negate the Z
- * component.
- */
+ ///Source or listener velocity.
+ ///- Type: ALfloat\[3\], ALint\[3]\
+ ///- Default: {0, 0, 0}
+ ///
+ ///Specifies the current velocity, relative to the position.
+ ///
+ ///To change from or to a left handed coordinate system, negate the Z
+ ///component.
public static final int AL_VELOCITY = 0x1006;
- /**
- * Source looping.
- * Type: ALboolean
- * Range: [AL_FALSE, AL_TRUE]
- * Default: AL_FALSE
- *
- * Specifies whether source playback loops.
- */
+ ///Source looping.
+ ///- Type: ALboolean
+ ///- Range: \[AL_FALSE, AL_TRUE\]
+ ///- Default: AL_FALSE
+ ///
+ ///Specifies whether source playback loops.
public static final int AL_LOOPING = 0x1007;
- /**
- * Source buffer.
- * Type: ALuint
- * Range: any valid Buffer ID
- * Default: AL_NONE
- *
- * Specifies the buffer to provide sound samples for a source.
- */
+ ///Source buffer.
+ ///- Type: ALuint
+ ///- Range: any valid Buffer ID
+ ///- Default: AL_NONE
+ ///
+ ///Specifies the buffer to provide sound samples for a source.
public static final int AL_BUFFER = 0x1009;
- /**
- * Source or listener gain.
- * Type: ALfloat
- * Range: [0.0 - ]
- *
- * For sources, an initial linear gain value (before attenuation is applied).
- * For the listener, an output linear gain adjustment.
- *
- * A value of 1.0 means unattenuated. Each division by 2 equals an attenuation
- * of about -6dB. Each multiplication by 2 equals an amplification of about
- * +6dB.
- */
+ ///Source or listener gain.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - \]
+ ///
+ ///For sources, an initial linear gain value (before attenuation is applied).
+ ///For the listener, an output linear gain adjustment.
+ ///
+ ///A value of 1.0 means unattenuated. Each division by 2 equals an attenuation
+ ///of about -6dB. Each multiplication by 2 equals an amplification of about
+ ///+6dB.
public static final int AL_GAIN = 0x100A;
- /**
- * Minimum source gain.
- * Type: ALfloat
- * Range: [0.0 - 1.0]
- *
- * The minimum gain allowed for a source, after distance and cone attenuation
- * are applied (if applicable).
- */
+ ///Minimum source gain.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - 1.0\]
+ ///
+ ///The minimum gain allowed for a source, after distance and cone attenuation
+ ///are applied (if applicable).
public static final int AL_MIN_GAIN = 0x100D;
- /**
- * Maximum source gain.
- * Type: ALfloat
- * Range: [0.0 - 1.0]
- *
- * The maximum gain allowed for a source, after distance and cone attenuation
- * are applied (if applicable).
- */
+ ///Maximum source gain.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - 1.0\]
+ ///
+ ///The maximum gain allowed for a source, after distance and cone attenuation
+ ///are applied (if applicable).
public static final int AL_MAX_GAIN = 0x100E;
- /**
- * Listener orientation.
- * Type: ALfloat[6]
- * Default: {0.0, 0.0, -1.0, 0.0, 1.0, 0.0}
- *
- * Effectively two three-dimensional vectors. The first vector is the front (or
- * "at"), and the second is the top (or "up"). Both vectors are relative to the
- * listener position.
- *
- * To change from or to a left-handed coordinate system, negate the Z
- * component of both vectors.
- */
+ ///Listener orientation.
+ ///- Type: ALfloat\[6\]
+ ///- Default: {0.0, 0.0, -1.0, 0.0, 1.0, 0.0}
+ ///
+ ///Effectively two three dimensional vectors. The first vector is the front (or
+ ///"at") and the second is the top (or "up"). Both vectors are relative to the
+ ///listener position.
+ ///
+ ///To change from or to a left handed coordinate system, negate the Z
+ ///component of both vectors.
public static final int AL_ORIENTATION = 0x100F;
- /**
- * Source state (query only).
- * Type: ALenum
- * Range: [AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED]
- */
+ ///Source state (query only).
+ ///- Type: ALenum
+ ///- Range: \[AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED\]
public static final int AL_SOURCE_STATE = 0x1010;
- /**
- * Source state values.
- */
- public static final int AL_INITIAL = 0x1011,
+ ///Source state values.
+ public static final int
+ AL_INITIAL = 0x1011,
AL_PLAYING = 0x1012,
AL_PAUSED = 0x1013,
AL_STOPPED = 0x1014;
- /**
- * Source Buffer Queue size (query only).
- * Type: ALint
- *
- * The number of buffers queued using alSourceQueueBuffers, minus the buffers
- * removed with alSourceUnqueueBuffers.
- */
+ ///Source Buffer Queue size (query only).
+ ///- Type: ALint
+ ///
+ ///The number of buffers queued using alSourceQueueBuffers, minus the buffers
+ ///removed with alSourceUnqueueBuffers.
public static final int AL_BUFFERS_QUEUED = 0x1015;
- /**
- * Source Buffer Queue processed count (query only).
- * Type: ALint
- *
- * The number of queued buffers that have been fully processed and can be
- * removed with alSourceUnqueueBuffers.
- *
- * Looping sources will never fully process buffers because they will be set to
- * play again for when the source loops.
- */
+ ///Source Buffer Queue processed count (query only).
+ ///- Type: ALint
+ ///
+ ///The number of queued buffers that have been fully processed, and can be
+ ///removed with alSourceUnqueueBuffers.
+ ///
+ ///Looping sources will never fully process buffers because they will be set to
+ ///play again for when the source loops.
public static final int AL_BUFFERS_PROCESSED = 0x1016;
- /**
- * Source reference distance.
- * Type: ALfloat
- * Range: [0.0 - ]
- * Default: 1.0
- *
- * The distance in units that no distance attenuation occurs.
- *
- * At 0.0, no distance attenuation occurs with non-linear attenuation models.
- */
+ ///Source reference distance.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - \]
+ ///- Default: 1.0
+ ///
+ ///The distance in units that no distance attenuation occurs.
+ ///
+ ///At 0.0, no distance attenuation occurs with non-linear attenuation models.
public static final int AL_REFERENCE_DISTANCE = 0x1020;
- /**
- * Source rolloff factor.
- * Type: ALfloat
- * Range: [0.0 - ]
- * Default: 1.0
- *
- * Multiplier to exaggerate or diminish distance attenuation.
- *
- * At 0.0, no distance attenuation ever occurs.
- */
+ ///Source rolloff factor.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - \]
+ ///- Default: 1.0
+ ///
+ ///Multiplier to exaggerate or diminish distance attenuation.
+ ///
+ ///At 0.0, no distance attenuation ever occurs.
public static final int AL_ROLLOFF_FACTOR = 0x1021;
- /**
- * Outer cone gain.
- * Type: ALfloat
- * Range: [0.0 - 1.0]
- * Default: 0.0
- *
- * The gain attenuation applied when the listener is outside the source's
- * outer cone angle.
- */
+ ///Outer cone gain.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - 1.0\]
+ ///- Default: 0.0
+ ///
+ ///The gain attenuation applied when the listener is outside of the source's
+ ///outer cone angle.
public static final int AL_CONE_OUTER_GAIN = 0x1022;
- /**
- * Source maximum distance.
- * Type: ALfloat
- * Range: [0.0 - ]
- * Default: FLT_MAX
- *
- * The distance above which the source is not attenuated any further with a
- * clamped distance model, or where attenuation reaches 0.0 gain for linear
- * distance models with a default rolloff factor.
- */
+ ///Source maximum distance.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - \]
+ ///- Default: FLT_MAX
+ ///
+ ///The distance above which the source is not attenuated any further with a
+ ///clamped distance model, or where attenuation reaches 0.0 gain for linear
+ ///distance models with a default rolloff factor.
public static final int AL_MAX_DISTANCE = 0x1023;
- /**
- * Source buffer offset, in seconds
- */
+ ///Source buffer offset, in seconds
public static final int AL_SEC_OFFSET = 0x1024;
- /**
- * Source buffer offset, in sample frames
- */
+ ///Source buffer offset, in sample frames
public static final int AL_SAMPLE_OFFSET = 0x1025;
- /**
- * Source buffer offset, in bytes
- */
+ ///Source buffer offset, in bytes
public static final int AL_BYTE_OFFSET = 0x1026;
- /**
- * Source type (query only).
- * Type: ALenum
- * Range: [AL_STATIC, AL_STREAMING, AL_UNDETERMINED]
- *
- * A Source is Static if a Buffer has been attached using AL_BUFFER.
- *
- * A Source is Streaming if one or more Buffers have been attached using
- * alSourceQueueBuffers.
- *
- * A Source is Undetermined when it has the NULL buffer attached using
- * AL_BUFFER.
- */
+ ///Source type (query only).
+ ///- Type: ALenum
+ ///- Range: \[AL_STATIC, AL_STREAMING, AL_UNDETERMINED\]
+ ///
+ ///A Source is Static if a Buffer has been attached using AL_BUFFER.
+ ///
+ ///A Source is Streaming if one or more Buffers have been attached using
+ ///alSourceQueueBuffers.
+ ///
+ ///A Source is Undetermined when it has the NULL buffer attached using
+ ///AL_BUFFER.
public static final int AL_SOURCE_TYPE = 0x1027;
- /**
- * Source type values.
- */
- public static final int AL_STATIC = 0x1028,
+ ///Source type values.
+ public static final int
+ AL_STATIC = 0x1028,
AL_STREAMING = 0x1029,
AL_UNDETERMINED = 0x1030;
- /**
- * Unsigned 8-bit mono buffer format.
- */
+ ///Unsigned 8-bit mono buffer format.
public static final int AL_FORMAT_MONO8 = 0x1100;
- /**
- * Signed 16-bit mono buffer format.
- */
+ ///Signed 16-bit mono buffer format.
public static final int AL_FORMAT_MONO16 = 0x1101;
- /**
- * Unsigned 8-bit stereo buffer format.
- */
+ ///Unsigned 8-bit stereo buffer format.
public static final int AL_FORMAT_STEREO8 = 0x1102;
- /**
- * Signed 16-bit stereo buffer format.
- */
+ ///Signed 16-bit stereo buffer format.
public static final int AL_FORMAT_STEREO16 = 0x1103;
- /**
- * Buffer frequency/sample rate (query only).
- */
+ ///Buffer frequency/sample rate (query only).
public static final int AL_FREQUENCY = 0x2001;
- /**
- * Buffer bits per sample (query only).
- */
+ ///Buffer bits per sample (query only).
public static final int AL_BITS = 0x2002;
- /**
- * Buffer channel count (query only).
- */
+ ///Buffer channel count (query only).
public static final int AL_CHANNELS = 0x2003;
- /**
- * Buffer data size in bytes (query only).
- */
+ ///Buffer data size in bytes (query only).
public static final int AL_SIZE = 0x2004;
- /**
- * Buffer state. Not for public use.
- */
- public static final int AL_UNUSED = 0x2010,
+ ///Buffer state. Not for public use.
+ public static final int
+ AL_UNUSED = 0x2010,
AL_PENDING = 0x2011,
AL_PROCESSED = 0x2012;
- /**
- * No error.
- */
+ ///No error.
public static final int AL_NO_ERROR = 0;
- /**
- * Invalid name (ID) passed to an AL call.
- */
+ ///Invalid name (ID) passed to an AL call.
public static final int AL_INVALID_NAME = 0xA001;
- /**
- * Invalid enumeration passed to AL call.
- */
+ ///Invalid enumeration passed to AL call.
public static final int AL_INVALID_ENUM = 0xA002;
- /**
- * Invalid value passed to AL call.
- */
+ ///Invalid value passed to AL call.
public static final int AL_INVALID_VALUE = 0xA003;
- /**
- * Illegal AL call.
- */
+ ///Illegal AL call.
public static final int AL_INVALID_OPERATION = 0xA004;
- /**
- * Not enough memory to execute the AL call.
- */
+ ///Not enough memory to execute the AL call.
public static final int AL_OUT_OF_MEMORY = 0xA005;
- /**
- * Context string: Vendor name.
- */
+ ///Context string: Vendor name.
public static final int AL_VENDOR = 0xB001;
- /**
- * Context string: Version.
- */
+ ///Context string: Version.
public static final int AL_VERSION = 0xB002;
- /**
- * Context string: Renderer name.
- */
+ ///Context string: Renderer name.
public static final int AL_RENDERER = 0xB003;
- /**
- * Context string: Space-separated extension list.
- */
+ ///Context string: Space-separated extension list.
public static final int AL_EXTENSIONS = 0xB004;
- /**
- * Doppler scale.
- * Type: ALfloat
- * Range: [0.0 - ]
- * Default: 1.0
- *
- * Scale for source and listener velocities.
- */
+ ///Doppler scale.
+ ///- Type: ALfloat
+ ///- Range: \[0.0 - \]
+ ///- Default: 1.0
+ ///
+ ///Scale for source and listener velocities.
public static final int AL_DOPPLER_FACTOR = 0xC000;
- /**
- * Doppler velocity (deprecated).
- *
- * A multiplier applied to the Speed of Sound.
- */
+ ///Doppler velocity (deprecated).
+ ///
+ ///A multiplier applied to the Speed of Sound.
public static final int AL_DOPPLER_VELOCITY = 0xC001;
- /**
- * Speed of Sound, in units per second.
- * Type: ALfloat
- * Range: [0.0001 - ]
- * Default: 343.3
- *
- * The speed at which sound waves are assumed to travel, when calculating the
- * doppler effect from source and listener velocities.
- */
+ ///Speed of Sound, in units per second.
+ ///- Type: ALfloat
+ ///- Range: \[0.0001 - \]
+ ///- Default: 343.3
+ ///
+ ///The speed at which sound waves are assumed to travel, when calculating the
+ ///doppler effect from source and listener velocities.
public static final int AL_SPEED_OF_SOUND = 0xC003;
- /**
- * Distance attenuation model.
- * Type: ALenum
- * Range: [AL_NONE, AL_INVERSE_DISTANCE, AL_INVERSE_DISTANCE_CLAMPED,
- * AL_LINEAR_DISTANCE, AL_LINEAR_DISTANCE_CLAMPED,
- * AL_EXPONENT_DISTANCE, AL_EXPONENT_DISTANCE_CLAMPED]
- * Default: AL_INVERSE_DISTANCE_CLAMPED
- *
- * The model by which sources attenuate with distance.
- *
- * None - No distance attenuation.
- * Inverse - Doubling the distance halves the source gain.
- * Linear - Linear gain scaling between the reference and max distances.
- * Exponent - Exponential gain dropoff.
- *
- * Clamped variations work like the non-clamped counterparts, except the
- * distance calculated is clamped between the reference and max distances.
- */
+ ///Distance attenuation model.
+ ///- Type: ALenum
+ ///- Range: \[AL_NONE, AL_INVERSE_DISTANCE, AL_INVERSE_DISTANCE_CLAMPED,
+ /// AL_LINEAR_DISTANCE, AL_LINEAR_DISTANCE_CLAMPED,
+ /// AL_EXPONENT_DISTANCE, AL_EXPONENT_DISTANCE_CLAMPED\]
+ ///- Default: AL_INVERSE_DISTANCE_CLAMPED
+ ///
+ ///The model by which sources attenuate with distance.
+ ///
+ ///- None - No distance attenuation.
+ ///- Inverse - Doubling the distance halves the source gain.
+ ///- Linear - Linear gain scaling between the reference and max distances.
+ ///- Exponent - Exponential gain dropoff.
+ ///
+ ///Clamped variations work like the non-clamped counterparts, except the
+ ///distance calculated is clamped between the reference and max distances.
public static final int AL_DISTANCE_MODEL = 0xD000;
- /**
- * Distance model values.
- */
- public static final int AL_INVERSE_DISTANCE = 0xD001,
+ ///Distance model values.
+ public static final int
+ AL_INVERSE_DISTANCE = 0xD001,
AL_INVERSE_DISTANCE_CLAMPED = 0xD002,
AL_LINEAR_DISTANCE = 0xD003,
AL_LINEAR_DISTANCE_CLAMPED = 0xD004,
AL_EXPONENT_DISTANCE = 0xD005,
AL_EXPONENT_DISTANCE_CLAMPED = 0xD006;
-
- public static void enable(int capability) {
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alEnable`.
+ public static final MethodHandle MH_alEnable = RuntimeHelper.downcall(ALInternal.lookup(), "alEnable", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alDisable`.
+ public static final MethodHandle MH_alDisable = RuntimeHelper.downcall(ALInternal.lookup(), "alDisable", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alIsEnabled`.
+ public static final MethodHandle MH_alIsEnabled = RuntimeHelper.downcall(ALInternal.lookup(), "alIsEnabled", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alDopplerFactor`.
+ public static final MethodHandle MH_alDopplerFactor = RuntimeHelper.downcall(ALInternal.lookup(), "alDopplerFactor", FunctionDescriptor.ofVoid(ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alDopplerVelocity`.
+ public static final MethodHandle MH_alDopplerVelocity = RuntimeHelper.downcall(ALInternal.lookup(), "alDopplerVelocity", FunctionDescriptor.ofVoid(ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alSpeedOfSound`.
+ public static final MethodHandle MH_alSpeedOfSound = RuntimeHelper.downcall(ALInternal.lookup(), "alSpeedOfSound", FunctionDescriptor.ofVoid(ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alDistanceModel`.
+ public static final MethodHandle MH_alDistanceModel = RuntimeHelper.downcall(ALInternal.lookup(), "alDistanceModel", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alGetString`.
+ public static final MethodHandle MH_alGetString = RuntimeHelper.downcall(ALInternal.lookup(), "alGetString", FunctionDescriptor.of(Unmarshal.STR_LAYOUT, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetBooleanv`.
+ public static final MethodHandle MH_alGetBooleanv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBooleanv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetIntegerv`.
+ public static final MethodHandle MH_alGetIntegerv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetIntegerv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFloatv`.
+ public static final MethodHandle MH_alGetFloatv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetFloatv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetDoublev`.
+ public static final MethodHandle MH_alGetDoublev = RuntimeHelper.downcall(ALInternal.lookup(), "alGetDoublev", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBoolean`.
+ public static final MethodHandle MH_alGetBoolean = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBoolean", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetInteger`.
+ public static final MethodHandle MH_alGetInteger = RuntimeHelper.downcall(ALInternal.lookup(), "alGetInteger", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetFloat`.
+ public static final MethodHandle MH_alGetFloat = RuntimeHelper.downcall(ALInternal.lookup(), "alGetFloat", FunctionDescriptor.of(ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetDouble`.
+ public static final MethodHandle MH_alGetDouble = RuntimeHelper.downcall(ALInternal.lookup(), "alGetDouble", FunctionDescriptor.of(ValueLayout.JAVA_DOUBLE, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetError`.
+ public static final MethodHandle MH_alGetError = RuntimeHelper.downcall(ALInternal.lookup(), "alGetError", FunctionDescriptor.of(ValueLayout.JAVA_INT));
+ /// The method handle of `alIsExtensionPresent`.
+ public static final MethodHandle MH_alIsExtensionPresent = RuntimeHelper.downcall(ALInternal.lookup(), "alIsExtensionPresent", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetProcAddress`.
+ public static final MethodHandle MH_alGetProcAddress = RuntimeHelper.downcall(ALInternal.lookup(), "alGetProcAddress", FunctionDescriptor.of(ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetEnumValue`.
+ public static final MethodHandle MH_alGetEnumValue = RuntimeHelper.downcall(ALInternal.lookup(), "alGetEnumValue", FunctionDescriptor.of(ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alListenerf`.
+ public static final MethodHandle MH_alListenerf = RuntimeHelper.downcall(ALInternal.lookup(), "alListenerf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alListener3f`.
+ public static final MethodHandle MH_alListener3f = RuntimeHelper.downcall(ALInternal.lookup(), "alListener3f", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alListenerfv`.
+ public static final MethodHandle MH_alListenerfv = RuntimeHelper.downcall(ALInternal.lookup(), "alListenerfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alListeneri`.
+ public static final MethodHandle MH_alListeneri = RuntimeHelper.downcall(ALInternal.lookup(), "alListeneri", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alListener3i`.
+ public static final MethodHandle MH_alListener3i = RuntimeHelper.downcall(ALInternal.lookup(), "alListener3i", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alListeneriv`.
+ public static final MethodHandle MH_alListeneriv = RuntimeHelper.downcall(ALInternal.lookup(), "alListeneriv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListenerf`.
+ public static final MethodHandle MH_alGetListenerf = RuntimeHelper.downcall(ALInternal.lookup(), "alGetListenerf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListener3f`.
+ public static final MethodHandle MH_alGetListener3f = RuntimeHelper.downcall(ALInternal.lookup(), "alGetListener3f", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListenerfv`.
+ public static final MethodHandle MH_alGetListenerfv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetListenerfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListeneri`.
+ public static final MethodHandle MH_alGetListeneri = RuntimeHelper.downcall(ALInternal.lookup(), "alGetListeneri", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListener3i`.
+ public static final MethodHandle MH_alGetListener3i = RuntimeHelper.downcall(ALInternal.lookup(), "alGetListener3i", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListeneriv`.
+ public static final MethodHandle MH_alGetListeneriv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetListeneriv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenSources`.
+ public static final MethodHandle MH_alGenSources = RuntimeHelper.downcall(ALInternal.lookup(), "alGenSources", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteSources`.
+ public static final MethodHandle MH_alDeleteSources = RuntimeHelper.downcall(ALInternal.lookup(), "alDeleteSources", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsSource`.
+ public static final MethodHandle MH_alIsSource = RuntimeHelper.downcall(ALInternal.lookup(), "alIsSource", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcef`.
+ public static final MethodHandle MH_alSourcef = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcef", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alSource3f`.
+ public static final MethodHandle MH_alSource3f = RuntimeHelper.downcall(ALInternal.lookup(), "alSource3f", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alSourcefv`.
+ public static final MethodHandle MH_alSourcefv = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcefv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcei`.
+ public static final MethodHandle MH_alSourcei = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcei", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alSource3i`.
+ public static final MethodHandle MH_alSource3i = RuntimeHelper.downcall(ALInternal.lookup(), "alSource3i", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourceiv`.
+ public static final MethodHandle MH_alSourceiv = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcef`.
+ public static final MethodHandle MH_alGetSourcef = RuntimeHelper.downcall(ALInternal.lookup(), "alGetSourcef", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3f`.
+ public static final MethodHandle MH_alGetSource3f = RuntimeHelper.downcall(ALInternal.lookup(), "alGetSource3f", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcefv`.
+ public static final MethodHandle MH_alGetSourcefv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetSourcefv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcei`.
+ public static final MethodHandle MH_alGetSourcei = RuntimeHelper.downcall(ALInternal.lookup(), "alGetSourcei", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3i`.
+ public static final MethodHandle MH_alGetSource3i = RuntimeHelper.downcall(ALInternal.lookup(), "alGetSource3i", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourceiv`.
+ public static final MethodHandle MH_alGetSourceiv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetSourceiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcePlay`.
+ public static final MethodHandle MH_alSourcePlay = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcePlay", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alSourceStop`.
+ public static final MethodHandle MH_alSourceStop = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceStop", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alSourceRewind`.
+ public static final MethodHandle MH_alSourceRewind = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceRewind", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcePause`.
+ public static final MethodHandle MH_alSourcePause = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcePause", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcePlayv`.
+ public static final MethodHandle MH_alSourcePlayv = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcePlayv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceStopv`.
+ public static final MethodHandle MH_alSourceStopv = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceStopv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceRewindv`.
+ public static final MethodHandle MH_alSourceRewindv = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceRewindv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcePausev`.
+ public static final MethodHandle MH_alSourcePausev = RuntimeHelper.downcall(ALInternal.lookup(), "alSourcePausev", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceQueueBuffers`.
+ public static final MethodHandle MH_alSourceQueueBuffers = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceQueueBuffers", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceUnqueueBuffers`.
+ public static final MethodHandle MH_alSourceUnqueueBuffers = RuntimeHelper.downcall(ALInternal.lookup(), "alSourceUnqueueBuffers", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenBuffers`.
+ public static final MethodHandle MH_alGenBuffers = RuntimeHelper.downcall(ALInternal.lookup(), "alGenBuffers", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteBuffers`.
+ public static final MethodHandle MH_alDeleteBuffers = RuntimeHelper.downcall(ALInternal.lookup(), "alDeleteBuffers", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsBuffer`.
+ public static final MethodHandle MH_alIsBuffer = RuntimeHelper.downcall(ALInternal.lookup(), "alIsBuffer", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alBufferData`.
+ public static final MethodHandle MH_alBufferData = RuntimeHelper.downcall(ALInternal.lookup(), "alBufferData", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alBufferf`.
+ public static final MethodHandle MH_alBufferf = RuntimeHelper.downcall(ALInternal.lookup(), "alBufferf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alBuffer3f`.
+ public static final MethodHandle MH_alBuffer3f = RuntimeHelper.downcall(ALInternal.lookup(), "alBuffer3f", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alBufferfv`.
+ public static final MethodHandle MH_alBufferfv = RuntimeHelper.downcall(ALInternal.lookup(), "alBufferfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alBufferi`.
+ public static final MethodHandle MH_alBufferi = RuntimeHelper.downcall(ALInternal.lookup(), "alBufferi", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alBuffer3i`.
+ public static final MethodHandle MH_alBuffer3i = RuntimeHelper.downcall(ALInternal.lookup(), "alBuffer3i", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alBufferiv`.
+ public static final MethodHandle MH_alBufferiv = RuntimeHelper.downcall(ALInternal.lookup(), "alBufferiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferf`.
+ public static final MethodHandle MH_alGetBufferf = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBufferf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBuffer3f`.
+ public static final MethodHandle MH_alGetBuffer3f = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBuffer3f", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferfv`.
+ public static final MethodHandle MH_alGetBufferfv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBufferfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferi`.
+ public static final MethodHandle MH_alGetBufferi = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBufferi", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBuffer3i`.
+ public static final MethodHandle MH_alGetBuffer3i = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBuffer3i", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferiv`.
+ public static final MethodHandle MH_alGetBufferiv = RuntimeHelper.downcall(ALInternal.lookup(), "alGetBufferiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alEnable(@CType("ALenum") int capability) {
+ try {
+ Handles.MH_alEnable.invokeExact(capability);
+ } catch (Throwable e) { throw new RuntimeException("error in alEnable", e); }
+ }
+
+ public static void alDisable(@CType("ALenum") int capability) {
try {
- alEnable.invokeExact(capability);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alDisable.invokeExact(capability);
+ } catch (Throwable e) { throw new RuntimeException("error in alDisable", e); }
}
- public static void disable(int capability) {
+ public static @CType("ALboolean") boolean alIsEnabled(@CType("ALenum") int capability) {
try {
- alDisable.invokeExact(capability);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alIsEnabled.invokeExact(capability);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsEnabled", e); }
}
- public static boolean isEnabled(int capability) {
+ public static void alDopplerFactor(@CType("ALfloat") float value) {
try {
- return (boolean) alIsEnabled.invokeExact(capability);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alDopplerFactor.invokeExact(value);
+ } catch (Throwable e) { throw new RuntimeException("error in alDopplerFactor", e); }
}
- public static void dopplerFactor(float value) {
+ public static void alDopplerVelocity(@CType("ALfloat") float value) {
try {
- alDopplerFactor.invokeExact(value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alDopplerVelocity.invokeExact(value);
+ } catch (Throwable e) { throw new RuntimeException("error in alDopplerVelocity", e); }
}
- public static void dopplerVelocity(float value) {
+ public static void alSpeedOfSound(@CType("ALfloat") float value) {
try {
- alDopplerVelocity.invokeExact(value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSpeedOfSound.invokeExact(value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSpeedOfSound", e); }
}
- public static void speedOfSound(float value) {
+ public static void alDistanceModel(@CType("ALenum") int distanceModel) {
try {
- alSpeedOfSound.invokeExact(value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alDistanceModel.invokeExact(distanceModel);
+ } catch (Throwable e) { throw new RuntimeException("error in alDistanceModel", e); }
}
- public static void distanceModel(int distanceModel) {
+ public static @CType("const ALchar*") java.lang.foreign.MemorySegment alGetString_(@CType("ALenum") int param) {
try {
- alDistanceModel.invokeExact(distanceModel);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetString.invokeExact(param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetString", e); }
}
- public static MemorySegment ngetString(int param) {
+ public static @CType("const ALchar*") java.lang.String alGetString(@CType("ALenum") int param) {
try {
- return (MemorySegment) alGetString.invokeExact(param);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
- }
-
- public static String getString(int param) {
- return ngetString(param).getUtf8String(0);
+ return Unmarshal.unmarshalAsString((java.lang.foreign.MemorySegment) Handles.MH_alGetString.invokeExact(param));
+ } catch (Throwable e) { throw new RuntimeException("error in alGetString", e); }
}
- public static void ngetBooleanv(int param, MemorySegment values) {
+ public static void alGetBooleanv(@CType("ALenum") int param, @Out @CType("ALboolean *") java.lang.foreign.MemorySegment values) {
try {
- alGetBooleanv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
- }
-
- public static void getBooleanv(SegmentAllocator allocator, int param, boolean[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_BYTE, values.length);
- ngetBooleanv(param, seg);
- RuntimeHelper.toArray(seg, values);
+ Handles.MH_alGetBooleanv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBooleanv", e); }
}
- public static void ngetIntegerv(int param, MemorySegment values) {
+ public static void alGetIntegerv(@CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment values) {
try {
- alGetIntegerv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetIntegerv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetIntegerv", e); }
}
- public static void getIntegerv(SegmentAllocator allocator, int param, int[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
- ngetIntegerv(param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetIntegerv(@CType("ALenum") int param, @Out @CType("ALint *") int[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetIntegerv.invokeExact(param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetIntegerv", e); }
}
- public static void ngetFloatv(int param, MemorySegment values) {
+ public static void alGetFloatv(@CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- alGetFloatv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetFloatv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFloatv", e); }
}
- public static void getFloatv(SegmentAllocator allocator, int param, float[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
- ngetFloatv(param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetFloatv(@CType("ALenum") int param, @Out @CType("ALfloat *") float[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetFloatv.invokeExact(param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFloatv", e); }
}
- public static void ngetDoublev(int param, MemorySegment values) {
+ public static void alGetDoublev(@CType("ALenum") int param, @Out @CType("ALdouble *") java.lang.foreign.MemorySegment values) {
try {
- alGetDoublev.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetDoublev.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDoublev", e); }
}
- public static void getDoublev(SegmentAllocator allocator, int param, double[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_DOUBLE, values.length);
- ngetDoublev(param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetDoublev(@CType("ALenum") int param, @Out @CType("ALdouble *") double[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetDoublev.invokeExact(param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDoublev", e); }
}
- public static boolean getBoolean(int param) {
+ public static @CType("ALboolean") boolean alGetBoolean(@CType("ALenum") int param) {
try {
- return (boolean) alGetBoolean.invokeExact(param);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alGetBoolean.invokeExact(param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBoolean", e); }
}
- public static int getInteger(int param) {
+ public static @CType("ALint") int alGetInteger(@CType("ALenum") int param) {
try {
- return (int) alGetInteger.invokeExact(param);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (int) Handles.MH_alGetInteger.invokeExact(param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetInteger", e); }
}
- public static float getFloat(int param) {
+ public static @CType("ALfloat") float alGetFloat(@CType("ALenum") int param) {
try {
- return (float) alGetFloat.invokeExact(param);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (float) Handles.MH_alGetFloat.invokeExact(param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFloat", e); }
}
- public static double getDouble(int param) {
+ public static @CType("ALdouble") double alGetDouble(@CType("ALenum") int param) {
try {
- return (double) alGetDouble.invokeExact(param);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (double) Handles.MH_alGetDouble.invokeExact(param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDouble", e); }
}
- /**
- * Obtain the first error generated in the AL context since the last call to
- * this function.
- *
- * @return the error code
- */
- public static int getError() {
+ ///Obtain the first error generated in the AL context since the last call to
+ ///this function.
+ public static @CType("ALenum") int alGetError() {
try {
- return (int) alGetError.invokeExact();
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (int) Handles.MH_alGetError.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alGetError", e); }
}
- /**
- * Query for the presence of an extension on the AL context.
- *
- * @param extName the name of the extension
- * @return the presence of the given extension
- */
- public static boolean nisExtensionPresent(MemorySegment extName) {
+ ///Query for the presence of an extension on the AL context.
+ public static @CType("ALboolean") boolean alIsExtensionPresent(@CType("const ALchar*") java.lang.foreign.MemorySegment extname) {
try {
- return (boolean) alIsExtensionPresent.invokeExact(extName);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
- }
-
- /**
- * Query for the presence of an extension on the AL context.
- *
- * @param extName the name of the extension
- * @return the presence of the given extension
- * @see #nisExtensionPresent(MemorySegment) nisExtensionPresent
- */
- public static boolean isExtensionPresent(SegmentAllocator allocator, String extName) {
- return nisExtensionPresent(allocator.allocateUtf8String(extName));
- }
-
- /**
- * Retrieve the address of a function.
- * The returned function may be context-specific.
- *
- * @param fname the name of the function
- * @return the address of the given function
- */
- public static MemorySegment ngetProcAddress(MemorySegment fname) {
- try {
- return (MemorySegment) alGetProcAddress.invokeExact(fname);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alIsExtensionPresent.invokeExact(extname);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsExtensionPresent", e); }
}
- /**
- * Retrieve the address of a function.
- * The returned function may be context-specific.
- *
- * @param fname the name of the function
- * @return the address of the given function
- * @see #ngetProcAddress(MemorySegment) ngetProcAddress
- */
- public static MemorySegment getProcAddress(SegmentAllocator allocator, String fname) {
- return ngetProcAddress(allocator.allocateUtf8String(fname));
- }
-
- /**
- * Retrieve the value of an enum. The returned value may be context-specific.
- *
- * @param ename the name of the enum
- * @return the value of the given enum
- */
- public static int ngetEnumValue(MemorySegment ename) {
- try {
- return (int) alGetEnumValue.invokeExact(ename);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
- }
-
- /**
- * Retrieve the value of an enum. The returned value may be context-specific.
- *
- * @param ename the name of the enum
- * @return the value of the given enum
- * @see #ngetEnumValue(MemorySegment) ngetEnumValue
- */
- public static int getEnumValue(SegmentAllocator allocator, String ename) {
- return ngetEnumValue(allocator.allocateUtf8String(ename));
+ ///Query for the presence of an extension on the AL context.
+ public static @CType("ALboolean") boolean alIsExtensionPresent(@CType("const ALchar*") java.lang.String extname) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (boolean) Handles.MH_alIsExtensionPresent.invokeExact(Marshal.marshal(__overrungl_stack, extname));
+ } catch (Throwable e) { throw new RuntimeException("error in alIsExtensionPresent", e); }
}
- public static void listenerf(int param, float value) {
+ ///Retrieve the address of a function. The returned function may be context-
+ ///specific.
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetProcAddress(@CType("const ALchar*") java.lang.foreign.MemorySegment fname) {
try {
- alListenerf.invokeExact(param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetProcAddress.invokeExact(fname);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetProcAddress", e); }
}
- public static void listener3f(int param, float value1, float value2, float value3) {
- try {
- alListener3f.invokeExact(param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Retrieve the address of a function. The returned function may be context-
+ ///specific.
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetProcAddress(@CType("const ALchar*") java.lang.String fname) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetProcAddress.invokeExact(Marshal.marshal(__overrungl_stack, fname));
+ } catch (Throwable e) { throw new RuntimeException("error in alGetProcAddress", e); }
}
- public static void nlistenerfv(int param, MemorySegment values) {
+ ///Retrieve the value of an enum. The returned value may be context-specific.
+ public static @CType("ALenum") int alGetEnumValue(@CType("const ALchar*") java.lang.foreign.MemorySegment ename) {
try {
- alListenerfv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (int) Handles.MH_alGetEnumValue.invokeExact(ename);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEnumValue", e); }
}
- public static void listenerfv(SegmentAllocator allocator, int param, float[] values) {
- nlistenerfv(param, allocator.allocateArray(JAVA_FLOAT, values));
+ ///Retrieve the value of an enum. The returned value may be context-specific.
+ public static @CType("ALenum") int alGetEnumValue(@CType("const ALchar*") java.lang.String ename) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (int) Handles.MH_alGetEnumValue.invokeExact(Marshal.marshal(__overrungl_stack, ename));
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEnumValue", e); }
}
- public static void listeneri(int param, int value) {
+ public static void alListenerf(@CType("ALenum") int param, @CType("ALfloat") float value) {
try {
- alListeneri.invokeExact(param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alListenerf.invokeExact(param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alListenerf", e); }
}
- public static void listener3i(int param, int value1, int value2, int value3) {
+ public static void alListener3f(@CType("ALenum") int param, @CType("ALfloat") float value1, @CType("ALfloat") float value2, @CType("ALfloat") float value3) {
try {
- alListener3i.invokeExact(param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alListener3f.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alListener3f", e); }
}
- public static void nlisteneriv(int param, MemorySegment values) {
+ public static void alListenerfv(@CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- alListeneriv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alListenerfv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alListenerfv", e); }
}
- public static void listeneriv(SegmentAllocator allocator, int param, int[] values) {
- nlisteneriv(param, allocator.allocateArray(JAVA_INT, values));
+ public static void alListeneri(@CType("ALenum") int param, @CType("ALint") int value) {
+ try {
+ Handles.MH_alListeneri.invokeExact(param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alListeneri", e); }
}
- public static void ngetListenerf(int param, MemorySegment value) {
+ public static void alListener3i(@CType("ALenum") int param, @CType("ALint") int value1, @CType("ALint") int value2, @CType("ALint") int value3) {
try {
- alGetListenerf.invokeExact(param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alListener3i.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alListener3i", e); }
}
- public static float getListenerf(int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
+ public static void alListeneriv(@CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment values) {
try {
- final MemorySegment seg = stack.calloc(JAVA_FLOAT);
- ngetListenerf(param, seg);
- return seg.get(JAVA_FLOAT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ Handles.MH_alListeneriv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alListeneriv", e); }
}
- public static void ngetListener3f(int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ public static void alGetListenerf(@CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value) {
try {
- alGetListener3f.invokeExact(param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetListenerf.invokeExact(param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerf", e); }
}
- public static Triplet.OfFloat getListener3f(int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg1 = stack.calloc(JAVA_FLOAT);
- final MemorySegment seg2 = stack.calloc(JAVA_FLOAT);
- final MemorySegment seg3 = stack.calloc(JAVA_FLOAT);
- ngetListener3f(param, seg1, seg2, seg3);
- return new Triplet.OfFloat(seg1.get(JAVA_FLOAT, 0), seg2.get(JAVA_FLOAT, 0), seg3.get(JAVA_FLOAT, 0));
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetListenerf(@CType("ALenum") int param, @Out @CType("ALfloat *") float[] value) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value = Marshal.marshal(__overrungl_stack, value);
+ Handles.MH_alGetListenerf.invokeExact(param, __overrungl_ref_value);
+ Unmarshal.copy(__overrungl_ref_value, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerf", e); }
}
- public static void ngetListenerfv(int param, MemorySegment values) {
+ public static void alGetListener3f(@CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value1, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value2, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value3) {
try {
- alGetListenerfv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetListener3f.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListener3f", e); }
}
- public static void getListenerfv(SegmentAllocator allocator, int param, float[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
- ngetListenerfv(param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetListener3f(@CType("ALenum") int param, @Out @CType("ALfloat *") float[] value1, @Out @CType("ALfloat *") float[] value2, @Out @CType("ALfloat *") float[] value3) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value1 = Marshal.marshal(__overrungl_stack, value1);
+ var __overrungl_ref_value2 = Marshal.marshal(__overrungl_stack, value2);
+ var __overrungl_ref_value3 = Marshal.marshal(__overrungl_stack, value3);
+ Handles.MH_alGetListener3f.invokeExact(param, __overrungl_ref_value1, __overrungl_ref_value2, __overrungl_ref_value3);
+ Unmarshal.copy(__overrungl_ref_value1, value1);
+ Unmarshal.copy(__overrungl_ref_value2, value2);
+ Unmarshal.copy(__overrungl_ref_value3, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListener3f", e); }
}
- public static void ngetListeneri(int param, MemorySegment value) {
+ public static void alGetListenerfv(@CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- alGetListeneri.invokeExact(param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetListenerfv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerfv", e); }
}
- public static float getListeneri(int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_INT);
- ngetListeneri(param, seg);
- return seg.get(JAVA_INT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetListenerfv(@CType("ALenum") int param, @Out @CType("ALfloat *") float[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetListenerfv.invokeExact(param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerfv", e); }
}
- public static void ngetListener3i(int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ public static void alGetListeneri(@CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment value) {
try {
- alGetListener3i.invokeExact(param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetListeneri.invokeExact(param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListeneri", e); }
}
- public static Triplet.OfInt getListener3i(int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg1 = stack.calloc(JAVA_INT);
- final MemorySegment seg2 = stack.calloc(JAVA_INT);
- final MemorySegment seg3 = stack.calloc(JAVA_INT);
- ngetListener3i(param, seg1, seg2, seg3);
- return new Triplet.OfInt(seg1.get(JAVA_INT, 0), seg2.get(JAVA_INT, 0), seg3.get(JAVA_INT, 0));
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetListeneri(@CType("ALenum") int param, @Out @CType("ALint *") int[] value) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value = Marshal.marshal(__overrungl_stack, value);
+ Handles.MH_alGetListeneri.invokeExact(param, __overrungl_ref_value);
+ Unmarshal.copy(__overrungl_ref_value, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListeneri", e); }
}
- public static void ngetListeneriv(int param, MemorySegment values) {
+ public static void alGetListener3i(@CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment value1, @Out @CType("ALint *") java.lang.foreign.MemorySegment value2, @Out @CType("ALint *") java.lang.foreign.MemorySegment value3) {
try {
- alGetListeneriv.invokeExact(param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetListener3i.invokeExact(param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListener3i", e); }
}
- public static void getListeneriv(SegmentAllocator allocator, int param, int[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
- ngetListeneriv(param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetListener3i(@CType("ALenum") int param, @Out @CType("ALint *") int[] value1, @Out @CType("ALint *") int[] value2, @Out @CType("ALint *") int[] value3) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value1 = Marshal.marshal(__overrungl_stack, value1);
+ var __overrungl_ref_value2 = Marshal.marshal(__overrungl_stack, value2);
+ var __overrungl_ref_value3 = Marshal.marshal(__overrungl_stack, value3);
+ Handles.MH_alGetListener3i.invokeExact(param, __overrungl_ref_value1, __overrungl_ref_value2, __overrungl_ref_value3);
+ Unmarshal.copy(__overrungl_ref_value1, value1);
+ Unmarshal.copy(__overrungl_ref_value2, value2);
+ Unmarshal.copy(__overrungl_ref_value3, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListener3i", e); }
}
- /**
- * Create source objects.
- *
- * @param n the count of the objects.
- * @param sources a buffer that retrieves the objects.
- */
- public static void ngenSources(int n, MemorySegment sources) {
+ public static void alGetListeneriv(@CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment values) {
try {
- alGenSources.invokeExact(n, sources);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetListeneriv.invokeExact(param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListeneriv", e); }
}
- /**
- * Create source objects.
- *
- * @param allocator the allocator of the buffer.
- * @param sources an array that retrieves the objects.
- * @see #ngenSources(int, MemorySegment) ngenSources
- */
- public static void genSources(SegmentAllocator allocator, int[] sources) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
- ngenSources(sources.length, seg);
- RuntimeHelper.toArray(seg, sources);
- }
-
- /**
- * Create a source object.
- *
- * @return the object.
- * @see #ngenSources(int, MemorySegment) ngenSources
- */
- public static int genSource() {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_INT);
- ngenSources(1, seg);
- return seg.get(JAVA_INT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetListeneriv(@CType("ALenum") int param, @Out @CType("ALint *") int[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetListeneriv.invokeExact(param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListeneriv", e); }
}
- /**
- * Delete source objects.
- *
- * @param n the count of the objects.
- * @param sources the objects.
- */
- public static void ndeleteSources(int n, MemorySegment sources) {
+ ///Create source objects.
+ public static void alGenSources(@CType("ALsizei") int n, @Out @CType("ALuint *") java.lang.foreign.MemorySegment sources) {
try {
- alDeleteSources.invokeExact(n, sources);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGenSources.invokeExact(n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenSources", e); }
}
- /**
- * Delete source objects.
- *
- * @param allocator the allocator of the buffer.
- * @param sources the objects.
- * @see #ndeleteSources(int, MemorySegment) ndeleteSources
- */
- public static void deleteSources(SegmentAllocator allocator, int[] sources) {
- ndeleteSources(sources.length, allocator.allocateArray(JAVA_INT, sources));
- }
-
- /**
- * Delete a source object.
- *
- * @param source the object.
- * @see #ndeleteSources(int, MemorySegment) ndeleteSources
- */
- public static void deleteSource(int source) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- ngenSources(1, stack.ints(source));
- } finally {
- stack.setPointer(stackPointer);
- }
+ ///Delete source objects.
+ public static void alDeleteSources(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ try {
+ Handles.MH_alDeleteSources.invokeExact(n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteSources", e); }
}
- /**
- * Verify an ID is for a valid source.
- *
- * @param source an ID of a source
- * @return the result
- */
- public static boolean isSource(int source) {
+ ///Verify an ID is for a valid source.
+ public static @CType("ALboolean") boolean alIsSource(@CType("ALuint") int source) {
try {
- return (boolean) alIsSource.invokeExact(source);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alIsSource.invokeExact(source);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsSource", e); }
}
- public static void sourcef(int source, int param, float value) {
+ public static void alSourcef(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat") float value) {
try {
- alSourcef.invokeExact(source, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourcef.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcef", e); }
}
- public static void source3f(int source, int param, float value1, float value2, float value3) {
+ public static void alSource3f(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat") float value1, @CType("ALfloat") float value2, @CType("ALfloat") float value3) {
try {
- alSource3f.invokeExact(source, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSource3f.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3f", e); }
}
- public static void nsourcefv(int source, int param, MemorySegment values) {
+ public static void alSourcefv(@CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- alSourcefv.invokeExact(source, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourcefv.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcefv", e); }
}
- public static void sourcefv(SegmentAllocator allocator, int source, int param, float[] values) {
- nsourcefv(source, param, allocator.allocateArray(JAVA_FLOAT, values));
+ public static void alSourcei(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint") int value) {
+ try {
+ Handles.MH_alSourcei.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcei", e); }
}
- public static void sourcei(int source, int param, int value) {
+ public static void alSource3i(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint") int value1, @CType("ALint") int value2, @CType("ALint") int value3) {
try {
- alSourcei.invokeExact(source, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSource3i.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3i", e); }
}
- public static void source3i(int source, int param, int value1, int value2, int value3) {
+ public static void alSourceiv(@CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment values) {
try {
- alSource3i.invokeExact(source, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourceiv.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceiv", e); }
}
- public static void nsourceiv(int source, int param, MemorySegment values) {
+ public static void alGetSourcef(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value) {
try {
- alSourceiv.invokeExact(source, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetSourcef.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcef", e); }
}
- public static void sourceiv(SegmentAllocator allocator, int source, int param, int[] values) {
- nsourceiv(source, param, allocator.allocateArray(JAVA_INT, values));
+ public static void alGetSourcef(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALfloat *") float[] value) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value = Marshal.marshal(__overrungl_stack, value);
+ Handles.MH_alGetSourcef.invokeExact(source, param, __overrungl_ref_value);
+ Unmarshal.copy(__overrungl_ref_value, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcef", e); }
}
- public static void ngetSourcef(int source, int param, MemorySegment value) {
+ public static void alGetSource3f(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value1, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value2, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value3) {
try {
- alGetSourcef.invokeExact(source, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetSource3f.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3f", e); }
}
- public static float getSourcef(int source, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_FLOAT);
- ngetSourcef(source, param, seg);
- return seg.get(JAVA_FLOAT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetSource3f(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALfloat *") float[] value1, @Out @CType("ALfloat *") float[] value2, @Out @CType("ALfloat *") float[] value3) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value1 = Marshal.marshal(__overrungl_stack, value1);
+ var __overrungl_ref_value2 = Marshal.marshal(__overrungl_stack, value2);
+ var __overrungl_ref_value3 = Marshal.marshal(__overrungl_stack, value3);
+ Handles.MH_alGetSource3f.invokeExact(source, param, __overrungl_ref_value1, __overrungl_ref_value2, __overrungl_ref_value3);
+ Unmarshal.copy(__overrungl_ref_value1, value1);
+ Unmarshal.copy(__overrungl_ref_value2, value2);
+ Unmarshal.copy(__overrungl_ref_value3, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3f", e); }
}
- public static void ngetSource3f(int source, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ public static void alGetSourcefv(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- alGetSource3f.invokeExact(source, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetSourcefv.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcefv", e); }
}
- public static Triplet.OfFloat getSource3f(int source, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg1 = stack.calloc(JAVA_FLOAT);
- final MemorySegment seg2 = stack.calloc(JAVA_FLOAT);
- final MemorySegment seg3 = stack.calloc(JAVA_FLOAT);
- ngetSource3f(source, param, seg1, seg2, seg3);
- return new Triplet.OfFloat(seg1.get(JAVA_FLOAT, 0), seg2.get(JAVA_FLOAT, 0), seg3.get(JAVA_FLOAT, 0));
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetSourcefv(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALfloat *") float[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetSourcefv.invokeExact(source, param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcefv", e); }
}
- public static void ngetSourcefv(int source, int param, MemorySegment values) {
+ public static void alGetSourcei(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment value) {
try {
- alGetSourcefv.invokeExact(source, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetSourcei.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcei", e); }
}
- public static void getSourcefv(SegmentAllocator allocator, int source, int param, float[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
- ngetSourcefv(source, param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetSourcei(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALint *") int[] value) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value = Marshal.marshal(__overrungl_stack, value);
+ Handles.MH_alGetSourcei.invokeExact(source, param, __overrungl_ref_value);
+ Unmarshal.copy(__overrungl_ref_value, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcei", e); }
}
- public static void ngetSourcei(int source, int param, MemorySegment value) {
+ public static void alGetSource3i(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment value1, @Out @CType("ALint *") java.lang.foreign.MemorySegment value2, @Out @CType("ALint *") java.lang.foreign.MemorySegment value3) {
try {
- alGetSourcei.invokeExact(source, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetSource3i.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3i", e); }
}
- public static float getSourcei(int source, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_INT);
- ngetSourcei(source, param, seg);
- return seg.get(JAVA_INT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetSource3i(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALint *") int[] value1, @Out @CType("ALint *") int[] value2, @Out @CType("ALint *") int[] value3) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value1 = Marshal.marshal(__overrungl_stack, value1);
+ var __overrungl_ref_value2 = Marshal.marshal(__overrungl_stack, value2);
+ var __overrungl_ref_value3 = Marshal.marshal(__overrungl_stack, value3);
+ Handles.MH_alGetSource3i.invokeExact(source, param, __overrungl_ref_value1, __overrungl_ref_value2, __overrungl_ref_value3);
+ Unmarshal.copy(__overrungl_ref_value1, value1);
+ Unmarshal.copy(__overrungl_ref_value2, value2);
+ Unmarshal.copy(__overrungl_ref_value3, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3i", e); }
}
- public static void ngetSource3i(int source, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ public static void alGetSourceiv(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment values) {
try {
- alGetSource3i.invokeExact(source, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetSourceiv.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourceiv", e); }
}
- public static Triplet.OfInt getSource3i(int source, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg1 = stack.calloc(JAVA_INT);
- final MemorySegment seg2 = stack.calloc(JAVA_INT);
- final MemorySegment seg3 = stack.calloc(JAVA_INT);
- ngetSource3i(source, param, seg1, seg2, seg3);
- return new Triplet.OfInt(seg1.get(JAVA_INT, 0), seg2.get(JAVA_INT, 0), seg3.get(JAVA_INT, 0));
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetSourceiv(@CType("ALuint") int source, @CType("ALenum") int param, @Out @CType("ALint *") int[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetSourceiv.invokeExact(source, param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourceiv", e); }
}
- public static void ngetSourceiv(int source, int param, MemorySegment values) {
+ ///Play, restart, or resume a source, setting its state to AL_PLAYING.
+ public static void alSourcePlay(@CType("ALuint") int source) {
try {
- alGetSourceiv.invokeExact(source, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourcePlay.invokeExact(source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlay", e); }
}
- public static void getSourceiv(SegmentAllocator allocator, int source, int param, int[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
- ngetSourceiv(source, param, seg);
- RuntimeHelper.toArray(seg, values);
+ ///Stop a source, setting its state to AL_STOPPED if playing or paused.
+ public static void alSourceStop(@CType("ALuint") int source) {
+ try {
+ Handles.MH_alSourceStop.invokeExact(source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceStop", e); }
}
- /**
- * Play, restart, or resume a source, setting its state to {@link #AL_PLAYING}.
- *
- * @param source the ID of the source
- */
- public static void sourcePlay(int source) {
+ ///Rewind a source, setting its state to AL_INITIAL.
+ public static void alSourceRewind(@CType("ALuint") int source) {
try {
- alSourcePlay.invokeExact(source);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourceRewind.invokeExact(source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceRewind", e); }
}
- /**
- * Stop a source, setting its state to {@link #AL_STOPPED} if playing or paused.
- *
- * @param source the ID of the source
- */
- public static void sourceStop(int source) {
+ ///Pause a source, setting its state to AL_PAUSED if playing.
+ public static void alSourcePause(@CType("ALuint") int source) {
try {
- alSourceStop.invokeExact(source);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourcePause.invokeExact(source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePause", e); }
}
- /**
- * Rewind a source, setting its state to {@link #AL_INITIAL}.
- *
- * @param source the ID of the source
- */
- public static void sourceRewind(int source) {
+ ///Play, restart, or resume a list of sources atomically.
+ public static void alSourcePlayv(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
- alSourceRewind.invokeExact(source);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourcePlayv.invokeExact(n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayv", e); }
}
- /**
- * Pause a source, setting its state to {@link #AL_PAUSED} if playing.
- *
- * @param source the ID of the source
- */
- public static void sourcePause(int source) {
+ ///Stop a list of sources atomically.
+ public static void alSourceStopv(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
- alSourcePause.invokeExact(source);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourceStopv.invokeExact(n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceStopv", e); }
}
- /**
- * Play, restart, or resume a list of sources atomically.
- *
- * @param n the count of the sources
- * @param sources the sources
- */
- public static void nsourcePlayv(int n, MemorySegment sources) {
+ ///Rewind a list of sources atomically.
+ public static void alSourceRewindv(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
- alSourcePlayv.invokeExact(n, sources);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alSourceRewindv.invokeExact(n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceRewindv", e); }
}
- /**
- * Play, restart, or resume a list of sources atomically.
- *
- * @param allocator the allocator of the sources
- * @param sources the sources
- * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
- */
- public static void sourcePlayv(SegmentAllocator allocator, int[] sources) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
- nsourcePlayv(sources.length, seg);
- RuntimeHelper.toArray(seg, sources);
- }
-
- /**
- * Stop a list of sources atomically.
- *
- * @param n the count of the sources
- * @param sources the sources
- */
- public static void nsourceStopv(int n, MemorySegment sources) {
- try {
- alSourceStopv.invokeExact(n, sources);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Pause a list of sources atomically.
+ public static void alSourcePausev(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ try {
+ Handles.MH_alSourcePausev.invokeExact(n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePausev", e); }
}
- /**
- * Stop a list of sources atomically.
- *
- * @param allocator the allocator of the sources
- * @param sources the sources
- * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
- */
- public static void sourceStopv(SegmentAllocator allocator, int[] sources) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
- nsourceStopv(sources.length, seg);
- RuntimeHelper.toArray(seg, sources);
- }
-
- /**
- * Rewind a list of sources atomically.
- *
- * @param n the count of the sources
- * @param sources the sources
- */
- public static void nsourceRewindv(int n, MemorySegment sources) {
- try {
- alSourceRewindv.invokeExact(n, sources);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Queue buffers onto a source
+ public static void alSourceQueueBuffers(@CType("ALuint") int source, @CType("ALsizei") int nb, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers) {
+ try {
+ Handles.MH_alSourceQueueBuffers.invokeExact(source, nb, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceQueueBuffers", e); }
}
- /**
- * Rewind a list of sources atomically.
- *
- * @param allocator the allocator of the sources
- * @param sources the sources
- * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
- */
- public static void sourceRewindv(SegmentAllocator allocator, int[] sources) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
- nsourceRewindv(sources.length, seg);
- RuntimeHelper.toArray(seg, sources);
- }
-
- /**
- * Pause a list of sources atomically.
- *
- * @param n the count of the sources
- * @param sources the sources
- */
- public static void nsourcePausev(int n, MemorySegment sources) {
- try {
- alSourcePausev.invokeExact(n, sources);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Unqueue processed buffers from a source
+ public static void alSourceUnqueueBuffers(@CType("ALuint") int source, @CType("ALsizei") int nb, @Out @CType("ALuint *") java.lang.foreign.MemorySegment buffers) {
+ try {
+ Handles.MH_alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceUnqueueBuffers", e); }
}
- /**
- * Pause a list of sources atomically.
- *
- * @param allocator the allocator of the sources
- * @param sources the sources
- * @see #nsourcePlayv(int, MemorySegment) nsourcePlayv
- */
- public static void sourcePausev(SegmentAllocator allocator, int[] sources) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, sources.length);
- nsourcePausev(sources.length, seg);
- RuntimeHelper.toArray(seg, sources);
- }
-
- /**
- * Queue buffers onto a source
- *
- * @param source the source
- * @param nb the count of the buffers
- * @param buffers the buffers
- */
- public static void nsourceQueueBuffers(int source, int nb, MemorySegment buffers) {
- try {
- alSourceQueueBuffers.invokeExact(source, nb, buffers);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Create buffer objects
+ public static void alGenBuffers(@CType("ALsizei") int n, @Out @CType("ALuint *") java.lang.foreign.MemorySegment buffers) {
+ try {
+ Handles.MH_alGenBuffers.invokeExact(n, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenBuffers", e); }
}
- /**
- * Queue buffers onto a source
- *
- * @param allocator the allocator of the buffers
- * @param source the source
- * @param buffers the buffers
- */
- public static void sourceQueueBuffers(SegmentAllocator allocator, int source, int[] buffers) {
- nsourceQueueBuffers(source, buffers.length, allocator.allocateArray(JAVA_INT, buffers));
- }
-
- /**
- * Unqueue processed buffers from a source
- *
- * @param source the source
- * @param nb the count of the buffers
- * @param buffers the buffers
- */
- public static void nsourceUnqueueBuffers(int source, int nb, MemorySegment buffers) {
- try {
- alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Delete buffer objects
+ public static void alDeleteBuffers(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers) {
+ try {
+ Handles.MH_alDeleteBuffers.invokeExact(n, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteBuffers", e); }
}
- /**
- * Unqueue processed buffers from a source
- *
- * @param allocator the allocator of the buffers
- * @param source the source
- * @param buffers the buffers
- */
- public static void sourceUnqueueBuffers(SegmentAllocator allocator, int source, int[] buffers) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, buffers);
- nsourceUnqueueBuffers(source, buffers.length, seg);
- RuntimeHelper.toArray(seg, buffers);
- }
-
- /**
- * Create buffer objects.
- *
- * @param n the count of the objects.
- * @param buffers a buffer that retrieves the objects.
- */
- public static void ngenBuffers(int n, MemorySegment buffers) {
- try {
- alGenBuffers.invokeExact(n, buffers);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ ///Verify an ID is a valid buffer (including the NULL buffer)
+ public static @CType("ALboolean") boolean alIsBuffer(@CType("ALuint") int source) {
+ try {
+ return (boolean) Handles.MH_alIsBuffer.invokeExact(source);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsBuffer", e); }
}
- /**
- * Create buffer objects.
- *
- * @param allocator the allocator of the buffer.
- * @param buffers an array that retrieves the objects.
- * @see #ngenBuffers(int, MemorySegment) ngenBuffers
- */
- public static void genBuffers(SegmentAllocator allocator, int[] buffers) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, buffers.length);
- ngenBuffers(buffers.length, seg);
- RuntimeHelper.toArray(seg, buffers);
- }
-
- /**
- * Create a buffer object.
- *
- * @return the object.
- * @see #ngenBuffers(int, MemorySegment) ngenBuffers
- */
- public static int genBuffer() {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_INT);
- ngenBuffers(1, seg);
- return seg.get(JAVA_INT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ ///Copies data into the buffer, interpreting it using the specified format and
+ ///samplerate.
+ public static void alBufferData(@CType("ALuint") int buffer, @CType("ALenum") int format, @CType("const ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int size, @CType("ALsizei") int samplerate) {
+ try {
+ Handles.MH_alBufferData.invokeExact(buffer, format, data, size, samplerate);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferData", e); }
}
- /**
- * Delete buffer objects.
- *
- * @param n the count of the objects.
- * @param buffers the objects.
- */
- public static void ndeleteBuffers(int n, MemorySegment buffers) {
+ public static void alBufferf(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat") float value) {
try {
- alDeleteBuffers.invokeExact(n, buffers);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alBufferf.invokeExact(buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferf", e); }
}
- /**
- * Delete buffer objects.
- *
- * @param allocator the allocator of the buffer.
- * @param buffers the objects.
- * @see #ndeleteBuffers(int, MemorySegment) ndeleteBuffers
- */
- public static void deleteBuffers(SegmentAllocator allocator, int[] buffers) {
- ndeleteBuffers(buffers.length, allocator.allocateArray(JAVA_INT, buffers));
- }
-
- /**
- * Delete a buffer object.
- *
- * @param buffer the object.
- * @see #ndeleteBuffers(int, MemorySegment) ndeleteBuffers
- */
- public static void deleteBuffer(int buffer) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- ngenBuffers(1, stack.ints(buffer));
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alBuffer3f(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat") float value1, @CType("ALfloat") float value2, @CType("ALfloat") float value3) {
+ try {
+ Handles.MH_alBuffer3f.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alBuffer3f", e); }
}
- /**
- * Verify an ID is a valid buffer (including the NULL buffer).
- *
- * @param buffer an ID of a buffer
- * @return the result
- */
- public static boolean isBuffer(int buffer) {
+ public static void alBufferfv(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- return (boolean) alIsBuffer.invokeExact(buffer);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alBufferfv.invokeExact(buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferfv", e); }
}
- /**
- * Copies data into the buffer, interpreting it using the specified format and
- * sample-rate.
- *
- * @param buffer the buffer ID
- * @param format the data format
- * @param data the data
- * @param size the data size
- * @param sampleRate the sample-rate
- */
- public static void bufferData(int buffer, int format, MemorySegment data, int size, int sampleRate) {
- try {
- alBufferData.invokeExact(buffer, format, data, size, sampleRate);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ public static void alBufferi(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint") int value) {
+ try {
+ Handles.MH_alBufferi.invokeExact(buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferi", e); }
}
- public static void bufferf(int buffer, int param, float value) {
+ public static void alBuffer3i(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint") int value1, @CType("ALint") int value2, @CType("ALint") int value3) {
try {
- alBufferf.invokeExact(buffer, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alBuffer3i.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alBuffer3i", e); }
}
- public static void buffer3f(int buffer, int param, float value1, float value2, float value3) {
+ public static void alBufferiv(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment values) {
try {
- alBuffer3f.invokeExact(buffer, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alBufferiv.invokeExact(buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferiv", e); }
}
- public static void nbufferfv(int buffer, int param, MemorySegment values) {
+ public static void alGetBufferf(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value) {
try {
- alBufferfv.invokeExact(buffer, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetBufferf.invokeExact(buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferf", e); }
}
- public static void bufferfv(SegmentAllocator allocator, int buffer, int param, float[] values) {
- nbufferfv(buffer, param, allocator.allocateArray(JAVA_FLOAT, values));
+ public static void alGetBufferf(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALfloat *") float[] value) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value = Marshal.marshal(__overrungl_stack, value);
+ Handles.MH_alGetBufferf.invokeExact(buffer, param, __overrungl_ref_value);
+ Unmarshal.copy(__overrungl_ref_value, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferf", e); }
}
- public static void bufferi(int buffer, int param, int value) {
+ public static void alGetBuffer3f(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value1, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value2, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment value3) {
try {
- alBufferi.invokeExact(buffer, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetBuffer3f.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3f", e); }
}
- public static void buffer3i(int buffer, int param, int value1, int value2, int value3) {
- try {
- alBuffer3i.invokeExact(buffer, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ public static void alGetBuffer3f(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALfloat *") float[] value1, @Out @CType("ALfloat *") float[] value2, @Out @CType("ALfloat *") float[] value3) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value1 = Marshal.marshal(__overrungl_stack, value1);
+ var __overrungl_ref_value2 = Marshal.marshal(__overrungl_stack, value2);
+ var __overrungl_ref_value3 = Marshal.marshal(__overrungl_stack, value3);
+ Handles.MH_alGetBuffer3f.invokeExact(buffer, param, __overrungl_ref_value1, __overrungl_ref_value2, __overrungl_ref_value3);
+ Unmarshal.copy(__overrungl_ref_value1, value1);
+ Unmarshal.copy(__overrungl_ref_value2, value2);
+ Unmarshal.copy(__overrungl_ref_value3, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3f", e); }
}
- public static void nbufferiv(int buffer, int param, MemorySegment values) {
+ public static void alGetBufferfv(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
try {
- alBufferiv.invokeExact(buffer, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetBufferfv.invokeExact(buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferfv", e); }
}
- public static void bufferiv(SegmentAllocator allocator, int buffer, int param, int[] values) {
- nbufferiv(buffer, param, allocator.allocateArray(JAVA_INT, values));
+ public static void alGetBufferfv(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALfloat *") float[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetBufferfv.invokeExact(buffer, param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferfv", e); }
}
- public static void ngetBufferf(int buffer, int param, MemorySegment value) {
+ public static void alGetBufferi(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment value) {
try {
- alGetBufferf.invokeExact(buffer, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetBufferi.invokeExact(buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferi", e); }
}
- public static float getBufferf(int buffer, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_FLOAT);
- ngetBufferf(buffer, param, seg);
- return seg.get(JAVA_FLOAT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetBufferi(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALint *") int[] value) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value = Marshal.marshal(__overrungl_stack, value);
+ Handles.MH_alGetBufferi.invokeExact(buffer, param, __overrungl_ref_value);
+ Unmarshal.copy(__overrungl_ref_value, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferi", e); }
}
- public static void ngetBuffer3f(int buffer, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
+ public static void alGetBuffer3i(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment value1, @Out @CType("ALint *") java.lang.foreign.MemorySegment value2, @Out @CType("ALint *") java.lang.foreign.MemorySegment value3) {
try {
- alGetBuffer3f.invokeExact(buffer, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetBuffer3i.invokeExact(buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3i", e); }
}
- public static Triplet.OfFloat getBuffer3f(int buffer, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg1 = stack.calloc(JAVA_FLOAT);
- final MemorySegment seg2 = stack.calloc(JAVA_FLOAT);
- final MemorySegment seg3 = stack.calloc(JAVA_FLOAT);
- ngetBuffer3f(buffer, param, seg1, seg2, seg3);
- return new Triplet.OfFloat(seg1.get(JAVA_FLOAT, 0), seg2.get(JAVA_FLOAT, 0), seg3.get(JAVA_FLOAT, 0));
- } finally {
- stack.setPointer(stackPointer);
- }
+ public static void alGetBuffer3i(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALint *") int[] value1, @Out @CType("ALint *") int[] value2, @Out @CType("ALint *") int[] value3) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_value1 = Marshal.marshal(__overrungl_stack, value1);
+ var __overrungl_ref_value2 = Marshal.marshal(__overrungl_stack, value2);
+ var __overrungl_ref_value3 = Marshal.marshal(__overrungl_stack, value3);
+ Handles.MH_alGetBuffer3i.invokeExact(buffer, param, __overrungl_ref_value1, __overrungl_ref_value2, __overrungl_ref_value3);
+ Unmarshal.copy(__overrungl_ref_value1, value1);
+ Unmarshal.copy(__overrungl_ref_value2, value2);
+ Unmarshal.copy(__overrungl_ref_value3, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3i", e); }
}
- public static void ngetBufferfv(int buffer, int param, MemorySegment values) {
+ public static void alGetBufferiv(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALint *") java.lang.foreign.MemorySegment values) {
try {
- alGetBufferfv.invokeExact(buffer, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alGetBufferiv.invokeExact(buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferiv", e); }
}
- public static void getBufferfv(SegmentAllocator allocator, int buffer, int param, float[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_FLOAT, values.length);
- ngetBufferfv(buffer, param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alGetBufferiv(@CType("ALuint") int buffer, @CType("ALenum") int param, @Out @CType("ALint *") int[] values) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ var __overrungl_ref_values = Marshal.marshal(__overrungl_stack, values);
+ Handles.MH_alGetBufferiv.invokeExact(buffer, param, __overrungl_ref_values);
+ Unmarshal.copy(__overrungl_ref_values, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferiv", e); }
}
- public static void ngetBufferi(int buffer, int param, MemorySegment value) {
- try {
- alGetBufferi.invokeExact(buffer, param, value);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
- }
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
- public static float getBufferi(int buffer, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg = stack.calloc(JAVA_INT);
- ngetBufferi(buffer, param, seg);
- return seg.get(JAVA_INT, 0);
- } finally {
- stack.setPointer(stackPointer);
- }
+ private AL() {
}
- public static void ngetBuffer3i(int buffer, int param, MemorySegment value1, MemorySegment value2, MemorySegment value3) {
- try {
- alGetBuffer3i.invokeExact(buffer, param, value1, value2, value3);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
+ public static int alGenSources() {
+ try (var stack = MemoryStack.pushLocal()) {
+ var p = stack.ints(0);
+ alGenSources(1, p);
+ return p.get(ValueLayout.JAVA_INT, 0);
}
}
- public static Triplet.OfInt getBuffer3i(int buffer, int param) {
- final MemoryStack stack = MemoryStack.stackGet();
- final long stackPointer = stack.getPointer();
- try {
- final MemorySegment seg1 = stack.calloc(JAVA_INT);
- final MemorySegment seg2 = stack.calloc(JAVA_INT);
- final MemorySegment seg3 = stack.calloc(JAVA_INT);
- ngetBuffer3i(buffer, param, seg1, seg2, seg3);
- return new Triplet.OfInt(seg1.get(JAVA_INT, 0), seg2.get(JAVA_INT, 0), seg3.get(JAVA_INT, 0));
- } finally {
- stack.setPointer(stackPointer);
+ public static void alDeleteSources(int source) {
+ try (var stack = MemoryStack.pushLocal()) {
+ alDeleteSources(1, stack.ints(source));
}
}
- public static void ngetBufferiv(int buffer, int param, MemorySegment values) {
- try {
- alGetBufferiv.invokeExact(buffer, param, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
+ public static int alGenBuffers() {
+ try (var stack = MemoryStack.pushLocal()) {
+ var p = stack.ints(0);
+ alGenBuffers(1, p);
+ return p.get(ValueLayout.JAVA_INT, 0);
}
}
- public static void getBufferiv(SegmentAllocator allocator, int buffer, int param, int[] values) {
- final MemorySegment seg = allocator.allocateArray(JAVA_INT, values.length);
- ngetBufferiv(buffer, param, seg);
- RuntimeHelper.toArray(seg, values);
+ public static void alDeleteBuffers(int buffer) {
+ try (var stack = MemoryStack.pushLocal()) {
+ alDeleteBuffers(1, stack.ints(buffer));
+ }
}
}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
index 5fa23bed..e30b3e23 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
@@ -1,7 +1,7 @@
/*
* MIT License
*
- * Copyright (c) 2023 Overrun Organization
+ * Copyright (c) 2023-2025 Overrun Organization
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -16,13 +16,15 @@
package overrungl.openal;
+import overrungl.annotation.CType;
import overrungl.internal.RuntimeHelper;
+import overrungl.util.Marshal;
+import overrungl.util.MemoryStack;
+import overrungl.util.Unmarshal;
-import java.lang.foreign.MemorySegment;
-import java.lang.foreign.SegmentAllocator;
+import java.lang.foreign.FunctionDescriptor;
import java.lang.foreign.ValueLayout;
-
-import static overrungl.openal.Handles.*;
+import java.lang.invoke.MethodHandle;
/**
* The OpenAL context binding.
@@ -31,320 +33,314 @@
* @since 0.1.0
*/
public final class ALC {
- static {
- create();
- }
-
- /**
- * Boolean False.
- */
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ ///Boolean False.
public static final int ALC_FALSE = 0;
- /**
- * Boolean True.
- */
+ ///Boolean True.
public static final int ALC_TRUE = 1;
- /**
- * Context attribute: Hz.
- */
+ ///Context attribute: <int> Hz.
public static final int ALC_FREQUENCY = 0x1007;
- /**
- * Context attribute: Hz.
- */
+ ///Context attribute: <int> Hz.
public static final int ALC_REFRESH = 0x1008;
- /**
- * Context attribute: AL_TRUE or AL_FALSE synchronous context?
- */
+ ///Context attribute: AL_TRUE or AL_FALSE synchronous context?
public static final int ALC_SYNC = 0x1009;
- /**
- * Context attribute: requested Mono (3D) Sources.
- */
+ ///Context attribute: <int> requested Mono (3D) Sources.
public static final int ALC_MONO_SOURCES = 0x1010;
- /**
- * Context attribute: requested Stereo Sources.
- */
+ ///Context attribute: <int> requested Stereo Sources.
public static final int ALC_STEREO_SOURCES = 0x1011;
- /**
- * No error.
- */
+ ///No error.
public static final int ALC_NO_ERROR = 0;
- /**
- * Invalid device handle.
- */
+ ///Invalid device handle.
public static final int ALC_INVALID_DEVICE = 0xA001;
- /**
- * Invalid context handle.
- */
+ ///Invalid context handle.
public static final int ALC_INVALID_CONTEXT = 0xA002;
- /**
- * Invalid enumeration passed to an ALC call.
- */
+ ///Invalid enumeration passed to an ALC call.
public static final int ALC_INVALID_ENUM = 0xA003;
- /**
- * Invalid value passed to an ALC call.
- */
+ ///Invalid value passed to an ALC call.
public static final int ALC_INVALID_VALUE = 0xA004;
-
- /**
- * Out of memory.
- */
+ ///Out of memory.
public static final int ALC_OUT_OF_MEMORY = 0xA005;
- /**
- * Runtime ALC major version.
- */
+ ///Runtime ALC major version.
public static final int ALC_MAJOR_VERSION = 0x1000;
- /**
- * Runtime ALC minor version.
- */
+ ///Runtime ALC minor version.
public static final int ALC_MINOR_VERSION = 0x1001;
- /**
- * Context attribute list size.
- */
+ ///Context attribute list size.
public static final int ALC_ATTRIBUTES_SIZE = 0x1002;
- /**
- * Context attribute list properties.
- */
+ ///Context attribute list properties.
public static final int ALC_ALL_ATTRIBUTES = 0x1003;
- /**
- * String for the default device specifier.
- */
+ ///String for the default device specifier.
public static final int ALC_DEFAULT_DEVICE_SPECIFIER = 0x1004;
- /**
- * Device specifier string.
- *
- * If device handle is NULL, it is instead a null-character separated list of
- * strings of known device specifiers (list ends with an empty string).
- */
+ ///Device specifier string.
+ ///
+ ///If device handle is NULL, it is instead a null-character separated list of
+ ///strings of known device specifiers (list ends with an empty string).
public static final int ALC_DEVICE_SPECIFIER = 0x1005;
- /**
- * String for space-separated list of ALC extensions.
- */
+ ///String for space-separated list of ALC extensions.
public static final int ALC_EXTENSIONS = 0x1006;
- /**
- * Capture extension
- */
+ ///Capture extension
public static final int ALC_EXT_CAPTURE = 1;
- /**
- * Capture device specifier string.
- *
- * If device handle is NULL, it is instead a null-character separated list of
- * strings of known capture device specifiers (list ends with an empty string).
- */
+ ///Capture device specifier string.
+ ///
+ ///If device handle is NULL, it is instead a null-character separated list of
+ ///strings of known capture device specifiers (list ends with an empty string).
public static final int ALC_CAPTURE_DEVICE_SPECIFIER = 0x310;
- /**
- * String for the default capture device specifier.
- */
+ ///String for the default capture device specifier.
public static final int ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER = 0x311;
- /**
- * Number of sample frames available for capture.
- */
+ ///Number of sample frames available for capture.
public static final int ALC_CAPTURE_SAMPLES = 0x312;
- /**
- * Enumerate All extension
- */
+ ///Enumerate All extension
public static final int ALC_ENUMERATE_ALL_EXT = 1;
- /**
- * String for the default extended device specifier.
- */
+ ///String for the default extended device specifier.
public static final int ALC_DEFAULT_ALL_DEVICES_SPECIFIER = 0x1012;
- /**
- * Device's extended specifier string.
- *
- * If device handle is NULL, it is instead a null-character separated list of
- * strings of known extended device specifiers (list ends with an empty string).
- */
+ ///Device's extended specifier string.
+ ///
+ ///If device handle is NULL, it is instead a null-character separated list of
+ ///strings of known extended device specifiers (list ends with an empty string).
public static final int ALC_ALL_DEVICES_SPECIFIER = 0x1013;
-
- public static MemorySegment ncreateContext(MemorySegment device, MemorySegment attrlist) {
- try {
- return (MemorySegment) alcCreateContext.invokeExact(device, attrlist);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcCreateContext`.
+ public static final MethodHandle MH_alcCreateContext = RuntimeHelper.downcall(ALInternal.lookup(), "alcCreateContext", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alcMakeContextCurrent`.
+ public static final MethodHandle MH_alcMakeContextCurrent = RuntimeHelper.downcall(ALInternal.lookup(), "alcMakeContextCurrent", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS));
+ /// The method handle of `alcProcessContext`.
+ public static final MethodHandle MH_alcProcessContext = RuntimeHelper.downcall(ALInternal.lookup(), "alcProcessContext", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alcSuspendContext`.
+ public static final MethodHandle MH_alcSuspendContext = RuntimeHelper.downcall(ALInternal.lookup(), "alcSuspendContext", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alcDestroyContext`.
+ public static final MethodHandle MH_alcDestroyContext = RuntimeHelper.downcall(ALInternal.lookup(), "alcDestroyContext", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alcGetCurrentContext`.
+ public static final MethodHandle MH_alcGetCurrentContext = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetCurrentContext", FunctionDescriptor.of(ValueLayout.ADDRESS));
+ /// The method handle of `alcGetContextsDevice`.
+ public static final MethodHandle MH_alcGetContextsDevice = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetContextsDevice", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alcOpenDevice`.
+ public static final MethodHandle MH_alcOpenDevice = RuntimeHelper.downcall(ALInternal.lookup(), "alcOpenDevice", FunctionDescriptor.of(ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alcCloseDevice`.
+ public static final MethodHandle MH_alcCloseDevice = RuntimeHelper.downcall(ALInternal.lookup(), "alcCloseDevice", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS));
+ /// The method handle of `alcGetError`.
+ public static final MethodHandle MH_alcGetError = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetError", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alcIsExtensionPresent`.
+ public static final MethodHandle MH_alcIsExtensionPresent = RuntimeHelper.downcall(ALInternal.lookup(), "alcIsExtensionPresent", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alcGetProcAddress`.
+ public static final MethodHandle MH_alcGetProcAddress = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetProcAddress", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alcGetEnumValue`.
+ public static final MethodHandle MH_alcGetEnumValue = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetEnumValue", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alcGetString`.
+ public static final MethodHandle MH_alcGetString = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetString", FunctionDescriptor.of(Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alcGetIntegerv`.
+ public static final MethodHandle MH_alcGetIntegerv = RuntimeHelper.downcall(ALInternal.lookup(), "alcGetIntegerv", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alcCaptureOpenDevice`.
+ public static final MethodHandle MH_alcCaptureOpenDevice = RuntimeHelper.downcall(ALInternal.lookup(), "alcCaptureOpenDevice", FunctionDescriptor.of(ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alcCaptureCloseDevice`.
+ public static final MethodHandle MH_alcCaptureCloseDevice = RuntimeHelper.downcall(ALInternal.lookup(), "alcCaptureCloseDevice", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS));
+ /// The method handle of `alcCaptureStart`.
+ public static final MethodHandle MH_alcCaptureStart = RuntimeHelper.downcall(ALInternal.lookup(), "alcCaptureStart", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alcCaptureStop`.
+ public static final MethodHandle MH_alcCaptureStop = RuntimeHelper.downcall(ALInternal.lookup(), "alcCaptureStop", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alcCaptureSamples`.
+ public static final MethodHandle MH_alcCaptureSamples = RuntimeHelper.downcall(ALInternal.lookup(), "alcCaptureSamples", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
}
+ //endregion
- public static MemorySegment createContext(SegmentAllocator allocator, MemorySegment device, int[] attrlist) {
- return ncreateContext(device, allocator.allocateArray(ValueLayout.JAVA_INT, attrlist));
+ ///Create and attach a context to the given device.
+ public static @CType("ALCcontext *") java.lang.foreign.MemorySegment alcCreateContext(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCint *") java.lang.foreign.MemorySegment attrlist) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcCreateContext.invokeExact(device, attrlist);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCreateContext", e); }
}
- public static boolean makeContextCurrent(MemorySegment context) {
+ ///Makes the given context the active process-wide context. Passing NULL clears
+ ///the active context.
+ public static @CType("ALCboolean") boolean alcMakeContextCurrent(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
- return (boolean) alcMakeContextCurrent.invokeExact(context);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alcMakeContextCurrent.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alcMakeContextCurrent", e); }
}
- public static void processContext(MemorySegment context) {
+ ///Resumes processing updates for the given context.
+ public static void alcProcessContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
- alcProcessContext.invokeExact(context);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alcProcessContext.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alcProcessContext", e); }
}
- public static void suspendContext(MemorySegment context) {
+ ///Suspends updates for the given context.
+ public static void alcSuspendContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
- alcSuspendContext.invokeExact(context);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alcSuspendContext.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alcSuspendContext", e); }
}
- public static void destroyContext(MemorySegment context) {
+ ///Remove a context from its device and destroys it.
+ public static void alcDestroyContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
- alcDestroyContext.invokeExact(context);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alcDestroyContext.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alcDestroyContext", e); }
}
- public static MemorySegment getCurrentContext() {
+ ///Returns the currently active context.
+ public static @CType("ALCcontext *") java.lang.foreign.MemorySegment alcGetCurrentContext() {
try {
- return (MemorySegment) alcGetCurrentContext.invokeExact();
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetCurrentContext.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetCurrentContext", e); }
}
- public static MemorySegment getContextsDevice(MemorySegment context) {
+ ///Returns the device that a particular context is attached to.
+ public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcGetContextsDevice(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
- return (MemorySegment) alcGetContextsDevice.invokeExact(context);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetContextsDevice.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetContextsDevice", e); }
}
- public static MemorySegment nopenDevice(MemorySegment deviceName) {
+ ///Opens the named playback device.
+ public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcOpenDevice(@CType("const ALCchar*") java.lang.foreign.MemorySegment devicename) {
try {
- return (MemorySegment) alcOpenDevice.invokeExact(deviceName);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcOpenDevice.invokeExact(devicename);
+ } catch (Throwable e) { throw new RuntimeException("error in alcOpenDevice", e); }
}
- public static MemorySegment openDevice(SegmentAllocator allocator, String deviceName) {
- return nopenDevice(allocator.allocateUtf8String(deviceName));
+ ///Opens the named playback device.
+ public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcOpenDevice(@CType("const ALCchar*") java.lang.String devicename) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcOpenDevice.invokeExact(Marshal.marshal(__overrungl_stack, devicename));
+ } catch (Throwable e) { throw new RuntimeException("error in alcOpenDevice", e); }
}
- public static boolean closeDevice(MemorySegment device) {
+ ///Closes the given playback device.
+ public static @CType("ALCboolean") boolean alcCloseDevice(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
- return (boolean) alcCloseDevice.invokeExact(device);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alcCloseDevice.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCloseDevice", e); }
}
- public static int getError(MemorySegment device) {
+ ///Obtain the most recent Device error.
+ public static @CType("ALCenum") int alcGetError(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
- return (int) alcGetError.invokeExact(device);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (int) Handles.MH_alcGetError.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetError", e); }
}
- public static boolean nisExtensionPresent(MemorySegment device, MemorySegment extName) {
+ ///Query for the presence of an extension on the device. Pass a NULL device to
+ ///query a device-inspecific extension.
+ public static @CType("ALCboolean") boolean alcIsExtensionPresent(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment extname) {
try {
- return (boolean) alcIsExtensionPresent.invokeExact(device, extName);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alcIsExtensionPresent.invokeExact(device, extname);
+ } catch (Throwable e) { throw new RuntimeException("error in alcIsExtensionPresent", e); }
}
- public static boolean isExtensionPresent(SegmentAllocator allocator, MemorySegment device, String extName) {
- return nisExtensionPresent(device, allocator.allocateUtf8String(extName));
+ ///Query for the presence of an extension on the device. Pass a NULL device to
+ ///query a device-inspecific extension.
+ public static @CType("ALCboolean") boolean alcIsExtensionPresent(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.String extname) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (boolean) Handles.MH_alcIsExtensionPresent.invokeExact(device, Marshal.marshal(__overrungl_stack, extname));
+ } catch (Throwable e) { throw new RuntimeException("error in alcIsExtensionPresent", e); }
}
- public static MemorySegment ngetProcAddress(MemorySegment device, MemorySegment funcName) {
+ ///Retrieve the address of a function. Given a non-NULL device, the returned
+ ///function may be device-specific.
+ public static @CType("ALCvoid *") java.lang.foreign.MemorySegment alcGetProcAddress(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment funcname) {
try {
- return (MemorySegment) alcGetProcAddress.invokeExact(device, funcName);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetProcAddress.invokeExact(device, funcname);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetProcAddress", e); }
}
- public static MemorySegment getProcAddress(SegmentAllocator allocator, MemorySegment device, String funcName) {
- return ngetProcAddress(device, allocator.allocateUtf8String(funcName));
+ ///Retrieve the address of a function. Given a non-NULL device, the returned
+ ///function may be device-specific.
+ public static @CType("ALCvoid *") java.lang.foreign.MemorySegment alcGetProcAddress(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.String funcname) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetProcAddress.invokeExact(device, Marshal.marshal(__overrungl_stack, funcname));
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetProcAddress", e); }
}
- public static int ngetEnumValue(MemorySegment device, MemorySegment enumName) {
+ ///Retrieve the value of an enum. Given a non-NULL device, the returned value
+ ///may be device-specific.
+ public static @CType("ALCenum") int alcGetEnumValue(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment enumname) {
try {
- return (int) alcGetEnumValue.invokeExact(device, enumName);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (int) Handles.MH_alcGetEnumValue.invokeExact(device, enumname);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetEnumValue", e); }
}
- public static int getEnumValue(SegmentAllocator allocator, MemorySegment device, String enumName) {
- return ngetEnumValue(device, allocator.allocateUtf8String(enumName));
+ ///Retrieve the value of an enum. Given a non-NULL device, the returned value
+ ///may be device-specific.
+ public static @CType("ALCenum") int alcGetEnumValue(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.String enumname) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (int) Handles.MH_alcGetEnumValue.invokeExact(device, Marshal.marshal(__overrungl_stack, enumname));
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetEnumValue", e); }
}
- public static MemorySegment ngetString(MemorySegment device, int param) {
+ ///Returns information about the device, and error strings.
+ public static @CType("const ALCchar*") java.lang.foreign.MemorySegment alcGetString_(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int param) {
try {
- return (MemorySegment) alcGetString.invokeExact(device, param);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetString.invokeExact(device, param);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetString", e); }
}
- public static String getString(MemorySegment device, int param) {
- return ngetString(device, param).getUtf8String(0);
- }
-
- public static void ngetIntegerv(MemorySegment device, int param, int size, MemorySegment values) {
+ ///Returns information about the device, and error strings.
+ public static @CType("const ALCchar*") java.lang.String alcGetString(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int param) {
try {
- alcGetIntegerv.invokeExact(device, param, size, values);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return Unmarshal.unmarshalAsString((java.lang.foreign.MemorySegment) Handles.MH_alcGetString.invokeExact(device, param));
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetString", e); }
}
- public static void getIntegerv(SegmentAllocator allocator, MemorySegment device, int param, int[] values) {
- final MemorySegment seg = allocator.allocateArray(ValueLayout.JAVA_INT, values.length);
- ngetIntegerv(device, param, values.length, seg);
- RuntimeHelper.toArray(seg, values);
+ ///Returns information about the device and the version of OpenAL.
+ public static void alcGetIntegerv(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int param, @CType("ALCsizei") int size, @CType("ALCint *") java.lang.foreign.MemorySegment values) {
+ try {
+ Handles.MH_alcGetIntegerv.invokeExact(device, param, size, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetIntegerv", e); }
}
- public static MemorySegment ncaptureOpenDevice(MemorySegment deviceName, int frequency, int format, int bufferSize) {
+ ///Opens the named capture device with the given frequency, format, and buffer
+ ///size.
+ public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcCaptureOpenDevice(@CType("const ALCchar*") java.lang.foreign.MemorySegment devicename, @CType("ALCuint") int frequency, @CType("ALCenum") int format, @CType("ALCsizei") int buffersize) {
try {
- return (MemorySegment) alcCaptureOpenDevice.invokeExact(deviceName, frequency, format, bufferSize);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcCaptureOpenDevice.invokeExact(devicename, frequency, format, buffersize);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCaptureOpenDevice", e); }
}
- public static MemorySegment captureOpenDevice(SegmentAllocator allocator, String deviceName, int frequency, int format, int bufferSize) {
- return ncaptureOpenDevice(allocator.allocateUtf8String(deviceName), frequency, format, bufferSize);
+ ///Opens the named capture device with the given frequency, format, and buffer
+ ///size.
+ public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcCaptureOpenDevice(@CType("const ALCchar*") java.lang.String devicename, @CType("ALCuint") int frequency, @CType("ALCenum") int format, @CType("ALCsizei") int buffersize) {
+ try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcCaptureOpenDevice.invokeExact(Marshal.marshal(__overrungl_stack, devicename), frequency, format, buffersize);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCaptureOpenDevice", e); }
}
- public static boolean captureCloseDevice(MemorySegment device) {
+ ///Closes the given capture device.
+ public static @CType("ALCboolean") boolean alcCaptureCloseDevice(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
- return (boolean) alcCaptureCloseDevice.invokeExact(device);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ return (boolean) Handles.MH_alcCaptureCloseDevice.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCaptureCloseDevice", e); }
}
- public static void captureStart(MemorySegment device) {
+ ///Starts capturing samples into the device buffer.
+ public static void alcCaptureStart(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
- alcCaptureStart.invokeExact(device);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alcCaptureStart.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCaptureStart", e); }
}
- public static void captureStop(MemorySegment device) {
+ ///Stops capturing samples. Samples in the device buffer remain available.
+ public static void alcCaptureStop(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
- alcCaptureStop.invokeExact(device);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alcCaptureStop.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCaptureStop", e); }
}
- public static void captureSamples(MemorySegment device, MemorySegment buffer, int samples) {
+ ///Reads samples from the device buffer.
+ public static void alcCaptureSamples(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCvoid *") java.lang.foreign.MemorySegment buffer, @CType("ALCsizei") int samples) {
try {
- alcCaptureSamples.invokeExact(device, buffer, samples);
- } catch (Throwable e) {
- throw new AssertionError("should not reach here", e);
- }
+ Handles.MH_alcCaptureSamples.invokeExact(device, buffer, samples);
+ } catch (Throwable e) { throw new RuntimeException("error in alcCaptureSamples", e); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALC() {
}
}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALInternal.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALInternal.java
new file mode 100644
index 00000000..2038da35
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALInternal.java
@@ -0,0 +1,50 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.openal;
+
+import overrungl.OverrunGL;
+import overrungl.OverrunGLConfigurations;
+import overrungl.internal.RuntimeHelper;
+
+import java.lang.foreign.SymbolLookup;
+import java.util.function.Supplier;
+
+/**
+ * OpenAL internal
+ *
+ * @author squid233
+ * @since 0.1.0
+ */
+final class ALInternal {
+ private static volatile SymbolLookup lookup;
+
+ private ALInternal() {
+ }
+
+ static SymbolLookup lookup() {
+ if (lookup == null) {
+ synchronized (ALInternal.class) {
+ if (lookup == null) {
+ Supplier lib = () -> RuntimeHelper.load("openal", "openal", OverrunGL.OPENAL_VERSION);
+ var function = OverrunGLConfigurations.OPENAL_SYMBOL_LOOKUP.get();
+ lookup = function != null ? function.apply(lib) : lib.get();
+ }
+ }
+ }
+ return lookup;
+ }
+}
diff --git a/settings.gradle.kts b/settings.gradle.kts
index 68410deb..e9d50c89 100644
--- a/settings.gradle.kts
+++ b/settings.gradle.kts
@@ -1,3 +1,19 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
pluginManagement {
repositories {
mavenCentral()
@@ -21,6 +37,7 @@ include(
"generators:core",
"generators:glfw",
"generators:nfd",
+ "generators:openal",
"generators:opengl",
"generators:stb",
"generators:vulkan"
From ad94531f927cc0a6cfc7edc89f01bcf3bd26e19b Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Sun, 5 Jan 2025 18:49:58 +0800
Subject: [PATCH 09/11] feat(api): [openal] remove Handles.java
---
.../main/java/overrungl/openal/Handles.java | 176 ------------------
1 file changed, 176 deletions(-)
delete mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java b/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
deleted file mode 100644
index 0fbef737..00000000
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/Handles.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * MIT License
- *
- * Copyright (c) 2023 Overrun Organization
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in all
- * copies or substantial portions of the Software.
- */
-
-package overrungl.openal;
-
-import overrungl.FunctionDescriptors;
-import overrungl.OverrunGL;
-import overrungl.internal.RuntimeHelper;
-
-import java.lang.foreign.FunctionDescriptor;
-import java.lang.foreign.SymbolLookup;
-import java.lang.invoke.MethodHandle;
-
-import static overrungl.FunctionDescriptors.*;
-
-/**
- * The OpenAL method handles.
- *
- * @author squid233
- * @since 0.1.0
- */
-final class Handles {
- private static boolean initialized;
- static SymbolLookup lookup;
- /**
- * AL
- */
- static MethodHandle
- alEnable, alDisable, alIsEnabled, alDopplerFactor, alDopplerVelocity, alSpeedOfSound, alDistanceModel, alGetString,
- alGetBooleanv, alGetIntegerv, alGetFloatv, alGetDoublev, alGetBoolean, alGetInteger, alGetFloat, alGetDouble, alGetError,
- alIsExtensionPresent, alGetProcAddress, alGetEnumValue, alListenerf, alListener3f, alListenerfv, alListeneri, alListener3i,
- alListeneriv, alGetListenerf, alGetListener3f, alGetListenerfv, alGetListeneri, alGetListener3i, alGetListeneriv,
- alGenSources, alDeleteSources, alIsSource, alSourcef, alSource3f, alSourcefv, alSourcei, alSource3i, alSourceiv,
- alGetSourcef, alGetSource3f, alGetSourcefv, alGetSourcei, alGetSource3i, alGetSourceiv, alSourcePlay, alSourceStop,
- alSourceRewind, alSourcePause, alSourcePlayv, alSourceStopv, alSourceRewindv, alSourcePausev, alSourceQueueBuffers,
- alSourceUnqueueBuffers, alGenBuffers, alDeleteBuffers, alIsBuffer, alBufferData, alBufferf, alBuffer3f, alBufferfv,
- alBufferi, alBuffer3i, alBufferiv, alGetBufferf, alGetBuffer3f, alGetBufferfv, alGetBufferi, alGetBuffer3i, alGetBufferiv;
- /**
- * ALC
- */
- static MethodHandle
- alcCreateContext, alcMakeContextCurrent, alcProcessContext, alcSuspendContext, alcDestroyContext, alcGetCurrentContext,
- alcGetContextsDevice, alcOpenDevice, alcCloseDevice, alcGetError, alcIsExtensionPresent, alcGetProcAddress, alcGetEnumValue,
- alcGetString, alcGetIntegerv, alcCaptureOpenDevice, alcCaptureCloseDevice, alcCaptureStart, alcCaptureStop, alcCaptureSamples;
-
- private static MethodHandle downcall(String name,
- FunctionDescriptor function) {
- return RuntimeHelper.downcallThrow(lookup.find(name), function);
- }
-
- private static MethodHandle downcall(String name,
- FunctionDescriptors function) {
- return RuntimeHelper.downcallThrow(lookup.find(name), function);
- }
-
- private static void createAL() {
- alEnable = downcall("alEnable", IV);
- alDisable = downcall("alDisable", IV);
- alIsEnabled = downcall("alIsEnabled", IZ);
- alDopplerFactor = downcall("alDopplerFactor", FV);
- alDopplerVelocity = downcall("alDopplerVelocity", FV);
- alSpeedOfSound = downcall("alSpeedOfSound", FV);
- alDistanceModel = downcall("alDistanceModel", IV);
- alGetString = downcall("alGetString", Ip);
- alGetBooleanv = downcall("alGetBooleanv", IPV);
- alGetIntegerv = downcall("alGetIntegerv", IPV);
- alGetFloatv = downcall("alGetFloatv", IPV);
- alGetDoublev = downcall("alGetDoublev", IPV);
- alGetBoolean = downcall("alGetBoolean", IZ);
- alGetInteger = downcall("alGetInteger", II);
- alGetFloat = downcall("alGetFloat", IF);
- alGetDouble = downcall("alGetDouble", ID);
- alGetError = downcall("alGetError", I);
- alIsExtensionPresent = downcall("alIsExtensionPresent", PZ);
- alGetProcAddress = downcall("alGetProcAddress", PP);
- alGetEnumValue = downcall("alGetEnumValue", fd_PI);
- alListenerf = downcall("alListenerf", IFV);
- alListener3f = downcall("alListener3f", IFFFV);
- alListenerfv = downcall("alListenerfv", IPV);
- alListeneri = downcall("alListeneri", IIV);
- alListener3i = downcall("alListener3i", IIIIV);
- alListeneriv = downcall("alListeneriv", IPV);
- alGetListenerf = downcall("alGetListenerf", IPV);
- alGetListener3f = downcall("alGetListener3f", IPPPV);
- alGetListenerfv = downcall("alGetListenerfv", IPV);
- alGetListeneri = downcall("alGetListeneri", IPV);
- alGetListener3i = downcall("alGetListener3i", IPPPV);
- alGetListeneriv = downcall("alGetListeneriv", IPV);
- alGenSources = downcall("alGenSources", IPV);
- alDeleteSources = downcall("alDeleteSources", IPV);
- alIsSource = downcall("alIsSource", IZ);
- alSourcef = downcall("alSourcef", IIFV);
- alSource3f = downcall("alSource3f", IIFFFV);
- alSourcefv = downcall("alSourcefv", IIPV);
- alSourcei = downcall("alSourcei", IIIV);
- alSource3i = downcall("alSource3i", IIIIIV);
- alSourceiv = downcall("alSourceiv", IIPV);
- alGetSourcef = downcall("alGetSourcef", IIPV);
- alGetSource3f = downcall("alGetSource3f", IIPPPV);
- alGetSourcefv = downcall("alGetSourcefv", IIPV);
- alGetSourcei = downcall("alGetSourcei", IIPV);
- alGetSource3i = downcall("alGetSource3i", IIPPPV);
- alGetSourceiv = downcall("alGetSourceiv", IIPV);
- alSourcePlay = downcall("alSourcePlay", IV);
- alSourceStop = downcall("alSourceStop", IV);
- alSourceRewind = downcall("alSourceRewind", IV);
- alSourcePause = downcall("alSourcePause", IV);
- alSourcePlayv = downcall("alSourcePlayv", IPV);
- alSourceStopv = downcall("alSourceStopv", IPV);
- alSourceRewindv = downcall("alSourceRewindv", IPV);
- alSourcePausev = downcall("alSourcePausev", IPV);
- alSourceQueueBuffers = downcall("alSourceQueueBuffers", IIPV);
- alSourceUnqueueBuffers = downcall("alSourceUnqueueBuffers", IIPV);
- alGenBuffers = downcall("alGenBuffers", IPV);
- alDeleteBuffers = downcall("alDeleteBuffers", IPV);
- alIsBuffer = downcall("alIsBuffer", IZ);
- alBufferData = downcall("alBufferData", IIPIIV);
- alBufferf = downcall("alBufferf", IIFV);
- alBuffer3f = downcall("alBuffer3f", IIFFFV);
- alBufferfv = downcall("alBufferfv", IIPV);
- alBufferi = downcall("alBufferi", IIIV);
- alBuffer3i = downcall("alBuffer3i", IIIIIV);
- alBufferiv = downcall("alBufferiv", IIPV);
- alGetBufferf = downcall("alGetBufferf", IIPV);
- alGetBuffer3f = downcall("alGetBuffer3f", IIPPPV);
- alGetBufferfv = downcall("alGetBufferfv", IIPV);
- alGetBufferi = downcall("alGetBufferi", IIPV);
- alGetBuffer3i = downcall("alGetBuffer3i", IIPPPV);
- alGetBufferiv = downcall("alGetBufferiv", IIPV);
- }
-
- private static void createALC() {
- alcCreateContext = downcall("alcCreateContext", PPP);
- alcMakeContextCurrent = downcall("alcMakeContextCurrent", PZ);
- alcProcessContext = downcall("alcProcessContext", PV);
- alcSuspendContext = downcall("alcSuspendContext", PV);
- alcDestroyContext = downcall("alcDestroyContext", PV);
- alcGetCurrentContext = downcall("alcGetCurrentContext", P);
- alcGetContextsDevice = downcall("alcGetContextsDevice", PP);
- alcOpenDevice = downcall("alcOpenDevice", PP);
- alcCloseDevice = downcall("alcCloseDevice", PZ);
- alcGetError = downcall("alcGetError", fd_PI);
- alcIsExtensionPresent = downcall("alcIsExtensionPresent", PPZ);
- alcGetProcAddress = downcall("alcGetProcAddress", PPP);
- alcGetEnumValue = downcall("alcGetEnumValue", PPI);
- alcGetString = downcall("alcGetString", PIp);
- alcGetIntegerv = downcall("alcGetIntegerv", PIIPV);
- alcCaptureOpenDevice = downcall("alcCaptureOpenDevice", PIIIP);
- alcCaptureCloseDevice = downcall("alcCaptureCloseDevice", PZ);
- alcCaptureStart = downcall("alcCaptureStart", PV);
- alcCaptureStop = downcall("alcCaptureStop", PV);
- alcCaptureSamples = downcall("alcCaptureSamples", PPIV);
- }
-
- static void create() {
- if (initialized) return;
- initialized = true;
-
- lookup = RuntimeHelper.load("openal", "openal", OverrunGL.VERSION);
- createAL();
- createALC();
- }
-}
From 51ea4121160a55b1b2837c820a5dc326e753076e Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Tue, 7 Jan 2025 17:00:11 +0800
Subject: [PATCH 10/11] feat(api): [openal] add extensions; [generator] throw
error for not-found optional functions
---
CONTRIBUTING.md | 2 +-
doc/notes/0.x/0.1.0.md | 2 +-
.../src/main/kotlin/overrungl/openal/AL.kt | 470 +---
.../src/main/kotlin/overrungl/openal/ALC.kt | 163 +-
.../src/main/kotlin/overrungl/openal/ALExt.kt | 2215 +++++++++++++++++
.../src/main/kotlin/overrungl/openal/EFX.kt | 855 +++++++
.../overrungl/openal/OpenALGenerator.kt | 26 +
.../overrungl/opengl/OpenGLGenerator.kt | 2 +-
.../kotlin/overrungl/gen/CustomTypeSpec.kt | 2 +
.../kotlin/overrungl/gen/StaticDowncall.kt | 304 +--
.../src/main/java/module-info.java | 1 +
.../overrungl/util/SymbolNotFoundError.java | 37 +
.../src/main/java/module-info.java | 29 +
.../src/main/java/overrungl/openal/AL.java | 244 +-
.../openal/ALBufferCallbackTypeSOFT.java | 53 +
.../src/main/java/overrungl/openal/ALC.java | 70 -
.../overrungl/openal/ALCEXTDEDICATED.java | 32 +
.../openal/ALCEXTDEFAULTFILTERORDER.java | 30 +
.../java/overrungl/openal/ALCEXTDebug.java | 31 +
.../overrungl/openal/ALCEXTDisconnect.java | 30 +
.../main/java/overrungl/openal/ALCEXTEFX.java | 848 +++++++
.../openal/ALCEXTThreadLocalContext.java | 61 +
.../openal/ALCEventProcTypeSOFT.java | 54 +
.../overrungl/openal/ALCLOKIAudioChannel.java | 32 +
.../overrungl/openal/ALCSOFTDeviceClock.java | 56 +
.../java/overrungl/openal/ALCSOFTHRTF.java | 73 +
.../overrungl/openal/ALCSOFTLoopback.java | 86 +
.../openal/ALCSOFTLoopbackBformat.java | 38 +
.../openal/ALCSOFTOutputLimiter.java | 30 +
.../overrungl/openal/ALCSOFTOutputMode.java | 37 +
.../overrungl/openal/ALCSOFTPauseDevice.java | 61 +
.../overrungl/openal/ALCSOFTReopenDevice.java | 51 +
.../overrungl/openal/ALCSOFTSystemEvents.java | 78 +
.../java/overrungl/openal/ALDebugProcEXT.java | 54 +
.../main/java/overrungl/openal/ALEXTALAW.java | 31 +
.../java/overrungl/openal/ALEXTBFORMAT.java | 35 +
.../java/overrungl/openal/ALEXTDebug.java | 177 ++
.../overrungl/openal/ALEXTDirectContext.java | 1531 ++++++++++++
.../java/overrungl/openal/ALEXTDouble.java | 31 +
.../java/overrungl/openal/ALEXTFOLDBACK.java | 67 +
.../java/overrungl/openal/ALEXTFloat32.java | 31 +
.../main/java/overrungl/openal/ALEXTIMA4.java | 31 +
.../java/overrungl/openal/ALEXTMCFORMATS.java | 44 +
.../java/overrungl/openal/ALEXTMULAW.java | 31 +
.../overrungl/openal/ALEXTMULAWBFORMAT.java | 31 +
.../overrungl/openal/ALEXTMULAWMCFORMATS.java | 36 +
.../overrungl/openal/ALEXTSOURCERADIUS.java | 30 +
.../overrungl/openal/ALEXTSTATICBUFFER.java | 51 +
.../overrungl/openal/ALEXTSTEREOANGLES.java | 30 +
.../openal/ALEXTSourceDistanceModel.java | 30 +
.../java/overrungl/openal/ALEXTVorbis.java | 30 +
.../overrungl/openal/ALEventProcSOFT.java | 54 +
.../overrungl/openal/ALFoldbackCallback.java | 53 +
.../openal/ALLOKIIMAADPCMFormat.java | 31 +
.../overrungl/openal/ALLOKIQuadriphonic.java | 31 +
.../overrungl/openal/ALLOKIWAVEFormat.java | 30 +
.../overrungl/openal/ALSOFTBformatEx.java | 35 +
.../overrungl/openal/ALSOFTBformatHoa.java | 30 +
.../openal/ALSOFTBlockAlignment.java | 31 +
.../overrungl/openal/ALSOFTBufferSamples.java | 123 +
.../overrungl/openal/ALSOFTBufferSubData.java | 53 +
.../openal/ALSOFTCallbackBuffer.java | 83 +
.../openal/ALSOFTDeferredUpdates.java | 62 +
.../openal/ALSOFTDirectChannels.java | 30 +
.../openal/ALSOFTDirectChannelsRemix.java | 31 +
.../overrungl/openal/ALSOFTEffectTarget.java | 30 +
.../java/overrungl/openal/ALSOFTEvents.java | 86 +
.../overrungl/openal/ALSOFTGainClampEx.java | 30 +
.../overrungl/openal/ALSOFTLoopPoints.java | 30 +
.../java/overrungl/openal/ALSOFTMSADPCM.java | 31 +
.../overrungl/openal/ALSOFTSourceLatency.java | 163 ++
.../openal/ALSOFTSourceResampler.java | 55 +
.../openal/ALSOFTSourceSpatialize.java | 31 +
.../openal/ALSOFTSourceStartDelay.java | 61 +
.../main/java/overrungl/openal/ALSOFTUHJ.java | 42 +
.../java/overrungl/openal/ALSOFTUHJEx.java | 37 +
76 files changed, 8715 insertions(+), 962 deletions(-)
create mode 100644 generators/openal/src/main/kotlin/overrungl/openal/ALExt.kt
create mode 100644 generators/openal/src/main/kotlin/overrungl/openal/EFX.kt
create mode 100644 modules/overrungl.core/src/main/java/overrungl/util/SymbolNotFoundError.java
create mode 100644 modules/overrungl.openal/src/main/java/module-info.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALBufferCallbackTypeSOFT.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEDICATED.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEFAULTFILTERORDER.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDebug.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDisconnect.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTEFX.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTThreadLocalContext.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCLOKIAudioChannel.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTDeviceClock.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTHRTF.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopback.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopbackBformat.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputLimiter.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputMode.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTPauseDevice.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTReopenDevice.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTSystemEvents.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTALAW.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTBFORMAT.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDebug.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDirectContext.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDouble.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFOLDBACK.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFloat32.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTIMA4.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMCFORMATS.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAW.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWBFORMAT.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWMCFORMATS.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSOURCERADIUS.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTATICBUFFER.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTEREOANGLES.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSourceDistanceModel.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTVorbis.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALFoldbackCallback.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIIMAADPCMFormat.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIQuadriphonic.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIWAVEFormat.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatEx.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatHoa.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBlockAlignment.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSamples.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSubData.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTCallbackBuffer.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDeferredUpdates.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannels.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannelsRemix.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEffectTarget.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEvents.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTGainClampEx.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTLoopPoints.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTMSADPCM.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceLatency.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceResampler.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceSpatialize.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceStartDelay.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJ.java
create mode 100644 modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJEx.java
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 1d44c8be..455bd84d 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -37,7 +37,7 @@ The formatted code:
*/
```
;
-- The class names **MUST** be CamelCase;
+- The class names **MUST** be CamelCase except for generated sources;
- The method and field names _should_ be camelCase; this restriction can be widened for non-public APIs;
- Other rules specified in [.editorconfig](.editorconfig).
diff --git a/doc/notes/0.x/0.1.0.md b/doc/notes/0.x/0.1.0.md
index 5c46c687..4d663ccf 100644
--- a/doc/notes/0.x/0.1.0.md
+++ b/doc/notes/0.x/0.1.0.md
@@ -9,4 +9,4 @@ This version includes the following features:
- stb features introduced in README
- Native memory access for JOML
- Native File Dialog Extended
-- OpenAL
+- OpenAL and extensions
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/AL.kt b/generators/openal/src/main/kotlin/overrungl/openal/AL.kt
index 4703445e..18a50038 100644
--- a/generators/openal/src/main/kotlin/overrungl/openal/AL.kt
+++ b/generators/openal/src/main/kotlin/overrungl/openal/AL.kt
@@ -23,372 +23,84 @@ import overrungl.gen.void_ptr
fun AL() {
StaticDowncall(alPackage, "AL", alLookup) {
//region fields
- ALenum("AL_NONE" to "0", "No distance model or no buffer")
- ALenum("AL_FALSE" to "0", "Boolean False.")
- ALenum("AL_TRUE" to "1", "Boolean True.")
-
- ALenum(
- "AL_SOURCE_RELATIVE" to "0x202",
- """
- Relative source.
- - Type: ALboolean
- - Range: \[AL_FALSE, AL_TRUE\]
- - Default: AL_FALSE
-
- Specifies if the source uses relative coordinates.
- """.trimIndent()
- )
- ALenum(
- "AL_CONE_INNER_ANGLE" to "0x1001",
- """
- Inner cone angle, in degrees.
- - Type: ALint, ALfloat
- - Range: \[0 - 360\]
- - Default: 360
-
- The angle covered by the inner cone, the area within which the source will
- not be attenuated by direction.
- """.trimIndent()
- )
- ALenum(
- "AL_CONE_OUTER_ANGLE" to "0x1002",
- """
- Outer cone angle, in degrees.
- - Range: \[0 - 360\]
- - Default: 360
-
- The angle covered by the outer cone, the area outside of which the source
- will be fully attenuated by direction.
- """.trimIndent()
- )
- ALenum(
- "AL_PITCH" to "0x1003",
- """
- Source pitch.
- - Type: ALfloat
- - Range: \[0.5 - 2.0\]
- - Default: 1.0
-
- A multiplier for the sample rate of the source's buffer.
- """.trimIndent()
- )
- ALenum(
- "AL_POSITION" to "0x1004",
- """
- Source or listener position.
- - Type: ALfloat\[3\], ALint\[3\]
- - Default: {0, 0, 0}
-
- The source or listener location in three dimensional space.
-
- OpenAL uses a right handed coordinate system, like OpenGL, where with a
- default view, X points right (thumb), Y points up (index finger), and Z
- points towards the viewer/camera (middle finger).
-
- To change from or to a left handed coordinate system, negate the Z
- component.
- """.trimIndent()
- )
- ALenum(
- "AL_DIRECTION" to "0x1005",
- """
- Source direction.
- - Type: ALfloat\[3\], ALint\[3\]
- - Default: {0, 0, 0}
-
- Specifies the current direction in local space. A zero-length vector
- specifies an omni-directional source (cone is ignored).
-
- To change from or to a left handed coordinate system, negate the Z
- component.
- """.trimIndent()
- )
- ALenum(
- "AL_VELOCITY" to "0x1006",
- """
- Source or listener velocity.
- - Type: ALfloat\[3\], ALint\[3]\
- - Default: {0, 0, 0}
-
- Specifies the current velocity, relative to the position.
-
- To change from or to a left handed coordinate system, negate the Z
- component.
- """.trimIndent()
- )
- ALenum(
- "AL_LOOPING" to "0x1007",
- """
- Source looping.
- - Type: ALboolean
- - Range: \[AL_FALSE, AL_TRUE\]
- - Default: AL_FALSE
-
- Specifies whether source playback loops.
- """.trimIndent()
- )
- ALenum(
- "AL_BUFFER" to "0x1009",
- """
- Source buffer.
- - Type: ALuint
- - Range: any valid Buffer ID
- - Default: AL_NONE
-
- Specifies the buffer to provide sound samples for a source.
- """.trimIndent()
- )
- ALenum(
- "AL_GAIN" to "0x100A",
- """
- Source or listener gain.
- - Type: ALfloat
- - Range: \[0.0 - \]
-
- For sources, an initial linear gain value (before attenuation is applied).
- For the listener, an output linear gain adjustment.
-
- A value of 1.0 means unattenuated. Each division by 2 equals an attenuation
- of about -6dB. Each multiplication by 2 equals an amplification of about
- +6dB.
- """.trimIndent()
- )
- ALenum(
- "AL_MIN_GAIN" to "0x100D",
- """
- Minimum source gain.
- - Type: ALfloat
- - Range: \[0.0 - 1.0\]
-
- The minimum gain allowed for a source, after distance and cone attenuation
- are applied (if applicable).
- """.trimIndent()
- )
- ALenum(
- "AL_MAX_GAIN" to "0x100E",
- """
- Maximum source gain.
- - Type: ALfloat
- - Range: \[0.0 - 1.0\]
-
- The maximum gain allowed for a source, after distance and cone attenuation
- are applied (if applicable).
- """.trimIndent()
- )
- ALenum(
- "AL_ORIENTATION" to "0x100F",
- """
- Listener orientation.
- - Type: ALfloat\[6\]
- - Default: {0.0, 0.0, -1.0, 0.0, 1.0, 0.0}
-
- Effectively two three dimensional vectors. The first vector is the front (or
- "at") and the second is the top (or "up"). Both vectors are relative to the
- listener position.
-
- To change from or to a left handed coordinate system, negate the Z
- component of both vectors.
- """.trimIndent()
- )
- ALenum(
- "AL_SOURCE_STATE" to "0x1010",
- """
- Source state (query only).
- - Type: ALenum
- - Range: \[AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED\]
- """.trimIndent()
- )
-
- ALenum("Source state values.") {
+ ALenum("AL_NONE" to "0")
+ ALenum("AL_FALSE" to "0")
+ ALenum("AL_TRUE" to "1")
+
+ ALenum("AL_SOURCE_RELATIVE" to "0x202")
+ ALenum("AL_CONE_INNER_ANGLE" to "0x1001")
+ ALenum("AL_CONE_OUTER_ANGLE" to "0x1002")
+ ALenum("AL_PITCH" to "0x1003")
+ ALenum("AL_POSITION" to "0x1004")
+ ALenum("AL_DIRECTION" to "0x1005")
+ ALenum("AL_VELOCITY" to "0x1006")
+ ALenum("AL_LOOPING" to "0x1007")
+ ALenum("AL_BUFFER" to "0x1009")
+ ALenum("AL_GAIN" to "0x100A")
+ ALenum("AL_MIN_GAIN" to "0x100D")
+ ALenum("AL_MAX_GAIN" to "0x100E")
+ ALenum("AL_ORIENTATION" to "0x100F")
+ ALenum("AL_SOURCE_STATE" to "0x1010")
+
+ ALenum {
"AL_INITIAL"("0x1011")
"AL_PLAYING"("0x1012")
"AL_PAUSED"("0x1013")
"AL_STOPPED"("0x1014")
}
- ALenum(
- "AL_BUFFERS_QUEUED" to "0x1015",
- """
- Source Buffer Queue size (query only).
- - Type: ALint
+ ALenum("AL_BUFFERS_QUEUED" to "0x1015")
+ ALenum("AL_BUFFERS_PROCESSED" to "0x1016")
+ ALenum("AL_REFERENCE_DISTANCE" to "0x1020")
+ ALenum("AL_ROLLOFF_FACTOR" to "0x1021")
+ ALenum("AL_CONE_OUTER_GAIN" to "0x1022")
+ ALenum("AL_MAX_DISTANCE" to "0x1023")
- The number of buffers queued using alSourceQueueBuffers, minus the buffers
- removed with alSourceUnqueueBuffers.
- """.trimIndent()
- )
- ALenum(
- "AL_BUFFERS_PROCESSED" to "0x1016",
- """
- Source Buffer Queue processed count (query only).
- - Type: ALint
-
- The number of queued buffers that have been fully processed, and can be
- removed with alSourceUnqueueBuffers.
-
- Looping sources will never fully process buffers because they will be set to
- play again for when the source loops.
- """.trimIndent()
- )
- ALenum(
- "AL_REFERENCE_DISTANCE" to "0x1020",
- """
- Source reference distance.
- - Type: ALfloat
- - Range: \[0.0 - \]
- - Default: 1.0
-
- The distance in units that no distance attenuation occurs.
-
- At 0.0, no distance attenuation occurs with non-linear attenuation models.
- """.trimIndent()
- )
- ALenum(
- "AL_ROLLOFF_FACTOR" to "0x1021",
- """
- Source rolloff factor.
- - Type: ALfloat
- - Range: \[0.0 - \]
- - Default: 1.0
-
- Multiplier to exaggerate or diminish distance attenuation.
-
- At 0.0, no distance attenuation ever occurs.
- """.trimIndent()
- )
- ALenum(
- "AL_CONE_OUTER_GAIN" to "0x1022",
- """
- Outer cone gain.
- - Type: ALfloat
- - Range: \[0.0 - 1.0\]
- - Default: 0.0
-
- The gain attenuation applied when the listener is outside of the source's
- outer cone angle.
- """.trimIndent()
- )
- ALenum(
- "AL_MAX_DISTANCE" to "0x1023",
- """
- Source maximum distance.
- - Type: ALfloat
- - Range: \[0.0 - \]
- - Default: FLT_MAX
-
- The distance above which the source is not attenuated any further with a
- clamped distance model, or where attenuation reaches 0.0 gain for linear
- distance models with a default rolloff factor.
- """.trimIndent()
- )
-
- ALenum("AL_SEC_OFFSET" to "0x1024", "Source buffer offset, in seconds")
- ALenum("AL_SAMPLE_OFFSET" to "0x1025", "Source buffer offset, in sample frames")
- ALenum("AL_BYTE_OFFSET" to "0x1026", "Source buffer offset, in bytes")
-
- ALenum(
- "AL_SOURCE_TYPE" to "0x1027",
- """
- Source type (query only).
- - Type: ALenum
- - Range: \[AL_STATIC, AL_STREAMING, AL_UNDETERMINED\]
-
- A Source is Static if a Buffer has been attached using AL_BUFFER.
+ ALenum("AL_SEC_OFFSET" to "0x1024")
+ ALenum("AL_SAMPLE_OFFSET" to "0x1025")
+ ALenum("AL_BYTE_OFFSET" to "0x1026")
- A Source is Streaming if one or more Buffers have been attached using
- alSourceQueueBuffers.
+ ALenum("AL_SOURCE_TYPE" to "0x1027")
- A Source is Undetermined when it has the NULL buffer attached using
- AL_BUFFER.
- """.trimIndent()
- )
-
- ALenum("Source type values.") {
+ ALenum {
"AL_STATIC"("0x1028")
"AL_STREAMING"("0x1029")
"AL_UNDETERMINED"("0x1030")
}
- ALenum("AL_FORMAT_MONO8" to "0x1100", "Unsigned 8-bit mono buffer format.")
- ALenum("AL_FORMAT_MONO16" to "0x1101", "Signed 16-bit mono buffer format.")
- ALenum("AL_FORMAT_STEREO8" to "0x1102", "Unsigned 8-bit stereo buffer format.")
- ALenum("AL_FORMAT_STEREO16" to "0x1103", "Signed 16-bit stereo buffer format.")
+ ALenum("AL_FORMAT_MONO8" to "0x1100")
+ ALenum("AL_FORMAT_MONO16" to "0x1101")
+ ALenum("AL_FORMAT_STEREO8" to "0x1102")
+ ALenum("AL_FORMAT_STEREO16" to "0x1103")
- ALenum("AL_FREQUENCY" to "0x2001", "Buffer frequency/sample rate (query only).")
- ALenum("AL_BITS" to "0x2002", "Buffer bits per sample (query only).")
- ALenum("AL_CHANNELS" to "0x2003", "Buffer channel count (query only).")
- ALenum("AL_SIZE" to "0x2004", "Buffer data size in bytes (query only).")
+ ALenum("AL_FREQUENCY" to "0x2001")
+ ALenum("AL_BITS" to "0x2002")
+ ALenum("AL_CHANNELS" to "0x2003")
+ ALenum("AL_SIZE" to "0x2004")
- ALenum("Buffer state. Not for public use.") {
+ ALenum {
"AL_UNUSED"("0x2010")
"AL_PENDING"("0x2011")
"AL_PROCESSED"("0x2012")
}
- ALenum("AL_NO_ERROR" to "0", "No error.")
- ALenum("AL_INVALID_NAME" to "0xA001", "Invalid name (ID) passed to an AL call.")
- ALenum("AL_INVALID_ENUM" to "0xA002", "Invalid enumeration passed to AL call.")
- ALenum("AL_INVALID_VALUE" to "0xA003", "Invalid value passed to AL call.")
- ALenum("AL_INVALID_OPERATION" to "0xA004", "Illegal AL call.")
- ALenum("AL_OUT_OF_MEMORY" to "0xA005", "Not enough memory to execute the AL call.")
-
- ALenum("AL_VENDOR" to "0xB001", "Context string: Vendor name.")
- ALenum("AL_VERSION" to "0xB002", "Context string: Version.")
- ALenum("AL_RENDERER" to "0xB003", "Context string: Renderer name.")
- ALenum("AL_EXTENSIONS" to "0xB004", "Context string: Space-separated extension list.")
-
- ALenum(
- "AL_DOPPLER_FACTOR" to "0xC000",
- """
- Doppler scale.
- - Type: ALfloat
- - Range: \[0.0 - \]
- - Default: 1.0
-
- Scale for source and listener velocities.
- """.trimIndent()
- )
- ALenum(
- "AL_DOPPLER_VELOCITY" to "0xC001",
- """
- Doppler velocity (deprecated).
+ ALenum("AL_NO_ERROR" to "0")
+ ALenum("AL_INVALID_NAME" to "0xA001")
+ ALenum("AL_INVALID_ENUM" to "0xA002")
+ ALenum("AL_INVALID_VALUE" to "0xA003")
+ ALenum("AL_INVALID_OPERATION" to "0xA004")
+ ALenum("AL_OUT_OF_MEMORY" to "0xA005")
- A multiplier applied to the Speed of Sound.
- """.trimIndent()
- )
- ALenum(
- "AL_SPEED_OF_SOUND" to "0xC003",
- """
- Speed of Sound, in units per second.
- - Type: ALfloat
- - Range: \[0.0001 - \]
- - Default: 343.3
-
- The speed at which sound waves are assumed to travel, when calculating the
- doppler effect from source and listener velocities.
- """.trimIndent()
- )
+ ALenum("AL_VENDOR" to "0xB001")
+ ALenum("AL_VERSION" to "0xB002")
+ ALenum("AL_RENDERER" to "0xB003")
+ ALenum("AL_EXTENSIONS" to "0xB004")
- ALenum(
- "AL_DISTANCE_MODEL" to "0xD000",
- """
- Distance attenuation model.
- - Type: ALenum
- - Range: \[AL_NONE, AL_INVERSE_DISTANCE, AL_INVERSE_DISTANCE_CLAMPED,
- AL_LINEAR_DISTANCE, AL_LINEAR_DISTANCE_CLAMPED,
- AL_EXPONENT_DISTANCE, AL_EXPONENT_DISTANCE_CLAMPED\]
- - Default: AL_INVERSE_DISTANCE_CLAMPED
-
- The model by which sources attenuate with distance.
-
- - None - No distance attenuation.
- - Inverse - Doubling the distance halves the source gain.
- - Linear - Linear gain scaling between the reference and max distances.
- - Exponent - Exponential gain dropoff.
-
- Clamped variations work like the non-clamped counterparts, except the
- distance calculated is clamped between the reference and max distances.
- """.trimIndent()
- )
+ ALenum("AL_DOPPLER_FACTOR" to "0xC000")
+ ALenum("AL_DOPPLER_VELOCITY" to "0xC001")
+ ALenum("AL_SPEED_OF_SOUND" to "0xC003")
+
+ ALenum("AL_DISTANCE_MODEL" to "0xD000")
ALenum("Distance model values.") {
"AL_INVERSE_DISTANCE"("0xD001")
@@ -422,35 +134,25 @@ fun AL() {
"alGetError"(
ALenum,
- entrypoint = "alGetError",
- javadoc = """
- Obtain the first error generated in the AL context since the last call to
- this function.
- """.trimIndent()
+ entrypoint = "alGetError"
)
+"alIsExtensionPresent"(
ALboolean,
const_ALchar_ptr("extname"),
- entrypoint = "alIsExtensionPresent",
- javadoc = "Query for the presence of an extension on the AL context."
+ entrypoint = "alIsExtensionPresent"
).overload()
+"alGetProcAddress"(
void_ptr,
const_ALchar_ptr("fname"),
- entrypoint = "alGetProcAddress",
- javadoc = """
- Retrieve the address of a function. The returned function may be context-
- specific.
- """.trimIndent()
+ entrypoint = "alGetProcAddress"
).overload()
+"alGetEnumValue"(
ALenum,
const_ALchar_ptr("ename"),
- entrypoint = "alGetEnumValue",
- javadoc = "Retrieve the value of an enum. The returned value may be context-specific."
+ entrypoint = "alGetEnumValue"
).overload()
"alListenerf"(void, ALenum("param"), ALfloat("value"), entrypoint = "alListenerf")
@@ -504,21 +206,18 @@ fun AL() {
void,
ALsizei("n"),
ALuint_ptr("sources").ref(),
- entrypoint = "alGenSources",
- javadoc = "Create source objects."
+ entrypoint = "alGenSources"
)
"alDeleteSources"(
void,
ALsizei("n"),
const_ALuint_ptr("sources"),
- entrypoint = "alDeleteSources",
- javadoc = "Delete source objects."
+ entrypoint = "alDeleteSources"
)
"alIsSource"(
ALboolean,
ALuint("source"),
- entrypoint = "alIsSource",
- javadoc = "Verify an ID is for a valid source."
+ entrypoint = "alIsSource"
)
"alSourcef"(void, ALuint("source"), ALenum("param"), ALfloat("value"), entrypoint = "alSourcef")
@@ -594,55 +293,47 @@ fun AL() {
"alSourcePlay"(
void,
ALuint("source"),
- entrypoint = "alSourcePlay",
- javadoc = "Play, restart, or resume a source, setting its state to AL_PLAYING."
+ entrypoint = "alSourcePlay"
)
"alSourceStop"(
void,
ALuint("source"),
- entrypoint = "alSourceStop",
- javadoc = "Stop a source, setting its state to AL_STOPPED if playing or paused."
+ entrypoint = "alSourceStop"
)
"alSourceRewind"(
void,
ALuint("source"),
- entrypoint = "alSourceRewind",
- javadoc = "Rewind a source, setting its state to AL_INITIAL."
+ entrypoint = "alSourceRewind"
)
"alSourcePause"(
void,
ALuint("source"),
- entrypoint = "alSourcePause",
- javadoc = "Pause a source, setting its state to AL_PAUSED if playing."
+ entrypoint = "alSourcePause"
)
"alSourcePlayv"(
void,
ALsizei("n"),
const_ALuint_ptr("sources"),
- entrypoint = "alSourcePlayv",
- javadoc = "Play, restart, or resume a list of sources atomically."
+ entrypoint = "alSourcePlayv"
)
"alSourceStopv"(
void,
ALsizei("n"),
const_ALuint_ptr("sources"),
- entrypoint = "alSourceStopv",
- javadoc = "Stop a list of sources atomically."
+ entrypoint = "alSourceStopv"
)
"alSourceRewindv"(
void,
ALsizei("n"),
const_ALuint_ptr("sources"),
- entrypoint = "alSourceRewindv",
- javadoc = "Rewind a list of sources atomically."
+ entrypoint = "alSourceRewindv"
)
"alSourcePausev"(
void,
ALsizei("n"),
const_ALuint_ptr("sources"),
- entrypoint = "alSourcePausev",
- javadoc = "Pause a list of sources atomically."
+ entrypoint = "alSourcePausev"
)
"alSourceQueueBuffers"(
@@ -650,37 +341,32 @@ fun AL() {
ALuint("source"),
ALsizei("nb"),
const_ALuint_ptr("buffers"),
- entrypoint = "alSourceQueueBuffers",
- javadoc = "Queue buffers onto a source"
+ entrypoint = "alSourceQueueBuffers"
)
"alSourceUnqueueBuffers"(
void,
ALuint("source"),
ALsizei("nb"),
ALuint_ptr("buffers").ref(),
- entrypoint = "alSourceUnqueueBuffers",
- javadoc = "Unqueue processed buffers from a source"
+ entrypoint = "alSourceUnqueueBuffers"
)
"alGenBuffers"(
void,
ALsizei("n"),
ALuint_ptr("buffers").ref(),
- entrypoint = "alGenBuffers",
- javadoc = "Create buffer objects"
+ entrypoint = "alGenBuffers"
)
"alDeleteBuffers"(
void,
ALsizei("n"),
const_ALuint_ptr("buffers"),
- entrypoint = "alDeleteBuffers",
- javadoc = "Delete buffer objects"
+ entrypoint = "alDeleteBuffers"
)
"alIsBuffer"(
ALboolean,
ALuint("source"),
- entrypoint = "alIsBuffer",
- javadoc = "Verify an ID is a valid buffer (including the NULL buffer)"
+ entrypoint = "alIsBuffer"
)
"alBufferData"(
@@ -690,11 +376,7 @@ fun AL() {
const_ALvoid_ptr("data"),
ALsizei("size"),
ALsizei("samplerate"),
- entrypoint = "alBufferData",
- javadoc = """
- Copies data into the buffer, interpreting it using the specified format and
- samplerate.
- """.trimIndent()
+ entrypoint = "alBufferData"
)
"alBufferf"(void, ALuint("buffer"), ALenum("param"), ALfloat("value"), entrypoint = "alBufferf")
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt b/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt
index 77782676..73e84c07 100644
--- a/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt
+++ b/generators/openal/src/main/kotlin/overrungl/openal/ALC.kt
@@ -22,63 +22,39 @@ import overrungl.gen.void
fun ALC() {
StaticDowncall(alPackage, "ALC", alLookup) {
//region fields
- ALCenum("ALC_FALSE" to "0", "Boolean False.")
- ALCenum("ALC_TRUE" to "1", "Boolean True.")
-
- ALCenum("ALC_FREQUENCY" to "0x1007", "Context attribute: <int> Hz.")
- ALCenum("ALC_REFRESH" to "0x1008", "Context attribute: <int> Hz.")
- ALCenum("ALC_SYNC" to "0x1009", "Context attribute: AL_TRUE or AL_FALSE synchronous context?")
- ALCenum("ALC_MONO_SOURCES" to "0x1010", "Context attribute: <int> requested Mono (3D) Sources.")
- ALCenum("ALC_STEREO_SOURCES" to "0x1011", "Context attribute: <int> requested Stereo Sources.")
-
- ALCenum("ALC_NO_ERROR" to "0", "No error.")
- ALCenum("ALC_INVALID_DEVICE" to "0xA001", "Invalid device handle.")
- ALCenum("ALC_INVALID_CONTEXT" to "0xA002", "Invalid context handle.")
- ALCenum("ALC_INVALID_ENUM" to "0xA003", "Invalid enumeration passed to an ALC call.")
- ALCenum("ALC_INVALID_VALUE" to "0xA004", "Invalid value passed to an ALC call.")
- ALCenum("ALC_OUT_OF_MEMORY" to "0xA005", "Out of memory.")
-
- ALCenum("ALC_MAJOR_VERSION" to "0x1000", "Runtime ALC major version.")
- ALCenum("ALC_MINOR_VERSION" to "0x1001", "Runtime ALC minor version.")
-
- ALCenum("ALC_ATTRIBUTES_SIZE" to "0x1002", "Context attribute list size.")
- ALCenum("ALC_ALL_ATTRIBUTES" to "0x1003", "Context attribute list properties.")
- ALCenum("ALC_DEFAULT_DEVICE_SPECIFIER" to "0x1004", "String for the default device specifier.")
- ALCenum(
- "ALC_DEVICE_SPECIFIER" to "0x1005",
- """
- Device specifier string.
-
- If device handle is NULL, it is instead a null-character separated list of
- strings of known device specifiers (list ends with an empty string).
- """.trimIndent()
- )
- ALCenum("ALC_EXTENSIONS" to "0x1006", "String for space-separated list of ALC extensions.")
+ ALCenum("ALC_FALSE" to "0")
+ ALCenum("ALC_TRUE" to "1")
+
+ ALCenum("ALC_FREQUENCY" to "0x1007")
+ ALCenum("ALC_REFRESH" to "0x1008")
+ ALCenum("ALC_SYNC" to "0x1009")
+ ALCenum("ALC_MONO_SOURCES" to "0x1010")
+ ALCenum("ALC_STEREO_SOURCES" to "0x1011")
+
+ ALCenum("ALC_NO_ERROR" to "0")
+ ALCenum("ALC_INVALID_DEVICE" to "0xA001")
+ ALCenum("ALC_INVALID_CONTEXT" to "0xA002")
+ ALCenum("ALC_INVALID_ENUM" to "0xA003")
+ ALCenum("ALC_INVALID_VALUE" to "0xA004")
+ ALCenum("ALC_OUT_OF_MEMORY" to "0xA005")
+
+ ALCenum("ALC_MAJOR_VERSION" to "0x1000")
+ ALCenum("ALC_MINOR_VERSION" to "0x1001")
+
+ ALCenum("ALC_ATTRIBUTES_SIZE" to "0x1002")
+ ALCenum("ALC_ALL_ATTRIBUTES" to "0x1003")
+ ALCenum("ALC_DEFAULT_DEVICE_SPECIFIER" to "0x1004")
+ ALCenum("ALC_DEVICE_SPECIFIER" to "0x1005")
+ ALCenum("ALC_EXTENSIONS" to "0x1006")
ALCenum("ALC_EXT_CAPTURE" to "1", "Capture extension")
- ALCenum(
- "ALC_CAPTURE_DEVICE_SPECIFIER" to "0x310",
- """
- Capture device specifier string.
-
- If device handle is NULL, it is instead a null-character separated list of
- strings of known capture device specifiers (list ends with an empty string).
- """.trimIndent()
- )
- ALCenum("ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER" to "0x311", "String for the default capture device specifier.")
- ALCenum("ALC_CAPTURE_SAMPLES" to "0x312", "Number of sample frames available for capture.")
+ ALCenum("ALC_CAPTURE_DEVICE_SPECIFIER" to "0x310")
+ ALCenum("ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER" to "0x311")
+ ALCenum("ALC_CAPTURE_SAMPLES" to "0x312")
- ALCenum("ALC_ENUMERATE_ALL_EXT" to "1", "Enumerate All extension")
- ALCenum("ALC_DEFAULT_ALL_DEVICES_SPECIFIER" to "0x1012", "String for the default extended device specifier.")
- ALCenum(
- "ALC_ALL_DEVICES_SPECIFIER" to "0x1013",
- """
- Device's extended specifier string.
-
- If device handle is NULL, it is instead a null-character separated list of
- strings of known extended device specifiers (list ends with an empty string).
- """.trimIndent()
- )
+ ALCenum("ALC_ENUMERATE_ALL_EXT" to "1")
+ ALCenum("ALC_DEFAULT_ALL_DEVICES_SPECIFIER" to "0x1012")
+ ALCenum("ALC_ALL_DEVICES_SPECIFIER" to "0x1013")
//endregion
//region functions
@@ -86,107 +62,79 @@ fun ALC() {
ALCcontext_ptr,
ALCdevice_ptr("device"),
const_ALCint_ptr("attrlist"),
- entrypoint = "alcCreateContext",
- javadoc = "Create and attach a context to the given device."
+ entrypoint = "alcCreateContext"
)
"alcMakeContextCurrent"(
ALCboolean,
ALCcontext_ptr("context"),
- entrypoint = "alcMakeContextCurrent",
- javadoc = """
- Makes the given context the active process-wide context. Passing NULL clears
- the active context.
- """.trimIndent()
+ entrypoint = "alcMakeContextCurrent"
)
"alcProcessContext"(
void,
ALCcontext_ptr("context"),
- entrypoint = "alcProcessContext",
- javadoc = "Resumes processing updates for the given context."
+ entrypoint = "alcProcessContext"
)
"alcSuspendContext"(
void,
ALCcontext_ptr("context"),
- entrypoint = "alcSuspendContext",
- javadoc = "Suspends updates for the given context."
+ entrypoint = "alcSuspendContext"
)
"alcDestroyContext"(
void,
ALCcontext_ptr("context"),
- entrypoint = "alcDestroyContext",
- javadoc = "Remove a context from its device and destroys it."
+ entrypoint = "alcDestroyContext"
)
"alcGetCurrentContext"(
ALCcontext_ptr,
- entrypoint = "alcGetCurrentContext",
- javadoc = "Returns the currently active context."
+ entrypoint = "alcGetCurrentContext"
)
"alcGetContextsDevice"(
ALCdevice_ptr,
ALCcontext_ptr("context"),
- entrypoint = "alcGetContextsDevice",
- javadoc = "Returns the device that a particular context is attached to."
+ entrypoint = "alcGetContextsDevice"
)
+"alcOpenDevice"(
ALCdevice_ptr,
const_ALCchar_ptr("devicename"),
- entrypoint = "alcOpenDevice",
- javadoc = "Opens the named playback device."
+ entrypoint = "alcOpenDevice"
).overload()
"alcCloseDevice"(
ALCboolean,
ALCdevice_ptr("device"),
- entrypoint = "alcCloseDevice",
- javadoc = "Closes the given playback device."
+ entrypoint = "alcCloseDevice"
)
"alcGetError"(
ALCenum,
ALCdevice_ptr("device"),
- entrypoint = "alcGetError",
- javadoc = "Obtain the most recent Device error."
+ entrypoint = "alcGetError"
)
+"alcIsExtensionPresent"(
ALCboolean,
ALCdevice_ptr("device"),
const_ALCchar_ptr("extname"),
- entrypoint = "alcIsExtensionPresent",
- javadoc = """
- Query for the presence of an extension on the device. Pass a NULL device to
- query a device-inspecific extension.
- """.trimIndent()
+ entrypoint = "alcIsExtensionPresent"
).overload()
+"alcGetProcAddress"(
ALCvoid_ptr,
ALCdevice_ptr("device"),
const_ALCchar_ptr("funcname"),
- entrypoint = "alcGetProcAddress",
- javadoc = """
- Retrieve the address of a function. Given a non-NULL device, the returned
- function may be device-specific.
- """.trimIndent()
+ entrypoint = "alcGetProcAddress"
).overload()
+"alcGetEnumValue"(
ALCenum,
ALCdevice_ptr("device"),
const_ALCchar_ptr("enumname"),
- entrypoint = "alcGetEnumValue",
- javadoc = """
- Retrieve the value of an enum. Given a non-NULL device, the returned value
- may be device-specific.
- """.trimIndent()
+ entrypoint = "alcGetEnumValue"
).overload()
+"alcGetString_"(
const_ALCchar_ptr,
ALCdevice_ptr("device"),
ALCenum("param"),
- entrypoint = "alcGetString",
- javadoc = """
- Returns information about the device, and error strings.
- """.trimIndent()
+ entrypoint = "alcGetString"
).overload(name = "alcGetString")
"alcGetIntegerv"(
void,
@@ -194,10 +142,7 @@ fun ALC() {
ALCenum("param"),
ALCsizei("size"),
ALCint_ptr("values"),
- entrypoint = "alcGetIntegerv",
- javadoc = """
- Returns information about the device and the version of OpenAL.
- """.trimIndent()
+ entrypoint = "alcGetIntegerv"
)
+"alcCaptureOpenDevice"(
@@ -206,37 +151,29 @@ fun ALC() {
ALCuint("frequency"),
ALCenum("format"),
ALCsizei("buffersize"),
- entrypoint = "alcCaptureOpenDevice",
- javadoc = """
- Opens the named capture device with the given frequency, format, and buffer
- size.
- """.trimIndent()
+ entrypoint = "alcCaptureOpenDevice"
).overload()
"alcCaptureCloseDevice"(
ALCboolean,
ALCdevice_ptr("device"),
- entrypoint = "alcCaptureCloseDevice",
- javadoc = "Closes the given capture device."
+ entrypoint = "alcCaptureCloseDevice"
)
"alcCaptureStart"(
void,
ALCdevice_ptr("device"),
- entrypoint = "alcCaptureStart",
- javadoc = "Starts capturing samples into the device buffer."
+ entrypoint = "alcCaptureStart"
)
"alcCaptureStop"(
void,
ALCdevice_ptr("device"),
- entrypoint = "alcCaptureStop",
- javadoc = "Stops capturing samples. Samples in the device buffer remain available."
+ entrypoint = "alcCaptureStop"
)
"alcCaptureSamples"(
void,
ALCdevice_ptr("device"),
ALCvoid_ptr("buffer"),
ALCsizei("samples"),
- entrypoint = "alcCaptureSamples",
- javadoc = "Reads samples from the device buffer."
+ entrypoint = "alcCaptureSamples"
)
//endregion
}
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/ALExt.kt b/generators/openal/src/main/kotlin/overrungl/openal/ALExt.kt
new file mode 100644
index 00000000..aebbef86
--- /dev/null
+++ b/generators/openal/src/main/kotlin/overrungl/openal/ALExt.kt
@@ -0,0 +1,2215 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.openal
+
+import overrungl.gen.*
+
+fun alext() {
+ //region upcalls
+ val LPALFOLDBACKCALLBACK = Upcall(alPackage, "ALFoldbackCallback") {
+ targetMethod = "invoke"(
+ void,
+ ALenum("mode"),
+ ALsizei("count")
+ )
+ }.pointerType c "LPALFOLDBACKCALLBACK"
+ val ALEVENTPROCSOFT = Upcall(alPackage, "ALEventProcSOFT") {
+ targetMethod = "invoke"(
+ void,
+ ALenum("eventType"),
+ ALuint("object"),
+ ALuint("param"),
+ ALsizei("length"),
+ const_ALchar_ptr("message"),
+ void_ptr("userParam")
+ )
+ }.pointerType c "ALEVENTPROCSOFT"
+ val ALBUFFERCALLBACKTYPESOFT = Upcall(alPackage, "ALBufferCallbackTypeSOFT") {
+ targetMethod = "invoke"(
+ ALsizei,
+ ALvoid_ptr("userptr"),
+ ALvoid_ptr("sampledata"),
+ ALsizei("numbytes")
+ )
+ }.pointerType c "ALBUFFERCALLBACKTYPESOFT"
+ val ALDEBUGPROCEXT = Upcall(alPackage, "ALDebugProcEXT") {
+ targetMethod = "invoke"(
+ void,
+ ALenum("source"),
+ ALenum("type"),
+ ALuint("id"),
+ ALenum("severity"),
+ ALsizei("length"),
+ const_ALchar_ptr("message"),
+ void_ptr("userParam")
+ )
+ }.pointerType c "ALDEBUGPROCEXT"
+ val ALCEVENTPROCTYPESOFT = Upcall(alPackage, "ALCEventProcTypeSOFT") {
+ targetMethod = "invoke"(
+ void,
+ ALCenum("eventType"),
+ ALCenum("deviceType"),
+ ALCdevice_ptr("device"),
+ ALCsizei("length"),
+ const_ALCchar_ptr("message"),
+ void_ptr("userParam")
+ )
+ }.pointerType c "ALCEVENTPROCTYPESOFT"
+ //endregion
+
+ //region downcalls
+ downcall("AL_LOKI_IMA_ADPCM_format") {
+ ALenum("AL_FORMAT_IMA_ADPCM_MONO16_EXT" to "0x10000")
+ ALenum("AL_FORMAT_IMA_ADPCM_STEREO16_EXT" to "0x10001")
+ }
+ downcall("AL_LOKI_WAVE_format") {
+ ALenum("AL_FORMAT_WAVE_EXT" to "0x10002")
+ }
+ downcall("AL_EXT_vorbis") {
+ ALenum("AL_FORMAT_VORBIS_EXT" to "0x10003")
+ }
+ downcall("AL_LOKI_quadriphonic") {
+ ALenum("AL_FORMAT_QUAD8_LOKI" to "0x10004")
+ ALenum("AL_FORMAT_QUAD16_LOKI" to "0x10005")
+ }
+ downcall("AL_EXT_float32") {
+ ALenum("AL_FORMAT_MONO_FLOAT32" to "0x10010")
+ ALenum("AL_FORMAT_STEREO_FLOAT32" to "0x10011")
+ }
+ downcall("AL_EXT_double") {
+ ALenum("AL_FORMAT_MONO_DOUBLE_EXT" to "0x10012")
+ ALenum("AL_FORMAT_STEREO_DOUBLE_EXT" to "0x10013")
+ }
+ downcall("AL_EXT_MULAW") {
+ ALenum("AL_FORMAT_MONO_MULAW_EXT" to "0x10014")
+ ALenum("AL_FORMAT_STEREO_MULAW_EXT" to "0x10015")
+ }
+ downcall("AL_EXT_ALAW") {
+ ALenum("AL_FORMAT_MONO_ALAW_EXT" to "0x10016")
+ ALenum("AL_FORMAT_STEREO_ALAW_EXT" to "0x10017")
+ }
+ downcall("ALC_LOKI_audio_channel") {
+ ALCenum("ALC_CHAN_MAIN_LOKI" to "0x500001")
+ ALCenum("ALC_CHAN_PCM_LOKI" to "0x500002")
+ ALCenum("ALC_CHAN_CD_LOKI" to "0x500003")
+ }
+ downcall("AL_EXT_MCFORMATS") {
+ ALenum("AL_FORMAT_QUAD8" to "0x1204")
+ ALenum("AL_FORMAT_QUAD16" to "0x1205")
+ ALenum("AL_FORMAT_QUAD32" to "0x1206")
+ ALenum("AL_FORMAT_REAR8" to "0x1207")
+ ALenum("AL_FORMAT_REAR16" to "0x1208")
+ ALenum("AL_FORMAT_REAR32" to "0x1209")
+ ALenum("AL_FORMAT_51CHN8" to "0x120A")
+ ALenum("AL_FORMAT_51CHN16" to "0x120B")
+ ALenum("AL_FORMAT_51CHN32" to "0x120C")
+ ALenum("AL_FORMAT_61CHN8" to "0x120D")
+ ALenum("AL_FORMAT_61CHN16" to "0x120E")
+ ALenum("AL_FORMAT_61CHN32" to "0x120F")
+ ALenum("AL_FORMAT_71CHN8" to "0x1210")
+ ALenum("AL_FORMAT_71CHN16" to "0x1211")
+ ALenum("AL_FORMAT_71CHN32" to "0x1212")
+ }
+ downcall("AL_EXT_MULAW_MCFORMATS") {
+ ALenum("AL_FORMAT_MONO_MULAW" to "0x10014")
+ ALenum("AL_FORMAT_STEREO_MULAW" to "0x10015")
+ ALenum("AL_FORMAT_QUAD_MULAW" to "0x10021")
+ ALenum("AL_FORMAT_REAR_MULAW" to "0x10022")
+ ALenum("AL_FORMAT_51CHN_MULAW" to "0x10023")
+ ALenum("AL_FORMAT_61CHN_MULAW" to "0x10024")
+ ALenum("AL_FORMAT_71CHN_MULAW" to "0x10025")
+ }
+ downcall("AL_EXT_IMA4") {
+ ALenum("AL_FORMAT_MONO_IMA4" to "0x1300")
+ ALenum("AL_FORMAT_STEREO_IMA4" to "0x1301")
+ }
+ downcall("AL_EXT_STATIC_BUFFER") {
+ "alBufferDataStatic"(
+ void,
+ const_ALuint("buffer"),
+ ALenum("format"),
+ ALvoid_ptr("data"),
+ ALsizei("size"),
+ ALsizei("freq"),
+ entrypoint = "alBufferDataStatic",
+ optional = true
+ )
+ }
+ downcall("ALC_EXT_disconnect") {
+ ALCenum("ALC_CONNECTED" to "0x313")
+ }
+ downcall("ALC_EXT_thread_local_context") {
+ "alcSetThreadContext"(
+ ALCboolean,
+ ALCcontext_ptr("context"),
+ entrypoint = "alcSetThreadContext",
+ optional = true
+ )
+ "alcGetThreadContext"(ALCcontext_ptr, entrypoint = "alcGetThreadContext", optional = true)
+ }
+ downcall("AL_EXT_source_distance_model") {
+ ALenum("AL_SOURCE_DISTANCE_MODEL" to "0x200")
+ }
+ downcall("AL_SOFT_buffer_sub_data") {
+ ALenum("AL_BYTE_RW_OFFSETS_SOFT" to "0x1031")
+ ALenum("AL_SAMPLE_RW_OFFSETS_SOFT" to "0x1032")
+ "alBufferSubDataSOFT"(
+ void,
+ ALuint("buffer"),
+ ALenum("format"),
+ const_ALvoid_ptr("data"),
+ ALsizei("offset"),
+ ALsizei("length"),
+ entrypoint = "alBufferSubDataSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_loop_points") {
+ ALenum("AL_LOOP_POINTS_SOFT" to "0x2015")
+ }
+ downcall("AL_EXT_FOLDBACK") {
+ string_u8("AL_EXT_FOLDBACK_NAME" to """"AL_EXT_FOLDBACK"""")
+ ALenum("AL_FOLDBACK_EVENT_BLOCK" to "0x4112")
+ ALenum("AL_FOLDBACK_EVENT_START" to "0x4111")
+ ALenum("AL_FOLDBACK_EVENT_STOP" to "0x4113")
+ ALenum("AL_FOLDBACK_MODE_MONO" to "0x4101")
+ ALenum("AL_FOLDBACK_MODE_STEREO" to "0x4102")
+ "alRequestFoldbackStart"(
+ void,
+ ALenum("mode"),
+ ALsizei("count"),
+ ALsizei("length"),
+ ALfloat_ptr("mem"),
+ LPALFOLDBACKCALLBACK("callback"),
+ entrypoint = "alRequestFoldbackStart",
+ optional = true
+ )
+ "alRequestFoldbackStop"(void, entrypoint = "alRequestFoldbackStop", optional = true)
+ }
+ downcall("ALC_EXT_DEDICATED") {
+ ALenum("AL_DEDICATED_GAIN" to "0x0001")
+ ALenum("AL_EFFECT_DEDICATED_DIALOGUE" to "0x9001")
+ ALenum("AL_EFFECT_DEDICATED_LOW_FREQUENCY_EFFECT" to "0x9000")
+ }
+ downcall("AL_SOFT_buffer_samples") {
+ ALenum("AL_MONO_SOFT" to "0x1500")
+ ALenum("AL_STEREO_SOFT" to "0x1501")
+ ALenum("AL_REAR_SOFT" to "0x1502")
+ ALenum("AL_QUAD_SOFT" to "0x1503")
+ ALenum("AL_5POINT1_SOFT" to "0x1504")
+ ALenum("AL_6POINT1_SOFT" to "0x1505")
+ ALenum("AL_7POINT1_SOFT" to "0x1506")
+
+ ALenum("AL_BYTE_SOFT" to "0x1400")
+ ALenum("AL_UNSIGNED_BYTE_SOFT" to "0x1401")
+ ALenum("AL_SHORT_SOFT" to "0x1402")
+ ALenum("AL_UNSIGNED_SHORT_SOFT" to "0x1403")
+ ALenum("AL_INT_SOFT" to "0x1404")
+ ALenum("AL_UNSIGNED_INT_SOFT" to "0x1405")
+ ALenum("AL_FLOAT_SOFT" to "0x1406")
+ ALenum("AL_DOUBLE_SOFT" to "0x1407")
+ ALenum("AL_BYTE3_SOFT" to "0x1408")
+ ALenum("AL_UNSIGNED_BYTE3_SOFT" to "0x1409")
+
+ ALenum("AL_MONO8_SOFT" to "0x1100")
+ ALenum("AL_MONO16_SOFT" to "0x1101")
+ ALenum("AL_MONO32F_SOFT" to "0x10010")
+ ALenum("AL_STEREO8_SOFT" to "0x1102")
+ ALenum("AL_STEREO16_SOFT" to "0x1103")
+ ALenum("AL_STEREO32F_SOFT" to "0x10011")
+ ALenum("AL_QUAD8_SOFT" to "0x1204")
+ ALenum("AL_QUAD16_SOFT" to "0x1205")
+ ALenum("AL_QUAD32F_SOFT" to "0x1206")
+ ALenum("AL_REAR8_SOFT" to "0x1207")
+ ALenum("AL_REAR16_SOFT" to "0x1208")
+ ALenum("AL_REAR32F_SOFT" to "0x1209")
+ ALenum("AL_5POINT1_8_SOFT" to "0x120A")
+ ALenum("AL_5POINT1_16_SOFT" to "0x120B")
+ ALenum("AL_5POINT1_32F_SOFT" to "0x120C")
+ ALenum("AL_6POINT1_8_SOFT" to "0x120D")
+ ALenum("AL_6POINT1_16_SOFT" to "0x120E")
+ ALenum("AL_6POINT1_32F_SOFT" to "0x120F")
+ ALenum("AL_7POINT1_8_SOFT" to "0x1210")
+ ALenum("AL_7POINT1_16_SOFT" to "0x1211")
+ ALenum("AL_7POINT1_32F_SOFT" to "0x1212")
+
+ ALenum("AL_INTERNAL_FORMAT_SOFT" to "0x2008")
+ ALenum("AL_BYTE_LENGTH_SOFT" to "0x2009")
+ ALenum("AL_SAMPLE_LENGTH_SOFT" to "0x200A")
+ ALenum("AL_SEC_LENGTH_SOFT" to "0x200B")
+
+ "alBufferSamplesSOFT"(
+ void,
+ ALuint("buffer"),
+ ALuint("samplerate"),
+ ALenum("internalformat"),
+ ALsizei("samples"),
+ ALenum("channels"),
+ ALenum("type"),
+ const_ALvoid_ptr("data"),
+ entrypoint = "alBufferSamplesSOFT",
+ optional = true
+ )
+ "alBufferSubSamplesSOFT"(
+ void,
+ ALuint("buffer"),
+ ALsizei("offset"),
+ ALsizei("samples"),
+ ALenum("channels"),
+ ALenum("type"),
+ const_ALvoid_ptr("data"),
+ entrypoint = "alBufferSubSamplesSOFT",
+ optional = true
+ )
+ "alGetBufferSamplesSOFT"(
+ void,
+ ALuint("buffer"),
+ ALsizei("offset"),
+ ALsizei("samples"),
+ ALenum("channels"),
+ ALenum("type"),
+ ALvoid_ptr("data"),
+ entrypoint = "alGetBufferSamplesSOFT",
+ optional = true
+ )
+ "alIsBufferFormatSupportedSOFT"(
+ ALboolean,
+ ALenum("format"),
+ entrypoint = "alIsBufferFormatSupportedSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_direct_channels") {
+ ALenum("AL_DIRECT_CHANNELS_SOFT" to "0x1033")
+ }
+ downcall("ALC_SOFT_loopback") {
+ ALCenum("ALC_FORMAT_CHANNELS_SOFT" to "0x1990")
+ ALCenum("ALC_FORMAT_TYPE_SOFT" to "0x1991")
+
+ ALCenum("ALC_BYTE_SOFT" to "0x1400")
+ ALCenum("ALC_UNSIGNED_BYTE_SOFT" to "0x1401")
+ ALCenum("ALC_SHORT_SOFT" to "0x1402")
+ ALCenum("ALC_UNSIGNED_SHORT_SOFT" to "0x1403")
+ ALCenum("ALC_INT_SOFT" to "0x1404")
+ ALCenum("ALC_UNSIGNED_INT_SOFT" to "0x1405")
+ ALCenum("ALC_FLOAT_SOFT" to "0x1406")
+
+ ALCenum("ALC_MONO_SOFT" to "0x1500")
+ ALCenum("ALC_STEREO_SOFT" to "0x1501")
+ ALCenum("ALC_QUAD_SOFT" to "0x1503")
+ ALCenum("ALC_5POINT1_SOFT" to "0x1504")
+ ALCenum("ALC_6POINT1_SOFT" to "0x1505")
+ ALCenum("ALC_7POINT1_SOFT" to "0x1506")
+
+ "alcLoopbackOpenDeviceSOFT"(
+ ALCdevice_ptr,
+ const_ALCchar_ptr("deviceName"),
+ entrypoint = "alcLoopbackOpenDeviceSOFT",
+ optional = true
+ )
+ "alcIsRenderFormatSupportedSOFT"(
+ ALCboolean,
+ ALCdevice_ptr("device"),
+ ALCsizei("freq"),
+ ALCenum("channels"),
+ ALCenum("type"),
+ entrypoint = "alcIsRenderFormatSupportedSOFT",
+ optional = true
+ )
+ "alcRenderSamplesSOFT"(
+ void,
+ ALCdevice_ptr("device"),
+ ALCvoid_ptr("buffer"),
+ ALCsizei("samples"),
+ entrypoint = "alcRenderSamplesSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_EXT_STEREO_ANGLES") {
+ ALenum("AL_STEREO_ANGLES" to "0x1030")
+ }
+ downcall("AL_EXT_SOURCE_RADIUS") {
+ ALenum("AL_SOURCE_RADIUS" to "0x1031")
+ }
+ downcall("AL_SOFT_source_latency") {
+ ALenum("AL_SAMPLE_OFFSET_LATENCY_SOFT" to "0x1200")
+ ALenum("AL_SEC_OFFSET_LATENCY_SOFT" to "0x1201")
+
+ "alSourcedSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble("value"),
+ entrypoint = "alSourcedSOFT",
+ optional = true
+ )
+ "alSource3dSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble("value1"),
+ ALdouble("value2"),
+ ALdouble("value3"),
+ entrypoint = "alSource3dSOFT",
+ optional = true
+ )
+ "alSourcedvSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ const_ALdouble_ptr("values"),
+ entrypoint = "alSourcedvSOFT",
+ optional = true
+ )
+ "alGetSourcedSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble_ptr("value"),
+ entrypoint = "alGetSourcedSOFT",
+ optional = true
+ )
+ "alGetSource3dSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble_ptr("value1"),
+ ALdouble_ptr("value2"),
+ ALdouble_ptr("value3"),
+ entrypoint = "alGetSource3dSOFT",
+ optional = true
+ )
+ "alGetSourcedvSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble_ptr("values"),
+ entrypoint = "alGetSourcedvSOFT",
+ optional = true
+ )
+ "alSourcei64SOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT("value"),
+ entrypoint = "alSourcei64SOFT",
+ optional = true
+ )
+ "alSource3i64SOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT("value1"),
+ ALint64SOFT("value2"),
+ ALint64SOFT("value3"),
+ entrypoint = "alSource3i64SOFT",
+ optional = true
+ )
+ "alSourcei64vSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ const_ALint64SOFT_ptr("values"),
+ entrypoint = "alSourcei64vSOFT",
+ optional = true
+ )
+ "alGetSourcei64SOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT_ptr("value"),
+ entrypoint = "alGetSourcei64SOFT",
+ optional = true
+ )
+ "alGetSource3i64SOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT_ptr("value1"),
+ ALint64SOFT_ptr("value2"),
+ ALint64SOFT_ptr("value3"),
+ entrypoint = "alGetSource3i64SOFT",
+ optional = true
+ )
+ "alGetSourcei64vSOFT"(
+ void,
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT_ptr("values"),
+ entrypoint = "alGetSourcei64vSOFT",
+ optional = true
+ )
+ }
+ downcall("ALC_EXT_DEFAULT_FILTER_ORDER") {
+ ALCenum("ALC_DEFAULT_FILTER_ORDER" to "0x1100")
+ }
+ downcall("AL_SOFT_deferred_updates") {
+ ALenum("AL_DEFERRED_UPDATES_SOFT" to "0xC002")
+
+ "alDeferUpdatesSOFT"(void, entrypoint = "alDeferUpdatesSOFT", optional = true)
+ "alProcessUpdatesSOFT"(void, entrypoint = "alProcessUpdatesSOFT", optional = true)
+ }
+ downcall("AL_SOFT_block_alignment") {
+ ALenum("AL_UNPACK_BLOCK_ALIGNMENT_SOFT" to "0x200C")
+ ALenum("AL_PACK_BLOCK_ALIGNMENT_SOFT" to "0x200D")
+ }
+ downcall("AL_SOFT_MSADPCM") {
+ ALenum("AL_FORMAT_MONO_MSADPCM_SOFT" to "0x1302")
+ ALenum("AL_FORMAT_STEREO_MSADPCM_SOFT" to "0x1303")
+ }
+ downcall("ALC_SOFT_pause_device") {
+ "alcDevicePauseSOFT"(void, ALCdevice_ptr("device"), entrypoint = "alcDevicePauseSOFT", optional = true)
+ "alcDeviceResumeSOFT"(void, ALCdevice_ptr("device"), entrypoint = "alcDeviceResumeSOFT", optional = true)
+ }
+ downcall("AL_EXT_BFORMAT") {
+ ALenum("AL_FORMAT_BFORMAT2D_8" to "0x20021")
+ ALenum("AL_FORMAT_BFORMAT2D_16" to "0x20022")
+ ALenum("AL_FORMAT_BFORMAT2D_FLOAT32" to "0x20023")
+ ALenum("AL_FORMAT_BFORMAT3D_8" to "0x20031")
+ ALenum("AL_FORMAT_BFORMAT3D_16" to "0x20032")
+ ALenum("AL_FORMAT_BFORMAT3D_FLOAT32" to "0x20033")
+ }
+ downcall("AL_EXT_MULAW_BFORMAT") {
+ ALenum("AL_FORMAT_BFORMAT2D_MULAW" to "0x10031")
+ ALenum("AL_FORMAT_BFORMAT3D_MULAW" to "0x10032")
+ }
+ downcall("ALC_SOFT_HRTF") {
+ ALCenum("ALC_HRTF_SOFT" to "0x1992")
+ ALCenum("ALC_DONT_CARE_SOFT" to "0x0002")
+ ALCenum("ALC_HRTF_STATUS_SOFT" to "0x1993")
+ ALCenum("ALC_HRTF_DISABLED_SOFT" to "0x0000")
+ ALCenum("ALC_HRTF_ENABLED_SOFT" to "0x0001")
+ ALCenum("ALC_HRTF_DENIED_SOFT" to "0x0002")
+ ALCenum("ALC_HRTF_REQUIRED_SOFT" to "0x0003")
+ ALCenum("ALC_HRTF_HEADPHONES_DETECTED_SOFT" to "0x0004")
+ ALCenum("ALC_HRTF_UNSUPPORTED_FORMAT_SOFT" to "0x0005")
+ ALCenum("ALC_NUM_HRTF_SPECIFIERS_SOFT" to "0x1994")
+ ALCenum("ALC_HRTF_SPECIFIER_SOFT" to "0x1995")
+ ALCenum("ALC_HRTF_ID_SOFT" to "0x1996")
+
+ "alcGetStringiSOFT"(
+ const_ALCchar_ptr,
+ ALCdevice_ptr("device"),
+ ALCenum("paramName"),
+ ALCsizei("index"),
+ entrypoint = "alcGetStringiSOFT",
+ optional = true
+ )
+ "alcResetDeviceSOFT"(
+ ALCboolean,
+ ALCdevice_ptr("device"),
+ const_ALCint_ptr("attribs"),
+ entrypoint = "alcResetDeviceSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_gain_clamp_ex") {
+ ALenum("AL_GAIN_LIMIT_SOFT" to "0x200E")
+ }
+ downcall("AL_SOFT_source_resampler") {
+ ALenum("AL_NUM_RESAMPLERS_SOFT" to "0x1210")
+ ALenum("AL_DEFAULT_RESAMPLER_SOFT" to "0x1211")
+ ALenum("AL_SOURCE_RESAMPLER_SOFT" to "0x1212")
+ ALenum("AL_RESAMPLER_NAME_SOFT" to "0x1213")
+
+ "alGetStringiSOFT"(
+ const_ALchar_ptr,
+ ALenum("pname"),
+ ALsizei("index"),
+ entrypoint = "alGetStringiSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_source_spatialize") {
+ ALenum("AL_SOURCE_SPATIALIZE_SOFT" to "0x1214")
+ ALenum("AL_AUTO_SOFT" to "0x0002")
+ }
+ downcall("ALC_SOFT_output_limiter") {
+ ALCenum("ALC_OUTPUT_LIMITER_SOFT" to "0x199A")
+ }
+ downcall("ALC_SOFT_device_clock") {
+ ALCenum("ALC_DEVICE_CLOCK_SOFT" to "0x1600")
+ ALCenum("ALC_DEVICE_LATENCY_SOFT" to "0x1601")
+ ALCenum("ALC_DEVICE_CLOCK_LATENCY_SOFT" to "0x1602")
+ ALenum("AL_SAMPLE_OFFSET_CLOCK_SOFT" to "0x1202")
+ ALenum("AL_SEC_OFFSET_CLOCK_SOFT" to "0x1203")
+
+ "alcGetInteger64vSOFT"(
+ void,
+ ALCdevice_ptr("device"),
+ ALCenum("pname"),
+ ALsizei("size"),
+ ALCint64SOFT_ptr("values"),
+ entrypoint = "alcGetInteger64vSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_direct_channels_remix") {
+ ALenum("AL_DROP_UNMATCHED_SOFT" to "0x0001")
+ ALenum("AL_REMIX_UNMATCHED_SOFT" to "0x0002")
+ }
+ downcall("AL_SOFT_bformat_ex") {
+ ALenum("AL_AMBISONIC_LAYOUT_SOFT" to "0x1997")
+ ALenum("AL_AMBISONIC_SCALING_SOFT" to "0x1998")
+
+ ALenum("AL_FUMA_SOFT" to "0x0000")
+ ALenum("AL_ACN_SOFT" to "0x0001")
+
+ ALenum("AL_SN3D_SOFT" to "0x0001")
+ ALenum("AL_N3D_SOFT" to "0x0002")
+ }
+ downcall("ALC_SOFT_loopback_bformat") {
+ ALCenum("ALC_AMBISONIC_LAYOUT_SOFT" to "0x1997")
+ ALCenum("ALC_AMBISONIC_SCALING_SOFT" to "0x1998")
+ ALCenum("ALC_AMBISONIC_ORDER_SOFT" to "0x1999")
+ ALCenum("ALC_MAX_AMBISONIC_ORDER_SOFT" to "0x199B")
+
+ ALCenum("ALC_BFORMAT3D_SOFT" to "0x1507")
+
+ ALCenum("ALC_FUMA_SOFT" to "0x0000")
+ ALCenum("ALC_ACN_SOFT" to "0x0001")
+
+ ALCenum("ALC_SN3D_SOFT" to "0x0001")
+ ALCenum("ALC_N3D_SOFT" to "0x0002")
+ }
+ downcall("AL_SOFT_effect_target") {
+ ALenum("AL_EFFECTSLOT_TARGET_SOFT" to "0x199C")
+ }
+ downcall("AL_SOFT_events") {
+ ALenum("AL_EVENT_CALLBACK_FUNCTION_SOFT" to "0x19A2")
+ ALenum("AL_EVENT_CALLBACK_USER_PARAM_SOFT" to "0x19A3")
+ ALenum("AL_EVENT_TYPE_BUFFER_COMPLETED_SOFT" to "0x19A4")
+ ALenum("AL_EVENT_TYPE_SOURCE_STATE_CHANGED_SOFT" to "0x19A5")
+ ALenum("AL_EVENT_TYPE_DISCONNECTED_SOFT" to "0x19A6")
+
+ "alEventControlSOFT"(
+ void,
+ ALsizei("count"),
+ const_ALenum_ptr("types"),
+ ALboolean("enable"),
+ entrypoint = "alEventControlSOFT",
+ optional = true
+ )
+ "alEventCallbackSOFT"(
+ void,
+ ALEVENTPROCSOFT("callback"),
+ void_ptr("userParam"),
+ entrypoint = "alEventCallbackSOFT",
+ optional = true
+ )
+ "alGetPointerSOFT"(void_ptr, ALenum("pname"), entrypoint = "alGetPointerSOFT", optional = true)
+ "alGetPointervSOFT"(
+ void,
+ ALenum("pname"),
+ void_ptr_ptr("values"),
+ entrypoint = "alGetPointervSOFT",
+ optional = true
+ )
+ }
+ downcall("ALC_SOFT_reopen_device") {
+ "alcReopenDeviceSOFT"(
+ ALCboolean,
+ ALCdevice_ptr("device"),
+ const_ALCchar_ptr("deviceName"),
+ const_ALCint_ptr("attribs"),
+ entrypoint = "alcReopenDeviceSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_callback_buffer") {
+ ALenum("AL_BUFFER_CALLBACK_FUNCTION_SOFT" to "0x19A0")
+ ALenum("AL_BUFFER_CALLBACK_USER_PARAM_SOFT" to "0x19A1")
+
+ "alBufferCallbackSOFT"(
+ void,
+ ALuint("buffer"),
+ ALenum("format"),
+ ALsizei("freq"),
+ ALBUFFERCALLBACKTYPESOFT("callback"),
+ ALvoid_ptr("userptr"),
+ entrypoint = "alBufferCallbackSOFT",
+ optional = true
+ )
+ "alGetBufferPtrSOFT"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALvoid_ptr_ptr("ptr"),
+ entrypoint = "alGetBufferPtrSOFT",
+ optional = true
+ )
+ "alGetBuffer3PtrSOFT"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALvoid_ptr_ptr("ptr0"),
+ ALvoid_ptr_ptr("ptr1"),
+ ALvoid_ptr_ptr("ptr2"),
+ entrypoint = "alGetBuffer3PtrSOFT",
+ optional = true
+ )
+ "alGetBufferPtrvSOFT"(
+ void,
+ ALuint("buffer"),
+ ALenum("param"),
+ ALvoid_ptr_ptr("ptr"),
+ entrypoint = "alGetBufferPtrvSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_UHJ") {
+ ALenum("AL_FORMAT_UHJ2CHN8_SOFT" to "0x19A2")
+ ALenum("AL_FORMAT_UHJ2CHN16_SOFT" to "0x19A3")
+ ALenum("AL_FORMAT_UHJ2CHN_FLOAT32_SOFT" to "0x19A4")
+ ALenum("AL_FORMAT_UHJ3CHN8_SOFT" to "0x19A5")
+ ALenum("AL_FORMAT_UHJ3CHN16_SOFT" to "0x19A6")
+ ALenum("AL_FORMAT_UHJ3CHN_FLOAT32_SOFT" to "0x19A7")
+ ALenum("AL_FORMAT_UHJ4CHN8_SOFT" to "0x19A8")
+ ALenum("AL_FORMAT_UHJ4CHN16_SOFT" to "0x19A9")
+ ALenum("AL_FORMAT_UHJ4CHN_FLOAT32_SOFT" to "0x19AA")
+
+ ALenum("AL_STEREO_MODE_SOFT" to "0x19B0")
+ ALenum("AL_NORMAL_SOFT" to "0x0000")
+ ALenum("AL_SUPER_STEREO_SOFT" to "0x0001")
+ ALenum("AL_SUPER_STEREO_WIDTH_SOFT" to "0x19B1")
+ }
+ downcall("AL_SOFT_UHJ_ex") {
+ ALenum("AL_FORMAT_UHJ2CHN_MULAW_SOFT" to "0x19B3")
+ ALenum("AL_FORMAT_UHJ2CHN_ALAW_SOFT" to "0x19B4")
+ ALenum("AL_FORMAT_UHJ2CHN_IMA4_SOFT" to "0x19B5")
+ ALenum("AL_FORMAT_UHJ2CHN_MSADPCM_SOFT" to "0x19B6")
+ ALenum("AL_FORMAT_UHJ3CHN_MULAW_SOFT" to "0x19B7")
+ ALenum("AL_FORMAT_UHJ3CHN_ALAW_SOFT" to "0x19B8")
+ ALenum("AL_FORMAT_UHJ4CHN_MULAW_SOFT" to "0x19B9")
+ ALenum("AL_FORMAT_UHJ4CHN_ALAW_SOFT" to "0x19BA")
+ }
+ downcall("ALC_SOFT_output_mode") {
+ ALCenum("ALC_OUTPUT_MODE_SOFT" to "0x19AC")
+ ALCenum("ALC_ANY_SOFT" to "0x19AD")
+
+ ALCenum("ALC_STEREO_BASIC_SOFT" to "0x19AE")
+ ALCenum("ALC_STEREO_UHJ_SOFT" to "0x19AF")
+ ALCenum("ALC_STEREO_HRTF_SOFT" to "0x19B2")
+
+ ALCenum("ALC_SURROUND_5_1_SOFT" to "0x1504")
+ ALCenum("ALC_SURROUND_6_1_SOFT" to "0x1505")
+ ALCenum("ALC_SURROUND_7_1_SOFT" to "0x1506")
+ }
+ downcall("AL_SOFT_source_start_delay") {
+ "alSourcePlayAtTimeSOFT"(
+ void,
+ ALuint("source"),
+ ALint64SOFT("start_time"),
+ entrypoint = "alSourcePlayAtTimeSOFT",
+ optional = true
+ )
+ "alSourcePlayAtTimevSOFT"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ ALint64SOFT("start_time"),
+ entrypoint = "alSourcePlayAtTimevSOFT",
+ optional = true
+ )
+ }
+ downcall("ALC_EXT_debug") {
+ ALCenum("ALC_CONTEXT_FLAGS_EXT" to "0x19CF")
+ ALCenum("ALC_CONTEXT_DEBUG_BIT_EXT" to "0x0001")
+ }
+ downcall("AL_EXT_debug") {
+ ALenum("AL_DONT_CARE_EXT" to "0x0002")
+ ALenum("AL_DEBUG_OUTPUT_EXT" to "0x19B2")
+ ALenum("AL_DEBUG_CALLBACK_FUNCTION_EXT" to "0x19B3")
+ ALenum("AL_DEBUG_CALLBACK_USER_PARAM_EXT" to "0x19B4")
+ ALenum("AL_DEBUG_SOURCE_API_EXT" to "0x19B5")
+ ALenum("AL_DEBUG_SOURCE_AUDIO_SYSTEM_EXT" to "0x19B6")
+ ALenum("AL_DEBUG_SOURCE_THIRD_PARTY_EXT" to "0x19B7")
+ ALenum("AL_DEBUG_SOURCE_APPLICATION_EXT" to "0x19B8")
+ ALenum("AL_DEBUG_SOURCE_OTHER_EXT" to "0x19B9")
+ ALenum("AL_DEBUG_TYPE_ERROR_EXT" to "0x19BA")
+ ALenum("AL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_EXT" to "0x19BB")
+ ALenum("AL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_EXT" to "0x19BC")
+ ALenum("AL_DEBUG_TYPE_PORTABILITY_EXT" to "0x19BD")
+ ALenum("AL_DEBUG_TYPE_PERFORMANCE_EXT" to "0x19BE")
+ ALenum("AL_DEBUG_TYPE_MARKER_EXT" to "0x19BF")
+ ALenum("AL_DEBUG_TYPE_PUSH_GROUP_EXT" to "0x19C0")
+ ALenum("AL_DEBUG_TYPE_POP_GROUP_EXT" to "0x19C1")
+ ALenum("AL_DEBUG_TYPE_OTHER_EXT" to "0x19C2")
+ ALenum("AL_DEBUG_SEVERITY_HIGH_EXT" to "0x19C3")
+ ALenum("AL_DEBUG_SEVERITY_MEDIUM_EXT" to "0x19C4")
+ ALenum("AL_DEBUG_SEVERITY_LOW_EXT" to "0x19C5")
+ ALenum("AL_DEBUG_SEVERITY_NOTIFICATION_EXT" to "0x19C6")
+ ALenum("AL_DEBUG_LOGGED_MESSAGES_EXT" to "0x19C7")
+ ALenum("AL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_EXT" to "0x19C8")
+ ALenum("AL_MAX_DEBUG_MESSAGE_LENGTH_EXT" to "0x19C9")
+ ALenum("AL_MAX_DEBUG_LOGGED_MESSAGES_EXT" to "0x19CA")
+ ALenum("AL_MAX_DEBUG_GROUP_STACK_DEPTH_EXT" to "0x19CB")
+ ALenum("AL_MAX_LABEL_LENGTH_EXT" to "0x19CC")
+ ALenum("AL_STACK_OVERFLOW_EXT" to "0x19CD")
+ ALenum("AL_STACK_UNDERFLOW_EXT" to "0x19CE")
+ ALenum("AL_CONTEXT_FLAGS_EXT" to "0x19CF")
+ ALenum("AL_BUFFER_EXT" to "0x1009")
+ ALenum("AL_SOURCE_EXT" to "0x19D0")
+ ALenum("AL_FILTER_EXT" to "0x19D1")
+ ALenum("AL_EFFECT_EXT" to "0x19D2")
+ ALenum("AL_AUXILIARY_EFFECT_SLOT_EXT" to "0x19D3")
+
+ "alDebugMessageCallbackEXT"(
+ void,
+ ALDEBUGPROCEXT("callback"),
+ void_ptr("userParam"),
+ entrypoint = "alDebugMessageCallbackEXT",
+ optional = true
+ )
+ "alDebugMessageInsertEXT"(
+ void,
+ ALenum("source"),
+ ALenum("type"),
+ ALuint("id"),
+ ALenum("severity"),
+ ALsizei("length"),
+ const_ALchar_ptr("message"),
+ entrypoint = "alDebugMessageInsertEXT",
+ optional = true
+ )
+ "alDebugMessageControlEXT"(
+ void,
+ ALenum("source"),
+ ALenum("type"),
+ ALenum("severity"),
+ ALsizei("count"),
+ const_ALuint_ptr("ids"),
+ ALboolean("enable"),
+ entrypoint = "alDebugMessageControlEXT",
+ optional = true
+ )
+ "alPushDebugGroupEXT"(
+ void,
+ ALenum("source"),
+ ALuint("id"),
+ ALsizei("length"),
+ const_ALchar_ptr("message"),
+ entrypoint = "alPushDebugGroupEXT",
+ optional = true
+ )
+ "alPopDebugGroupEXT"(void, entrypoint = "alPopDebugGroupEXT", optional = true)
+ "alGetDebugMessageLogEXT"(
+ ALuint,
+ ALuint("count"),
+ ALsizei("logBufSize"),
+ ALenum_ptr("sources"),
+ ALenum_ptr("types"),
+ ALuint_ptr("ids"),
+ ALenum_ptr("severities"),
+ ALsizei_ptr("lengths"),
+ ALchar_ptr("logBuf"),
+ entrypoint = "alGetDebugMessageLogEXT",
+ optional = true
+ )
+ "alObjectLabelEXT"(
+ void,
+ ALenum("identifier"),
+ ALuint("name"),
+ ALsizei("length"),
+ const_ALchar_ptr("label"),
+ entrypoint = "alObjectLabelEXT",
+ optional = true
+ )
+ "alGetObjectLabelEXT"(
+ void,
+ ALenum("identifier"),
+ ALuint("name"),
+ ALsizei("bufSize"),
+ ALsizei_ptr("length"),
+ ALchar_ptr("label"),
+ entrypoint = "alGetObjectLabelEXT",
+ optional = true
+ )
+ "alGetPointerEXT"(void_ptr, ALenum("pname"), entrypoint = "alGetPointerEXT", optional = true)
+ "alGetPointervEXT"(
+ void,
+ ALenum("pname"),
+ void_ptr_ptr("values"),
+ entrypoint = "alGetPointervEXT",
+ optional = true
+ )
+ }
+ downcall("ALC_SOFT_system_events") {
+ ALCenum("ALC_PLAYBACK_DEVICE_SOFT" to "0x19D4")
+ ALCenum("ALC_CAPTURE_DEVICE_SOFT" to "0x19D5")
+ ALCenum("ALC_EVENT_TYPE_DEFAULT_DEVICE_CHANGED_SOFT" to "0x19D6")
+ ALCenum("ALC_EVENT_TYPE_DEVICE_ADDED_SOFT" to "0x19D7")
+ ALCenum("ALC_EVENT_TYPE_DEVICE_REMOVED_SOFT" to "0x19D8")
+ ALCenum("ALC_EVENT_SUPPORTED_SOFT" to "0x19D9")
+ ALCenum("ALC_EVENT_NOT_SUPPORTED_SOFT" to "0x19DA")
+
+ "alcEventIsSupportedSOFT"(
+ ALCenum,
+ ALCenum("eventType"),
+ ALCenum("deviceType"),
+ entrypoint = "alcEventIsSupportedSOFT",
+ optional = true
+ )
+ "alcEventControlSOFT"(
+ ALCboolean,
+ ALCsizei("count"),
+ const_ALCenum_ptr("events"),
+ ALCboolean("enable"),
+ entrypoint = "alcEventControlSOFT",
+ optional = true
+ )
+ "alcEventCallbackSOFT"(
+ void,
+ ALCEVENTPROCTYPESOFT("callback"),
+ void_ptr("userParam"),
+ entrypoint = "alcEventCallbackSOFT",
+ optional = true
+ )
+ }
+ downcall("AL_EXT_direct_context") {
+ "alcGetProcAddress2"(
+ ALCvoid_ptr,
+ ALCdevice_ptr("device"),
+ const_ALCchar_ptr("funcName"),
+ entrypoint = "alcGetProcAddress2",
+ optional = true
+ )
+
+ "alEnableDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("capability"),
+ entrypoint = "alEnableDirect",
+ optional = true
+ )
+ "alDisableDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("capability"),
+ entrypoint = "alDisableDirect",
+ optional = true
+ )
+ "alIsEnabledDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALenum("capability"),
+ entrypoint = "alIsEnabledDirect",
+ optional = true
+ )
+
+ "alDopplerFactorDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALfloat("value"),
+ entrypoint = "alDopplerFactorDirect",
+ optional = true
+ )
+ "alSpeedOfSoundDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALfloat("value"),
+ entrypoint = "alSpeedOfSoundDirect",
+ optional = true
+ )
+ "alDistanceModelDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("distanceModel"),
+ entrypoint = "alDistanceModelDirect",
+ optional = true
+ )
+
+ "alGetStringDirect"(
+ const_ALchar_ptr,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ entrypoint = "alGetStringDirect",
+ optional = true
+ )
+ "alGetBooleanvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALboolean_ptr("values"),
+ entrypoint = "alGetBooleanvDirect",
+ optional = true
+ )
+ "alGetIntegervDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALint_ptr("values"),
+ entrypoint = "alGetIntegervDirect",
+ optional = true
+ )
+ "alGetFloatvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALfloat_ptr("values"),
+ entrypoint = "alGetFloatvDirect",
+ optional = true
+ )
+ "alGetDoublevDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALdouble_ptr("values"),
+ entrypoint = "alGetDoublevDirect",
+ optional = true
+ )
+ "alGetBooleanDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ entrypoint = "alGetBooleanDirect",
+ optional = true
+ )
+ "alGetIntegerDirect"(
+ ALint,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ entrypoint = "alGetIntegerDirect",
+ optional = true
+ )
+ "alGetFloatDirect"(
+ ALfloat,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ entrypoint = "alGetFloatDirect",
+ optional = true
+ )
+ "alGetDoubleDirect"(
+ ALdouble,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ entrypoint = "alGetDoubleDirect",
+ optional = true
+ )
+
+ "alGetErrorDirect"(ALenum, ALCcontext_ptr("context"), entrypoint = "alGetErrorDirect", optional = true)
+ "alIsExtensionPresentDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ const_ALchar_ptr("extname"),
+ entrypoint = "alIsExtensionPresentDirect",
+ optional = true
+ )
+ "alGetProcAddressDirect"(
+ void_ptr,
+ ALCcontext_ptr("context"),
+ const_ALchar_ptr("fname"),
+ entrypoint = "alGetProcAddressDirect",
+ optional = true
+ )
+ "alGetEnumValueDirect"(
+ ALenum,
+ ALCcontext_ptr("context"),
+ const_ALchar_ptr("ename"),
+ entrypoint = "alGetEnumValueDirect",
+ optional = true
+ )
+
+ "alListenerfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALfloat("value"),
+ entrypoint = "alListenerfDirect",
+ optional = true
+ )
+ "alListener3fDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALfloat("value1"),
+ ALfloat("value2"),
+ ALfloat("value3"),
+ entrypoint = "alListener3fDirect",
+ optional = true
+ )
+ "alListenerfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ const_ALfloat_ptr("values"),
+ entrypoint = "alListenerfvDirect",
+ optional = true
+ )
+ "alListeneriDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALint("value"),
+ entrypoint = "alListeneriDirect",
+ optional = true
+ )
+ "alListener3iDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALint("value1"),
+ ALint("value2"),
+ ALint("value3"),
+ entrypoint = "alListener3iDirect",
+ optional = true
+ )
+ "alListenerivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ const_ALint_ptr("values"),
+ entrypoint = "alListenerivDirect",
+ optional = true
+ )
+ "alGetListenerfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALfloat_ptr("value"),
+ entrypoint = "alGetListenerfDirect",
+ optional = true
+ )
+ "alGetListener3fDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALfloat_ptr("value1"),
+ ALfloat_ptr("value2"),
+ ALfloat_ptr("value3"),
+ entrypoint = "alGetListener3fDirect",
+ optional = true
+ )
+ "alGetListenerfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALfloat_ptr("values"),
+ entrypoint = "alGetListenerfvDirect",
+ optional = true
+ )
+ "alGetListeneriDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALint_ptr("value"),
+ entrypoint = "alGetListeneriDirect",
+ optional = true
+ )
+ "alGetListener3iDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALint_ptr("value1"),
+ ALint_ptr("value2"),
+ ALint_ptr("value3"),
+ entrypoint = "alGetListener3iDirect",
+ optional = true
+ )
+ "alGetListenerivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("param"),
+ ALint_ptr("values"),
+ entrypoint = "alGetListenerivDirect",
+ optional = true
+ )
+
+ "alGenSourcesDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ ALuint_ptr("sources"),
+ entrypoint = "alGenSourcesDirect",
+ optional = true
+ )
+ "alDeleteSourcesDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alDeleteSourcesDirect",
+ optional = true
+ )
+ "alIsSourceDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ entrypoint = "alIsSourceDirect",
+ optional = true
+ )
+ "alSourcefDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat("value"),
+ entrypoint = "alSourcefDirect",
+ optional = true
+ )
+ "alSource3fDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat("value1"),
+ ALfloat("value2"),
+ ALfloat("value3"),
+ entrypoint = "alSource3fDirect",
+ optional = true
+ )
+ "alSourcefvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ const_ALfloat_ptr("values"),
+ entrypoint = "alSourcefvDirect",
+ optional = true
+ )
+ "alSourceiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint("value"),
+ entrypoint = "alSourceiDirect",
+ optional = true
+ )
+ "alSource3iDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint("value1"),
+ ALint("value2"),
+ ALint("value3"),
+ entrypoint = "alSource3iDirect",
+ optional = true
+ )
+ "alSourceivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ const_ALint_ptr("values"),
+ entrypoint = "alSourceivDirect",
+ optional = true
+ )
+ "alGetSourcefDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat_ptr("value"),
+ entrypoint = "alGetSourcefDirect",
+ optional = true
+ )
+ "alGetSource3fDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat_ptr("value1"),
+ ALfloat_ptr("value2"),
+ ALfloat_ptr("value3"),
+ entrypoint = "alGetSource3fDirect",
+ optional = true
+ )
+ "alGetSourcefvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALfloat_ptr("values"),
+ entrypoint = "alGetSourcefvDirect",
+ optional = true
+ )
+ "alGetSourceiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint_ptr("value"),
+ entrypoint = "alGetSourceiDirect",
+ optional = true
+ )
+ "alGetSource3iDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint_ptr("value1"),
+ ALint_ptr("value2"),
+ ALint_ptr("value3"),
+ entrypoint = "alGetSource3iDirect",
+ optional = true
+ )
+ "alGetSourceivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint_ptr("values"),
+ entrypoint = "alGetSourceivDirect",
+ optional = true
+ )
+ "alSourcePlayDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ entrypoint = "alSourcePlayDirect",
+ optional = true
+ )
+ "alSourceStopDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ entrypoint = "alSourceStopDirect",
+ optional = true
+ )
+ "alSourceRewindDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ entrypoint = "alSourceRewindDirect",
+ optional = true
+ )
+ "alSourcePauseDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ entrypoint = "alSourcePauseDirect",
+ optional = true
+ )
+ "alSourcePlayvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourcePlayvDirect",
+ optional = true
+ )
+ "alSourceStopvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourceStopvDirect",
+ optional = true
+ )
+ "alSourceRewindvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourceRewindvDirect",
+ optional = true
+ )
+ "alSourcePausevDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ entrypoint = "alSourcePausevDirect",
+ optional = true
+ )
+ "alSourceQueueBuffersDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALsizei("nb"),
+ const_ALuint_ptr("buffers"),
+ entrypoint = "alSourceQueueBuffersDirect",
+ optional = true
+ )
+ "alSourceUnqueueBuffersDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALsizei("nb"),
+ ALuint_ptr("buffers"),
+ entrypoint = "alSourceUnqueueBuffersDirect",
+ optional = true
+ )
+
+ "alGenBuffersDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ ALuint_ptr("buffers"),
+ entrypoint = "alGenBuffersDirect",
+ optional = true
+ )
+ "alDeleteBuffersDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("buffers"),
+ entrypoint = "alDeleteBuffersDirect",
+ optional = true
+ )
+ "alIsBufferDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ entrypoint = "alIsBufferDirect",
+ optional = true
+ )
+ "alBufferDataDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("format"),
+ const_ALvoid_ptr("data"),
+ ALsizei("size"),
+ ALsizei("samplerate"),
+ entrypoint = "alBufferDataDirect",
+ optional = true
+ )
+ "alBufferfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat("value"),
+ entrypoint = "alBufferfDirect",
+ optional = true
+ )
+ "alBuffer3fDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat("value1"),
+ ALfloat("value2"),
+ ALfloat("value3"),
+ entrypoint = "alBuffer3fDirect",
+ optional = true
+ )
+ "alBufferfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ const_ALfloat_ptr("values"),
+ entrypoint = "alBufferfvDirect",
+ optional = true
+ )
+ "alBufferiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint("value"),
+ entrypoint = "alBufferiDirect",
+ optional = true
+ )
+ "alBuffer3iDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint("value1"),
+ ALint("value2"),
+ ALint("value3"),
+ entrypoint = "alBuffer3iDirect",
+ optional = true
+ )
+ "alBufferivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ const_ALint_ptr("values"),
+ entrypoint = "alBufferivDirect",
+ optional = true
+ )
+ "alGetBufferfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat_ptr("value"),
+ entrypoint = "alGetBufferfDirect",
+ optional = true
+ )
+ "alGetBuffer3fDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat_ptr("value1"),
+ ALfloat_ptr("value2"),
+ ALfloat_ptr("value3"),
+ entrypoint = "alGetBuffer3fDirect",
+ optional = true
+ )
+ "alGetBufferfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALfloat_ptr("values"),
+ entrypoint = "alGetBufferfvDirect",
+ optional = true
+ )
+ "alGetBufferiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint_ptr("value"),
+ entrypoint = "alGetBufferiDirect",
+ optional = true
+ )
+ "alGetBuffer3iDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint_ptr("value1"),
+ ALint_ptr("value2"),
+ ALint_ptr("value3"),
+ entrypoint = "alGetBuffer3iDirect",
+ optional = true
+ )
+ "alGetBufferivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALint_ptr("values"),
+ entrypoint = "alGetBufferivDirect",
+ optional = true
+ )
+
+ "alGenEffectsDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ ALuint_ptr("effects"),
+ entrypoint = "alGenEffectsDirect",
+ optional = true
+ )
+ "alDeleteEffectsDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("effects"),
+ entrypoint = "alDeleteEffectsDirect",
+ optional = true
+ )
+ "alIsEffectDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ entrypoint = "alIsEffectDirect",
+ optional = true
+ )
+ "alEffectiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ ALint("iValue"),
+ entrypoint = "alEffectiDirect",
+ optional = true
+ )
+ "alEffectivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ const_ALint_ptr("piValues"),
+ entrypoint = "alEffectivDirect",
+ optional = true
+ )
+ "alEffectfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ ALfloat("flValue"),
+ entrypoint = "alEffectfDirect",
+ optional = true
+ )
+ "alEffectfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ const_ALfloat_ptr("pflValues"),
+ entrypoint = "alEffectfvDirect",
+ optional = true
+ )
+ "alGetEffectiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ ALint_ptr("piValue"),
+ entrypoint = "alGetEffectiDirect",
+ optional = true
+ )
+ "alGetEffectivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ ALint_ptr("piValues"),
+ entrypoint = "alGetEffectivDirect",
+ optional = true
+ )
+ "alGetEffectfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ ALfloat_ptr("pflValue"),
+ entrypoint = "alGetEffectfDirect",
+ optional = true
+ )
+ "alGetEffectfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effect"),
+ ALenum("param"),
+ ALfloat_ptr("pflValues"),
+ entrypoint = "alGetEffectfvDirect",
+ optional = true
+ )
+
+ "alGenFiltersDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ ALuint_ptr("filters"),
+ entrypoint = "alGenFiltersDirect",
+ optional = true
+ )
+ "alDeleteFiltersDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("filters"),
+ entrypoint = "alDeleteFiltersDirect",
+ optional = true
+ )
+ "alIsFilterDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ entrypoint = "alIsFilterDirect",
+ optional = true
+ )
+ "alFilteriDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ ALint("iValue"),
+ entrypoint = "alFilteriDirect",
+ optional = true
+ )
+ "alFilterivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ const_ALint_ptr("piValues"),
+ entrypoint = "alFilterivDirect",
+ optional = true
+ )
+ "alFilterfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ ALfloat("flValue"),
+ entrypoint = "alFilterfDirect",
+ optional = true
+ )
+ "alFilterfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ const_ALfloat_ptr("pflValues"),
+ entrypoint = "alFilterfvDirect",
+ optional = true
+ )
+ "alGetFilteriDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ ALint_ptr("piValue"),
+ entrypoint = "alGetFilteriDirect",
+ optional = true
+ )
+ "alGetFilterivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ ALint_ptr("piValues"),
+ entrypoint = "alGetFilterivDirect",
+ optional = true
+ )
+ "alGetFilterfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ ALfloat_ptr("pflValue"),
+ entrypoint = "alGetFilterfDirect",
+ optional = true
+ )
+ "alGetFilterfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("filter"),
+ ALenum("param"),
+ ALfloat_ptr("pflValues"),
+ entrypoint = "alGetFilterfvDirect",
+ optional = true
+ )
+
+ "alGenAuxiliaryEffectSlotsDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ ALuint_ptr("effectslots"),
+ entrypoint = "alGenAuxiliaryEffectSlotsDirect",
+ optional = true
+ )
+ "alDeleteAuxiliaryEffectSlotsDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("effectslots"),
+ entrypoint = "alDeleteAuxiliaryEffectSlotsDirect",
+ optional = true
+ )
+ "alIsAuxiliaryEffectSlotDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ entrypoint = "alIsAuxiliaryEffectSlotDirect",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALint("iValue"),
+ entrypoint = "alAuxiliaryEffectSlotiDirect",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ const_ALint_ptr("piValues"),
+ entrypoint = "alAuxiliaryEffectSlotivDirect",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALfloat("flValue"),
+ entrypoint = "alAuxiliaryEffectSlotfDirect",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ const_ALfloat_ptr("pflValues"),
+ entrypoint = "alAuxiliaryEffectSlotfvDirect",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotiDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALint_ptr("piValue"),
+ entrypoint = "alGetAuxiliaryEffectSlotiDirect",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotivDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALint_ptr("piValues"),
+ entrypoint = "alGetAuxiliaryEffectSlotivDirect",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotfDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALfloat_ptr("pflValue"),
+ entrypoint = "alGetAuxiliaryEffectSlotfDirect",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotfvDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALfloat_ptr("pflValues"),
+ entrypoint = "alGetAuxiliaryEffectSlotfvDirect",
+ optional = true
+ )
+
+ "alBufferDataStaticDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("format"),
+ ALvoid_ptr("data"),
+ ALsizei("size"),
+ ALsizei("freq"),
+ entrypoint = "alBufferDataStaticDirect",
+ optional = true
+ )
+
+ "alDebugMessageCallbackDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALDEBUGPROCEXT("callback"),
+ void_ptr("userParam"),
+ entrypoint = "alDebugMessageCallbackDirectEXT",
+ optional = true
+ )
+ "alDebugMessageInsertDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("source"),
+ ALenum("type"),
+ ALuint("id"),
+ ALenum("severity"),
+ ALsizei("length"),
+ const_ALchar_ptr("message"),
+ entrypoint = "alDebugMessageInsertDirectEXT",
+ optional = true
+ )
+ "alDebugMessageControlDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("source"),
+ ALenum("type"),
+ ALenum("severity"),
+ ALsizei("count"),
+ const_ALuint_ptr("ids"),
+ ALboolean("enable"),
+ entrypoint = "alDebugMessageControlDirectEXT",
+ optional = true
+ )
+ "alPushDebugGroupDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("source"),
+ ALuint("id"),
+ ALsizei("length"),
+ const_ALchar_ptr("message"),
+ entrypoint = "alPushDebugGroupDirectEXT",
+ optional = true
+ )
+ "alPopDebugGroupDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alPopDebugGroupDirectEXT",
+ optional = true
+ )
+ "alGetDebugMessageLogDirectEXT"(
+ ALuint,
+ ALCcontext_ptr("context"),
+ ALuint("count"),
+ ALsizei("logBufSize"),
+ ALenum_ptr("sources"),
+ ALenum_ptr("types"),
+ ALuint_ptr("ids"),
+ ALenum_ptr("severities"),
+ ALsizei_ptr("lengths"),
+ ALchar_ptr("logBuf"),
+ entrypoint = "alGetDebugMessageLogDirectEXT",
+ optional = true
+ )
+ "alObjectLabelDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("identifier"),
+ ALuint("name"),
+ ALsizei("length"),
+ const_ALchar_ptr("label"),
+ entrypoint = "alObjectLabelDirectEXT",
+ optional = true
+ )
+ "alGetObjectLabelDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("identifier"),
+ ALuint("name"),
+ ALsizei("bufSize"),
+ ALsizei_ptr("length"),
+ ALchar_ptr("label"),
+ entrypoint = "alGetObjectLabelDirectEXT",
+ optional = true
+ )
+ "alGetPointerDirectEXT"(
+ void_ptr,
+ ALCcontext_ptr("context"),
+ ALenum("pname"),
+ entrypoint = "alGetPointerDirectEXT",
+ optional = true
+ )
+ "alGetPointervDirectEXT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("pname"),
+ void_ptr_ptr("values"),
+ entrypoint = "alGetPointervDirectEXT",
+ optional = true
+ )
+
+ "alRequestFoldbackStartDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("mode"),
+ ALsizei("count"),
+ ALsizei("length"),
+ ALfloat_ptr("mem"),
+ LPALFOLDBACKCALLBACK("callback"),
+ entrypoint = "alRequestFoldbackStartDirect",
+ optional = true
+ )
+ "alRequestFoldbackStopDirect"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alRequestFoldbackStopDirect",
+ optional = true
+ )
+
+ "alBufferSubDataDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("format"),
+ const_ALvoid_ptr("data"),
+ ALsizei("offset"),
+ ALsizei("length"),
+ entrypoint = "alBufferSubDataDirectSOFT",
+ optional = true
+ )
+
+ "alSourcedDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble("value"),
+ entrypoint = "alSourcedDirectSOFT",
+ optional = true
+ )
+ "alSource3dDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble("value1"),
+ ALdouble("value2"),
+ ALdouble("value3"),
+ entrypoint = "alSource3dDirectSOFT",
+ optional = true
+ )
+ "alSourcedvDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ const_ALdouble_ptr("values"),
+ entrypoint = "alSourcedvDirectSOFT",
+ optional = true
+ )
+ "alGetSourcedDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble_ptr("value"),
+ entrypoint = "alGetSourcedDirectSOFT",
+ optional = true
+ )
+ "alGetSource3dDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble_ptr("value1"),
+ ALdouble_ptr("value2"),
+ ALdouble_ptr("value3"),
+ entrypoint = "alGetSource3dDirectSOFT",
+ optional = true
+ )
+ "alGetSourcedvDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALdouble_ptr("values"),
+ entrypoint = "alGetSourcedvDirectSOFT",
+ optional = true
+ )
+ "alSourcei64DirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT("value"),
+ entrypoint = "alSourcei64DirectSOFT",
+ optional = true
+ )
+ "alSource3i64DirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT("value1"),
+ ALint64SOFT("value2"),
+ ALint64SOFT("value3"),
+ entrypoint = "alSource3i64DirectSOFT",
+ optional = true
+ )
+ "alSourcei64vDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ const_ALint64SOFT_ptr("values"),
+ entrypoint = "alSourcei64vDirectSOFT",
+ optional = true
+ )
+ "alGetSourcei64DirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT_ptr("value"),
+ entrypoint = "alGetSourcei64DirectSOFT",
+ optional = true
+ )
+ "alGetSource3i64DirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT_ptr("value1"),
+ ALint64SOFT_ptr("value2"),
+ ALint64SOFT_ptr("value3"),
+ entrypoint = "alGetSource3i64DirectSOFT",
+ optional = true
+ )
+ "alGetSourcei64vDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALenum("param"),
+ ALint64SOFT_ptr("values"),
+ entrypoint = "alGetSourcei64vDirectSOFT",
+ optional = true
+ )
+
+ "alDeferUpdatesDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alDeferUpdatesDirectSOFT",
+ optional = true
+ )
+ "alProcessUpdatesDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ entrypoint = "alProcessUpdatesDirectSOFT",
+ optional = true
+ )
+
+ "alGetStringiDirectSOFT"(
+ const_ALchar_ptr,
+ ALCcontext_ptr("context"),
+ ALenum("pname"),
+ ALsizei("index"),
+ entrypoint = "alGetStringiDirectSOFT",
+ optional = true
+ )
+
+ "alEventControlDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("count"),
+ const_ALenum_ptr("types"),
+ ALboolean("enable"),
+ entrypoint = "alEventControlDirectSOFT",
+ optional = true
+ )
+ "alEventCallbackDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALEVENTPROCSOFT("callback"),
+ void_ptr("userParam"),
+ entrypoint = "alEventCallbackDirectSOFT",
+ optional = true
+ )
+ "alGetPointerDirectSOFT"(
+ void_ptr,
+ ALCcontext_ptr("context"),
+ ALenum("pname"),
+ entrypoint = "alGetPointerDirectSOFT",
+ optional = true
+ )
+ "alGetPointervDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALenum("pname"),
+ void_ptr_ptr("values"),
+ entrypoint = "alGetPointervDirectSOFT",
+ optional = true
+ )
+
+ "alBufferCallbackDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("format"),
+ ALsizei("freq"),
+ ALBUFFERCALLBACKTYPESOFT("callback"),
+ ALvoid_ptr("userptr"),
+ entrypoint = "alBufferCallbackDirectSOFT",
+ optional = true
+ )
+ "alGetBufferPtrDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALvoid_ptr_ptr("ptr"),
+ entrypoint = "alGetBufferPtrDirectSOFT",
+ optional = true
+ )
+ "alGetBuffer3PtrDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALvoid_ptr_ptr("ptr0"),
+ ALvoid_ptr_ptr("ptr1"),
+ ALvoid_ptr_ptr("ptr2"),
+ entrypoint = "alGetBuffer3PtrDirectSOFT",
+ optional = true
+ )
+ "alGetBufferPtrvDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALenum("param"),
+ ALvoid_ptr_ptr("ptr"),
+ entrypoint = "alGetBufferPtrvDirectSOFT",
+ optional = true
+ )
+
+ "alSourcePlayAtTimeDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALuint("source"),
+ ALint64SOFT("start_time"),
+ entrypoint = "alSourcePlayAtTimeDirectSOFT",
+ optional = true
+ )
+ "alSourcePlayAtTimevDirectSOFT"(
+ void,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("sources"),
+ ALint64SOFT("start_time"),
+ entrypoint = "alSourcePlayAtTimevDirectSOFT",
+ optional = true
+ )
+
+ "EAXSetDirect"(
+ ALenum,
+ ALCcontext_ptr("context"),
+ (address c "const struct _GUID *")("property_set_id"),
+ ALuint("property_id"),
+ ALuint("source_id"),
+ ALvoid_ptr("value"),
+ ALuint("value_size"),
+ entrypoint = "EAXSetDirect",
+ optional = true
+ )
+ "EAXGetDirect"(
+ ALenum,
+ ALCcontext_ptr("context"),
+ (address c "const struct _GUID *")("property_set_id"),
+ ALuint("property_id"),
+ ALuint("source_id"),
+ ALvoid_ptr("value"),
+ ALuint("value_size"),
+ entrypoint = "EAXGetDirect",
+ optional = true
+ )
+ "EAXSetBufferModeDirect"(
+ ALboolean,
+ ALCcontext_ptr("context"),
+ ALsizei("n"),
+ const_ALuint_ptr("buffers"),
+ ALint("value"),
+ entrypoint = "EAXSetBufferModeDirect",
+ optional = true
+ )
+ "EAXGetBufferModeDirect"(
+ ALenum,
+ ALCcontext_ptr("context"),
+ ALuint("buffer"),
+ ALint_ptr("pReserved"),
+ entrypoint = "EAXGetBufferModeDirect",
+ optional = true
+ )
+ }
+ downcall("AL_SOFT_bformat_hoa") {
+ ALenum("AL_UNPACK_AMBISONIC_ORDER_SOFT" to "0x199D")
+ }
+ //endregion
+}
+
+fun downcall(extName: String, action: StaticDowncall.() -> Unit) {
+ StaticDowncall(
+ alPackage,
+ extName.split('_').joinToString("") { it.replaceFirstChar(Char::uppercaseChar) },
+ alLookup,
+ writeWholeFile = true,
+ action = action
+ )
+}
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/EFX.kt b/generators/openal/src/main/kotlin/overrungl/openal/EFX.kt
new file mode 100644
index 00000000..4fa0292a
--- /dev/null
+++ b/generators/openal/src/main/kotlin/overrungl/openal/EFX.kt
@@ -0,0 +1,855 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.openal
+
+import overrungl.gen.float
+import overrungl.gen.int
+import overrungl.gen.string_u8
+import overrungl.gen.void
+
+fun efx() {
+ downcall("ALC_EXT_EFX") {
+ string_u8("ALC_EXT_EFX_NAME" to """"ALC_EXT_EFX"""")
+
+ int("ALC_EFX_MAJOR_VERSION" to "0x20001")
+ int("ALC_EFX_MINOR_VERSION" to "0x20002")
+ int("ALC_MAX_AUXILIARY_SENDS" to "0x20003")
+
+ int("AL_METERS_PER_UNIT" to "0x20004")
+
+ int("AL_DIRECT_FILTER" to "0x20005")
+ int("AL_AUXILIARY_SEND_FILTER" to "0x20006")
+ int("AL_AIR_ABSORPTION_FACTOR" to "0x20007")
+ int("AL_ROOM_ROLLOFF_FACTOR" to "0x20008")
+ int("AL_CONE_OUTER_GAINHF" to "0x20009")
+ int("AL_DIRECT_FILTER_GAINHF_AUTO" to "0x2000A")
+ int("AL_AUXILIARY_SEND_FILTER_GAIN_AUTO" to "0x2000B")
+ int("AL_AUXILIARY_SEND_FILTER_GAINHF_AUTO" to "0x2000C")
+
+ int("AL_REVERB_DENSITY" to "0x0001")
+ int("AL_REVERB_DIFFUSION" to "0x0002")
+ int("AL_REVERB_GAIN" to "0x0003")
+ int("AL_REVERB_GAINHF" to "0x0004")
+ int("AL_REVERB_DECAY_TIME" to "0x0005")
+ int("AL_REVERB_DECAY_HFRATIO" to "0x0006")
+ int("AL_REVERB_REFLECTIONS_GAIN" to "0x0007")
+ int("AL_REVERB_REFLECTIONS_DELAY" to "0x0008")
+ int("AL_REVERB_LATE_REVERB_GAIN" to "0x0009")
+ int("AL_REVERB_LATE_REVERB_DELAY" to "0x000A")
+ int("AL_REVERB_AIR_ABSORPTION_GAINHF" to "0x000B")
+ int("AL_REVERB_ROOM_ROLLOFF_FACTOR" to "0x000C")
+ int("AL_REVERB_DECAY_HFLIMIT" to "0x000D")
+
+ int("AL_EAXREVERB_DENSITY" to "0x0001")
+ int("AL_EAXREVERB_DIFFUSION" to "0x0002")
+ int("AL_EAXREVERB_GAIN" to "0x0003")
+ int("AL_EAXREVERB_GAINHF" to "0x0004")
+ int("AL_EAXREVERB_GAINLF" to "0x0005")
+ int("AL_EAXREVERB_DECAY_TIME" to "0x0006")
+ int("AL_EAXREVERB_DECAY_HFRATIO" to "0x0007")
+ int("AL_EAXREVERB_DECAY_LFRATIO" to "0x0008")
+ int("AL_EAXREVERB_REFLECTIONS_GAIN" to "0x0009")
+ int("AL_EAXREVERB_REFLECTIONS_DELAY" to "0x000A")
+ int("AL_EAXREVERB_REFLECTIONS_PAN" to "0x000B")
+ int("AL_EAXREVERB_LATE_REVERB_GAIN" to "0x000C")
+ int("AL_EAXREVERB_LATE_REVERB_DELAY" to "0x000D")
+ int("AL_EAXREVERB_LATE_REVERB_PAN" to "0x000E")
+ int("AL_EAXREVERB_ECHO_TIME" to "0x000F")
+ int("AL_EAXREVERB_ECHO_DEPTH" to "0x0010")
+ int("AL_EAXREVERB_MODULATION_TIME" to "0x0011")
+ int("AL_EAXREVERB_MODULATION_DEPTH" to "0x0012")
+ int("AL_EAXREVERB_AIR_ABSORPTION_GAINHF" to "0x0013")
+ int("AL_EAXREVERB_HFREFERENCE" to "0x0014")
+ int("AL_EAXREVERB_LFREFERENCE" to "0x0015")
+ int("AL_EAXREVERB_ROOM_ROLLOFF_FACTOR" to "0x0016")
+ int("AL_EAXREVERB_DECAY_HFLIMIT" to "0x0017")
+
+ int("AL_CHORUS_WAVEFORM" to "0x0001")
+ int("AL_CHORUS_PHASE" to "0x0002")
+ int("AL_CHORUS_RATE" to "0x0003")
+ int("AL_CHORUS_DEPTH" to "0x0004")
+ int("AL_CHORUS_FEEDBACK" to "0x0005")
+ int("AL_CHORUS_DELAY" to "0x0006")
+
+ int("AL_DISTORTION_EDGE" to "0x0001")
+ int("AL_DISTORTION_GAIN" to "0x0002")
+ int("AL_DISTORTION_LOWPASS_CUTOFF" to "0x0003")
+ int("AL_DISTORTION_EQCENTER" to "0x0004")
+ int("AL_DISTORTION_EQBANDWIDTH" to "0x0005")
+
+ int("AL_ECHO_DELAY" to "0x0001")
+ int("AL_ECHO_LRDELAY" to "0x0002")
+ int("AL_ECHO_DAMPING" to "0x0003")
+ int("AL_ECHO_FEEDBACK" to "0x0004")
+ int("AL_ECHO_SPREAD" to "0x0005")
+
+ int("AL_FLANGER_WAVEFORM" to "0x0001")
+ int("AL_FLANGER_PHASE" to "0x0002")
+ int("AL_FLANGER_RATE" to "0x0003")
+ int("AL_FLANGER_DEPTH" to "0x0004")
+ int("AL_FLANGER_FEEDBACK" to "0x0005")
+ int("AL_FLANGER_DELAY" to "0x0006")
+
+ int("AL_FREQUENCY_SHIFTER_FREQUENCY" to "0x0001")
+ int("AL_FREQUENCY_SHIFTER_LEFT_DIRECTION" to "0x0002")
+ int("AL_FREQUENCY_SHIFTER_RIGHT_DIRECTION" to "0x0003")
+
+ int("AL_VOCAL_MORPHER_PHONEMEA" to "0x0001")
+ int("AL_VOCAL_MORPHER_PHONEMEA_COARSE_TUNING" to "0x0002")
+ int("AL_VOCAL_MORPHER_PHONEMEB" to "0x0003")
+ int("AL_VOCAL_MORPHER_PHONEMEB_COARSE_TUNING" to "0x0004")
+ int("AL_VOCAL_MORPHER_WAVEFORM" to "0x0005")
+ int("AL_VOCAL_MORPHER_RATE" to "0x0006")
+
+ int("AL_PITCH_SHIFTER_COARSE_TUNE" to "0x0001")
+ int("AL_PITCH_SHIFTER_FINE_TUNE" to "0x0002")
+
+ int("AL_RING_MODULATOR_FREQUENCY" to "0x0001")
+ int("AL_RING_MODULATOR_HIGHPASS_CUTOFF" to "0x0002")
+ int("AL_RING_MODULATOR_WAVEFORM" to "0x0003")
+
+ int("AL_AUTOWAH_ATTACK_TIME" to "0x0001")
+ int("AL_AUTOWAH_RELEASE_TIME" to "0x0002")
+ int("AL_AUTOWAH_RESONANCE" to "0x0003")
+ int("AL_AUTOWAH_PEAK_GAIN" to "0x0004")
+
+ int("AL_COMPRESSOR_ONOFF" to "0x0001")
+
+ int("AL_EQUALIZER_LOW_GAIN" to "0x0001")
+ int("AL_EQUALIZER_LOW_CUTOFF" to "0x0002")
+ int("AL_EQUALIZER_MID1_GAIN" to "0x0003")
+ int("AL_EQUALIZER_MID1_CENTER" to "0x0004")
+ int("AL_EQUALIZER_MID1_WIDTH" to "0x0005")
+ int("AL_EQUALIZER_MID2_GAIN" to "0x0006")
+ int("AL_EQUALIZER_MID2_CENTER" to "0x0007")
+ int("AL_EQUALIZER_MID2_WIDTH" to "0x0008")
+ int("AL_EQUALIZER_HIGH_GAIN" to "0x0009")
+ int("AL_EQUALIZER_HIGH_CUTOFF" to "0x000A")
+
+ int("AL_EFFECT_FIRST_PARAMETER" to "0x0000")
+ int("AL_EFFECT_LAST_PARAMETER" to "0x8000")
+ int("AL_EFFECT_TYPE" to "0x8001")
+
+ int("AL_EFFECT_NULL" to "0x0000")
+ int("AL_EFFECT_REVERB" to "0x0001")
+ int("AL_EFFECT_CHORUS" to "0x0002")
+ int("AL_EFFECT_DISTORTION" to "0x0003")
+ int("AL_EFFECT_ECHO" to "0x0004")
+ int("AL_EFFECT_FLANGER" to "0x0005")
+ int("AL_EFFECT_FREQUENCY_SHIFTER" to "0x0006")
+ int("AL_EFFECT_VOCAL_MORPHER" to "0x0007")
+ int("AL_EFFECT_PITCH_SHIFTER" to "0x0008")
+ int("AL_EFFECT_RING_MODULATOR" to "0x0009")
+ int("AL_EFFECT_AUTOWAH" to "0x000A")
+ int("AL_EFFECT_COMPRESSOR" to "0x000B")
+ int("AL_EFFECT_EQUALIZER" to "0x000C")
+ int("AL_EFFECT_EAXREVERB" to "0x8000")
+
+ int("AL_EFFECTSLOT_EFFECT" to "0x0001")
+ int("AL_EFFECTSLOT_GAIN" to "0x0002")
+ int("AL_EFFECTSLOT_AUXILIARY_SEND_AUTO" to "0x0003")
+
+ int("AL_EFFECTSLOT_NULL" to "0x0000")
+
+ int("AL_LOWPASS_GAIN" to "0x0001")
+ int("AL_LOWPASS_GAINHF" to "0x0002")
+
+ int("AL_HIGHPASS_GAIN" to "0x0001")
+ int("AL_HIGHPASS_GAINLF" to "0x0002")
+
+ int("AL_BANDPASS_GAIN" to "0x0001")
+ int("AL_BANDPASS_GAINLF" to "0x0002")
+ int("AL_BANDPASS_GAINHF" to "0x0003")
+
+ int("AL_FILTER_FIRST_PARAMETER" to "0x0000")
+ int("AL_FILTER_LAST_PARAMETER" to "0x8000")
+ int("AL_FILTER_TYPE" to "0x8001")
+
+ int("AL_FILTER_NULL" to "0x0000")
+ int("AL_FILTER_LOWPASS" to "0x0001")
+ int("AL_FILTER_HIGHPASS" to "0x0002")
+ int("AL_FILTER_BANDPASS" to "0x0003")
+
+ "alGenEffects"(void, ALsizei("n"), ALuint_ptr("effects"), entrypoint = "alGenEffects", optional = true)
+ "alDeleteEffects"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("effects"),
+ entrypoint = "alDeleteEffects",
+ optional = true
+ )
+ "alIsEffect"(ALboolean, ALuint("effect"), entrypoint = "alIsEffect", optional = true)
+ "alEffecti"(void, ALuint("effect"), ALenum("param"), ALint("iValue"), entrypoint = "alEffecti", optional = true)
+ "alEffectiv"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ const_ALint_ptr("piValues"),
+ entrypoint = "alEffectiv",
+ optional = true
+ )
+ "alEffectf"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ ALfloat("flValue"),
+ entrypoint = "alEffectf",
+ optional = true
+ )
+ "alEffectfv"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ const_ALfloat_ptr("pflValues"),
+ entrypoint = "alEffectfv",
+ optional = true
+ )
+ "alGetEffecti"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ ALint_ptr("piValue"),
+ entrypoint = "alGetEffecti",
+ optional = true
+ )
+ "alGetEffectiv"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ ALint_ptr("piValues"),
+ entrypoint = "alGetEffectiv",
+ optional = true
+ )
+ "alGetEffectf"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ ALfloat_ptr("pflValue"),
+ entrypoint = "alGetEffectf",
+ optional = true
+ )
+ "alGetEffectfv"(
+ void,
+ ALuint("effect"),
+ ALenum("param"),
+ ALfloat_ptr("pflValues"),
+ entrypoint = "alGetEffectfv",
+ optional = true
+ )
+
+ "alGenFilters"(void, ALsizei("n"), ALuint_ptr("filters"), entrypoint = "alGenFilters", optional = true)
+ "alDeleteFilters"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("filters"),
+ entrypoint = "alDeleteFilters",
+ optional = true
+ )
+ "alIsFilter"(ALboolean, ALuint("filter"), entrypoint = "alIsFilter", optional = true)
+ "alFilteri"(void, ALuint("filter"), ALenum("param"), ALint("iValue"), entrypoint = "alFilteri", optional = true)
+ "alFilteriv"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ const_ALint_ptr("piValues"),
+ entrypoint = "alFilteriv",
+ optional = true
+ )
+ "alFilterf"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ ALfloat("flValue"),
+ entrypoint = "alFilterf",
+ optional = true
+ )
+ "alFilterfv"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ const_ALfloat_ptr("pflValues"),
+ entrypoint = "alFilterfv",
+ optional = true
+ )
+ "alGetFilteri"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ ALint_ptr("piValue"),
+ entrypoint = "alGetFilteri",
+ optional = true
+ )
+ "alGetFilteriv"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ ALint_ptr("piValues"),
+ entrypoint = "alGetFilteriv",
+ optional = true
+ )
+ "alGetFilterf"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ ALfloat_ptr("pflValue"),
+ entrypoint = "alGetFilterf",
+ optional = true
+ )
+ "alGetFilterfv"(
+ void,
+ ALuint("filter"),
+ ALenum("param"),
+ ALfloat_ptr("pflValues"),
+ entrypoint = "alGetFilterfv",
+ optional = true
+ )
+
+ "alGenAuxiliaryEffectSlots"(
+ void,
+ ALsizei("n"),
+ ALuint_ptr("effectslots"),
+ entrypoint = "alGenAuxiliaryEffectSlots",
+ optional = true
+ )
+ "alDeleteAuxiliaryEffectSlots"(
+ void,
+ ALsizei("n"),
+ const_ALuint_ptr("effectslots"),
+ entrypoint = "alDeleteAuxiliaryEffectSlots",
+ optional = true
+ )
+ "alIsAuxiliaryEffectSlot"(
+ ALboolean,
+ ALuint("effectslot"),
+ entrypoint = "alIsAuxiliaryEffectSlot",
+ optional = true
+ )
+ "alAuxiliaryEffectSloti"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALint("iValue"),
+ entrypoint = "alAuxiliaryEffectSloti",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotiv"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ const_ALint_ptr("piValues"),
+ entrypoint = "alAuxiliaryEffectSlotiv",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotf"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALfloat("flValue"),
+ entrypoint = "alAuxiliaryEffectSlotf",
+ optional = true
+ )
+ "alAuxiliaryEffectSlotfv"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ const_ALfloat_ptr("pflValues"),
+ entrypoint = "alAuxiliaryEffectSlotfv",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSloti"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALint_ptr("piValue"),
+ entrypoint = "alGetAuxiliaryEffectSloti",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotiv"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALint_ptr("piValues"),
+ entrypoint = "alGetAuxiliaryEffectSlotiv",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotf"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALfloat_ptr("pflValue"),
+ entrypoint = "alGetAuxiliaryEffectSlotf",
+ optional = true
+ )
+ "alGetAuxiliaryEffectSlotfv"(
+ void,
+ ALuint("effectslot"),
+ ALenum("param"),
+ ALfloat_ptr("pflValues"),
+ entrypoint = "alGetAuxiliaryEffectSlotfv",
+ optional = true
+ )
+
+ float("AL_LOWPASS_MIN_GAIN" to "0.0f")
+ float("AL_LOWPASS_MAX_GAIN" to "1.0f")
+ float("AL_LOWPASS_DEFAULT_GAIN" to "1.0f")
+
+ float("AL_LOWPASS_MIN_GAINHF" to "0.0f")
+ float("AL_LOWPASS_MAX_GAINHF" to "1.0f")
+ float("AL_LOWPASS_DEFAULT_GAINHF" to "1.0f")
+
+ float("AL_HIGHPASS_MIN_GAIN" to "0.0f")
+ float("AL_HIGHPASS_MAX_GAIN" to "1.0f")
+ float("AL_HIGHPASS_DEFAULT_GAIN" to "1.0f")
+
+ float("AL_HIGHPASS_MIN_GAINLF" to "0.0f")
+ float("AL_HIGHPASS_MAX_GAINLF" to "1.0f")
+ float("AL_HIGHPASS_DEFAULT_GAINLF" to "1.0f")
+
+ float("AL_BANDPASS_MIN_GAIN" to "0.0f")
+ float("AL_BANDPASS_MAX_GAIN" to "1.0f")
+ float("AL_BANDPASS_DEFAULT_GAIN" to "1.0f")
+
+ float("AL_BANDPASS_MIN_GAINHF" to "0.0f")
+ float("AL_BANDPASS_MAX_GAINHF" to "1.0f")
+ float("AL_BANDPASS_DEFAULT_GAINHF" to "1.0f")
+
+ float("AL_BANDPASS_MIN_GAINLF" to "0.0f")
+ float("AL_BANDPASS_MAX_GAINLF" to "1.0f")
+ float("AL_BANDPASS_DEFAULT_GAINLF" to "1.0f")
+
+ float("AL_REVERB_MIN_DENSITY" to "0.0f")
+ float("AL_REVERB_MAX_DENSITY" to "1.0f")
+ float("AL_REVERB_DEFAULT_DENSITY" to "1.0f")
+
+ float("AL_REVERB_MIN_DIFFUSION" to "0.0f")
+ float("AL_REVERB_MAX_DIFFUSION" to "1.0f")
+ float("AL_REVERB_DEFAULT_DIFFUSION" to "1.0f")
+
+ float("AL_REVERB_MIN_GAIN" to "0.0f")
+ float("AL_REVERB_MAX_GAIN" to "1.0f")
+ float("AL_REVERB_DEFAULT_GAIN" to "0.32f")
+
+ float("AL_REVERB_MIN_GAINHF" to "0.0f")
+ float("AL_REVERB_MAX_GAINHF" to "1.0f")
+ float("AL_REVERB_DEFAULT_GAINHF" to "0.89f")
+
+ float("AL_REVERB_MIN_DECAY_TIME" to "0.1f")
+ float("AL_REVERB_MAX_DECAY_TIME" to "20.0f")
+ float("AL_REVERB_DEFAULT_DECAY_TIME" to "1.49f")
+
+ float("AL_REVERB_MIN_DECAY_HFRATIO" to "0.1f")
+ float("AL_REVERB_MAX_DECAY_HFRATIO" to "2.0f")
+ float("AL_REVERB_DEFAULT_DECAY_HFRATIO" to "0.83f")
+
+ float("AL_REVERB_MIN_REFLECTIONS_GAIN" to "0.0f")
+ float("AL_REVERB_MAX_REFLECTIONS_GAIN" to "3.16f")
+ float("AL_REVERB_DEFAULT_REFLECTIONS_GAIN" to "0.05f")
+
+ float("AL_REVERB_MIN_REFLECTIONS_DELAY" to "0.0f")
+ float("AL_REVERB_MAX_REFLECTIONS_DELAY" to "0.3f")
+ float("AL_REVERB_DEFAULT_REFLECTIONS_DELAY" to "0.007f")
+
+ float("AL_REVERB_MIN_LATE_REVERB_GAIN" to "0.0f")
+ float("AL_REVERB_MAX_LATE_REVERB_GAIN" to "10.0f")
+ float("AL_REVERB_DEFAULT_LATE_REVERB_GAIN" to "1.26f")
+
+ float("AL_REVERB_MIN_LATE_REVERB_DELAY" to "0.0f")
+ float("AL_REVERB_MAX_LATE_REVERB_DELAY" to "0.1f")
+ float("AL_REVERB_DEFAULT_LATE_REVERB_DELAY" to "0.011f")
+
+ float("AL_REVERB_MIN_AIR_ABSORPTION_GAINHF" to "0.892f")
+ float("AL_REVERB_MAX_AIR_ABSORPTION_GAINHF" to "1.0f")
+ float("AL_REVERB_DEFAULT_AIR_ABSORPTION_GAINHF" to "0.994f")
+
+ float("AL_REVERB_MIN_ROOM_ROLLOFF_FACTOR" to "0.0f")
+ float("AL_REVERB_MAX_ROOM_ROLLOFF_FACTOR" to "10.0f")
+ float("AL_REVERB_DEFAULT_ROOM_ROLLOFF_FACTOR" to "0.0f")
+
+ int("AL_REVERB_MIN_DECAY_HFLIMIT" to "AL.AL_FALSE")
+ int("AL_REVERB_MAX_DECAY_HFLIMIT" to "AL.AL_TRUE")
+ int("AL_REVERB_DEFAULT_DECAY_HFLIMIT" to "AL.AL_TRUE")
+
+ float("AL_EAXREVERB_MIN_DENSITY" to "0.0f")
+ float("AL_EAXREVERB_MAX_DENSITY" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_DENSITY" to "1.0f")
+
+ float("AL_EAXREVERB_MIN_DIFFUSION" to "0.0f")
+ float("AL_EAXREVERB_MAX_DIFFUSION" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_DIFFUSION" to "1.0f")
+
+ float("AL_EAXREVERB_MIN_GAIN" to "0.0f")
+ float("AL_EAXREVERB_MAX_GAIN" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_GAIN" to "0.32f")
+
+ float("AL_EAXREVERB_MIN_GAINHF" to "0.0f")
+ float("AL_EAXREVERB_MAX_GAINHF" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_GAINHF" to "0.89f")
+
+ float("AL_EAXREVERB_MIN_GAINLF" to "0.0f")
+ float("AL_EAXREVERB_MAX_GAINLF" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_GAINLF" to "1.0f")
+
+ float("AL_EAXREVERB_MIN_DECAY_TIME" to "0.1f")
+ float("AL_EAXREVERB_MAX_DECAY_TIME" to "20.0f")
+ float("AL_EAXREVERB_DEFAULT_DECAY_TIME" to "1.49f")
+
+ float("AL_EAXREVERB_MIN_DECAY_HFRATIO" to "0.1f")
+ float("AL_EAXREVERB_MAX_DECAY_HFRATIO" to "2.0f")
+ float("AL_EAXREVERB_DEFAULT_DECAY_HFRATIO" to "0.83f")
+
+ float("AL_EAXREVERB_MIN_DECAY_LFRATIO" to "0.1f")
+ float("AL_EAXREVERB_MAX_DECAY_LFRATIO" to "2.0f")
+ float("AL_EAXREVERB_DEFAULT_DECAY_LFRATIO" to "1.0f")
+
+ float("AL_EAXREVERB_MIN_REFLECTIONS_GAIN" to "0.0f")
+ float("AL_EAXREVERB_MAX_REFLECTIONS_GAIN" to "3.16f")
+ float("AL_EAXREVERB_DEFAULT_REFLECTIONS_GAIN" to "0.05f")
+
+ float("AL_EAXREVERB_MIN_REFLECTIONS_DELAY" to "0.0f")
+ float("AL_EAXREVERB_MAX_REFLECTIONS_DELAY" to "0.3f")
+ float("AL_EAXREVERB_DEFAULT_REFLECTIONS_DELAY" to "0.007f")
+
+ float("AL_EAXREVERB_DEFAULT_REFLECTIONS_PAN_XYZ" to "0.0f")
+
+ float("AL_EAXREVERB_MIN_LATE_REVERB_GAIN" to "0.0f")
+ float("AL_EAXREVERB_MAX_LATE_REVERB_GAIN" to "10.0f")
+ float("AL_EAXREVERB_DEFAULT_LATE_REVERB_GAIN" to "1.26f")
+
+ float("AL_EAXREVERB_MIN_LATE_REVERB_DELAY" to "0.0f")
+ float("AL_EAXREVERB_MAX_LATE_REVERB_DELAY" to "0.1f")
+ float("AL_EAXREVERB_DEFAULT_LATE_REVERB_DELAY" to "0.011f")
+
+ float("AL_EAXREVERB_DEFAULT_LATE_REVERB_PAN_XYZ" to "0.0f")
+
+ float("AL_EAXREVERB_MIN_ECHO_TIME" to "0.075f")
+ float("AL_EAXREVERB_MAX_ECHO_TIME" to "0.25f")
+ float("AL_EAXREVERB_DEFAULT_ECHO_TIME" to "0.25f")
+
+ float("AL_EAXREVERB_MIN_ECHO_DEPTH" to "0.0f")
+ float("AL_EAXREVERB_MAX_ECHO_DEPTH" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_ECHO_DEPTH" to "0.0f")
+
+ float("AL_EAXREVERB_MIN_MODULATION_TIME" to "0.04f")
+ float("AL_EAXREVERB_MAX_MODULATION_TIME" to "4.0f")
+ float("AL_EAXREVERB_DEFAULT_MODULATION_TIME" to "0.25f")
+
+ float("AL_EAXREVERB_MIN_MODULATION_DEPTH" to "0.0f")
+ float("AL_EAXREVERB_MAX_MODULATION_DEPTH" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_MODULATION_DEPTH" to "0.0f")
+
+ float("AL_EAXREVERB_MIN_AIR_ABSORPTION_GAINHF" to "0.892f")
+ float("AL_EAXREVERB_MAX_AIR_ABSORPTION_GAINHF" to "1.0f")
+ float("AL_EAXREVERB_DEFAULT_AIR_ABSORPTION_GAINHF" to "0.994f")
+
+ float("AL_EAXREVERB_MIN_HFREFERENCE" to "1000.0f")
+ float("AL_EAXREVERB_MAX_HFREFERENCE" to "20000.0f")
+ float("AL_EAXREVERB_DEFAULT_HFREFERENCE" to "5000.0f")
+
+ float("AL_EAXREVERB_MIN_LFREFERENCE" to "20.0f")
+ float("AL_EAXREVERB_MAX_LFREFERENCE" to "1000.0f")
+ float("AL_EAXREVERB_DEFAULT_LFREFERENCE" to "250.0f")
+
+ float("AL_EAXREVERB_MIN_ROOM_ROLLOFF_FACTOR" to "0.0f")
+ float("AL_EAXREVERB_MAX_ROOM_ROLLOFF_FACTOR" to "10.0f")
+ float("AL_EAXREVERB_DEFAULT_ROOM_ROLLOFF_FACTOR" to "0.0f")
+
+ int("AL_EAXREVERB_MIN_DECAY_HFLIMIT" to "AL.AL_FALSE")
+ int("AL_EAXREVERB_MAX_DECAY_HFLIMIT" to "AL.AL_TRUE")
+ int("AL_EAXREVERB_DEFAULT_DECAY_HFLIMIT" to "AL.AL_TRUE")
+
+ int("AL_CHORUS_WAVEFORM_SINUSOID" to "0")
+ int("AL_CHORUS_WAVEFORM_TRIANGLE" to "1")
+
+ int("AL_CHORUS_MIN_WAVEFORM" to "0")
+ int("AL_CHORUS_MAX_WAVEFORM" to "1")
+ int("AL_CHORUS_DEFAULT_WAVEFORM" to "1")
+
+ int("AL_CHORUS_MIN_PHASE" to "-180")
+ int("AL_CHORUS_MAX_PHASE" to "180")
+ int("AL_CHORUS_DEFAULT_PHASE" to "90")
+
+ float("AL_CHORUS_MIN_RATE" to "0.0f")
+ float("AL_CHORUS_MAX_RATE" to "10.0f")
+ float("AL_CHORUS_DEFAULT_RATE" to "1.1f")
+
+ float("AL_CHORUS_MIN_DEPTH" to "0.0f")
+ float("AL_CHORUS_MAX_DEPTH" to "1.0f")
+ float("AL_CHORUS_DEFAULT_DEPTH" to "0.1f")
+
+ float("AL_CHORUS_MIN_FEEDBACK" to "-1.0f")
+ float("AL_CHORUS_MAX_FEEDBACK" to "1.0f")
+ float("AL_CHORUS_DEFAULT_FEEDBACK" to "0.25f")
+
+ float("AL_CHORUS_MIN_DELAY" to "0.0f")
+ float("AL_CHORUS_MAX_DELAY" to "0.016f")
+ float("AL_CHORUS_DEFAULT_DELAY" to "0.016f")
+
+ float("AL_DISTORTION_MIN_EDGE" to "0.0f")
+ float("AL_DISTORTION_MAX_EDGE" to "1.0f")
+ float("AL_DISTORTION_DEFAULT_EDGE" to "0.2f")
+
+ float("AL_DISTORTION_MIN_GAIN" to "0.01f")
+ float("AL_DISTORTION_MAX_GAIN" to "1.0f")
+ float("AL_DISTORTION_DEFAULT_GAIN" to "0.05f")
+
+ float("AL_DISTORTION_MIN_LOWPASS_CUTOFF" to "80.0f")
+ float("AL_DISTORTION_MAX_LOWPASS_CUTOFF" to "24000.0f")
+ float("AL_DISTORTION_DEFAULT_LOWPASS_CUTOFF" to "8000.0f")
+
+ float("AL_DISTORTION_MIN_EQCENTER" to "80.0f")
+ float("AL_DISTORTION_MAX_EQCENTER" to "24000.0f")
+ float("AL_DISTORTION_DEFAULT_EQCENTER" to "3600.0f")
+
+ float("AL_DISTORTION_MIN_EQBANDWIDTH" to "80.0f")
+ float("AL_DISTORTION_MAX_EQBANDWIDTH" to "24000.0f")
+ float("AL_DISTORTION_DEFAULT_EQBANDWIDTH" to "3600.0f")
+
+ float("AL_ECHO_MIN_DELAY" to "0.0f")
+ float("AL_ECHO_MAX_DELAY" to "0.207f")
+ float("AL_ECHO_DEFAULT_DELAY" to "0.1f")
+
+ float("AL_ECHO_MIN_LRDELAY" to "0.0f")
+ float("AL_ECHO_MAX_LRDELAY" to "0.404f")
+ float("AL_ECHO_DEFAULT_LRDELAY" to "0.1f")
+
+ float("AL_ECHO_MIN_DAMPING" to "0.0f")
+ float("AL_ECHO_MAX_DAMPING" to "0.99f")
+ float("AL_ECHO_DEFAULT_DAMPING" to "0.5f")
+
+ float("AL_ECHO_MIN_FEEDBACK" to "0.0f")
+ float("AL_ECHO_MAX_FEEDBACK" to "1.0f")
+ float("AL_ECHO_DEFAULT_FEEDBACK" to "0.5f")
+
+ float("AL_ECHO_MIN_SPREAD" to "-1.0f")
+ float("AL_ECHO_MAX_SPREAD" to "1.0f")
+ float("AL_ECHO_DEFAULT_SPREAD" to "-1.0f")
+
+ int("AL_FLANGER_WAVEFORM_SINUSOID" to "0")
+ int("AL_FLANGER_WAVEFORM_TRIANGLE" to "1")
+
+ int("AL_FLANGER_MIN_WAVEFORM" to "0")
+ int("AL_FLANGER_MAX_WAVEFORM" to "1")
+ int("AL_FLANGER_DEFAULT_WAVEFORM" to "1")
+
+ int("AL_FLANGER_MIN_PHASE" to "-180")
+ int("AL_FLANGER_MAX_PHASE" to "180")
+ int("AL_FLANGER_DEFAULT_PHASE" to "0")
+
+ float("AL_FLANGER_MIN_RATE" to "0.0f")
+ float("AL_FLANGER_MAX_RATE" to "10.0f")
+ float("AL_FLANGER_DEFAULT_RATE" to "0.27f")
+
+ float("AL_FLANGER_MIN_DEPTH" to "0.0f")
+ float("AL_FLANGER_MAX_DEPTH" to "1.0f")
+ float("AL_FLANGER_DEFAULT_DEPTH" to "1.0f")
+
+ float("AL_FLANGER_MIN_FEEDBACK" to "-1.0f")
+ float("AL_FLANGER_MAX_FEEDBACK" to "1.0f")
+ float("AL_FLANGER_DEFAULT_FEEDBACK" to "-0.5f")
+
+ float("AL_FLANGER_MIN_DELAY" to "0.0f")
+ float("AL_FLANGER_MAX_DELAY" to "0.004f")
+ float("AL_FLANGER_DEFAULT_DELAY" to "0.002f")
+
+ float("AL_FREQUENCY_SHIFTER_MIN_FREQUENCY" to "0.0f")
+ float("AL_FREQUENCY_SHIFTER_MAX_FREQUENCY" to "24000.0f")
+ float("AL_FREQUENCY_SHIFTER_DEFAULT_FREQUENCY" to "0.0f")
+
+ int("AL_FREQUENCY_SHIFTER_MIN_LEFT_DIRECTION" to "0")
+ int("AL_FREQUENCY_SHIFTER_MAX_LEFT_DIRECTION" to "2")
+ int("AL_FREQUENCY_SHIFTER_DEFAULT_LEFT_DIRECTION" to "0")
+
+ int("AL_FREQUENCY_SHIFTER_DIRECTION_DOWN" to "0")
+ int("AL_FREQUENCY_SHIFTER_DIRECTION_UP" to "1")
+ int("AL_FREQUENCY_SHIFTER_DIRECTION_OFF" to "2")
+
+ int("AL_FREQUENCY_SHIFTER_MIN_RIGHT_DIRECTION" to "0")
+ int("AL_FREQUENCY_SHIFTER_MAX_RIGHT_DIRECTION" to "2")
+ int("AL_FREQUENCY_SHIFTER_DEFAULT_RIGHT_DIRECTION" to "0")
+
+ int("AL_VOCAL_MORPHER_MIN_PHONEMEA" to "0")
+ int("AL_VOCAL_MORPHER_MAX_PHONEMEA" to "29")
+ int("AL_VOCAL_MORPHER_DEFAULT_PHONEMEA" to "0")
+
+ int("AL_VOCAL_MORPHER_MIN_PHONEMEA_COARSE_TUNING" to "-24")
+ int("AL_VOCAL_MORPHER_MAX_PHONEMEA_COARSE_TUNING" to "24")
+ int("AL_VOCAL_MORPHER_DEFAULT_PHONEMEA_COARSE_TUNING" to "0")
+
+ int("AL_VOCAL_MORPHER_MIN_PHONEMEB" to "0")
+ int("AL_VOCAL_MORPHER_MAX_PHONEMEB" to "29")
+ int("AL_VOCAL_MORPHER_DEFAULT_PHONEMEB" to "10")
+
+ int("AL_VOCAL_MORPHER_MIN_PHONEMEB_COARSE_TUNING" to "-24")
+ int("AL_VOCAL_MORPHER_MAX_PHONEMEB_COARSE_TUNING" to "24")
+ int("AL_VOCAL_MORPHER_DEFAULT_PHONEMEB_COARSE_TUNING" to "0")
+
+ int("AL_VOCAL_MORPHER_PHONEME_A" to "0")
+ int("AL_VOCAL_MORPHER_PHONEME_E" to "1")
+ int("AL_VOCAL_MORPHER_PHONEME_I" to "2")
+ int("AL_VOCAL_MORPHER_PHONEME_O" to "3")
+ int("AL_VOCAL_MORPHER_PHONEME_U" to "4")
+ int("AL_VOCAL_MORPHER_PHONEME_AA" to "5")
+ int("AL_VOCAL_MORPHER_PHONEME_AE" to "6")
+ int("AL_VOCAL_MORPHER_PHONEME_AH" to "7")
+ int("AL_VOCAL_MORPHER_PHONEME_AO" to "8")
+ int("AL_VOCAL_MORPHER_PHONEME_EH" to "9")
+ int("AL_VOCAL_MORPHER_PHONEME_ER" to "10")
+ int("AL_VOCAL_MORPHER_PHONEME_IH" to "11")
+ int("AL_VOCAL_MORPHER_PHONEME_IY" to "12")
+ int("AL_VOCAL_MORPHER_PHONEME_UH" to "13")
+ int("AL_VOCAL_MORPHER_PHONEME_UW" to "14")
+ int("AL_VOCAL_MORPHER_PHONEME_B" to "15")
+ int("AL_VOCAL_MORPHER_PHONEME_D" to "16")
+ int("AL_VOCAL_MORPHER_PHONEME_F" to "17")
+ int("AL_VOCAL_MORPHER_PHONEME_G" to "18")
+ int("AL_VOCAL_MORPHER_PHONEME_J" to "19")
+ int("AL_VOCAL_MORPHER_PHONEME_K" to "20")
+ int("AL_VOCAL_MORPHER_PHONEME_L" to "21")
+ int("AL_VOCAL_MORPHER_PHONEME_M" to "22")
+ int("AL_VOCAL_MORPHER_PHONEME_N" to "23")
+ int("AL_VOCAL_MORPHER_PHONEME_P" to "24")
+ int("AL_VOCAL_MORPHER_PHONEME_R" to "25")
+ int("AL_VOCAL_MORPHER_PHONEME_S" to "26")
+ int("AL_VOCAL_MORPHER_PHONEME_T" to "27")
+ int("AL_VOCAL_MORPHER_PHONEME_V" to "28")
+ int("AL_VOCAL_MORPHER_PHONEME_Z" to "29")
+
+ int("AL_VOCAL_MORPHER_WAVEFORM_SINUSOID" to "0")
+ int("AL_VOCAL_MORPHER_WAVEFORM_TRIANGLE" to "1")
+ int("AL_VOCAL_MORPHER_WAVEFORM_SAWTOOTH" to "2")
+
+ int("AL_VOCAL_MORPHER_MIN_WAVEFORM" to "0")
+ int("AL_VOCAL_MORPHER_MAX_WAVEFORM" to "2")
+ int("AL_VOCAL_MORPHER_DEFAULT_WAVEFORM" to "0")
+
+ float("AL_VOCAL_MORPHER_MIN_RATE" to "0.0f")
+ float("AL_VOCAL_MORPHER_MAX_RATE" to "10.0f")
+ float("AL_VOCAL_MORPHER_DEFAULT_RATE" to "1.41f")
+
+ int("AL_PITCH_SHIFTER_MIN_COARSE_TUNE" to "-12")
+ int("AL_PITCH_SHIFTER_MAX_COARSE_TUNE" to "12")
+ int("AL_PITCH_SHIFTER_DEFAULT_COARSE_TUNE" to "12")
+
+ int("AL_PITCH_SHIFTER_MIN_FINE_TUNE" to "-50")
+ int("AL_PITCH_SHIFTER_MAX_FINE_TUNE" to "50")
+ int("AL_PITCH_SHIFTER_DEFAULT_FINE_TUNE" to "0")
+
+ float("AL_RING_MODULATOR_MIN_FREQUENCY" to "0.0f")
+ float("AL_RING_MODULATOR_MAX_FREQUENCY" to "8000.0f")
+ float("AL_RING_MODULATOR_DEFAULT_FREQUENCY" to "440.0f")
+
+ float("AL_RING_MODULATOR_MIN_HIGHPASS_CUTOFF" to "0.0f")
+ float("AL_RING_MODULATOR_MAX_HIGHPASS_CUTOFF" to "24000.0f")
+ float("AL_RING_MODULATOR_DEFAULT_HIGHPASS_CUTOFF" to "800.0f")
+
+ int("AL_RING_MODULATOR_SINUSOID" to "0")
+ int("AL_RING_MODULATOR_SAWTOOTH" to "1")
+ int("AL_RING_MODULATOR_SQUARE" to "2")
+
+ int("AL_RING_MODULATOR_MIN_WAVEFORM" to "0")
+ int("AL_RING_MODULATOR_MAX_WAVEFORM" to "2")
+ int("AL_RING_MODULATOR_DEFAULT_WAVEFORM" to "0")
+
+ float("AL_AUTOWAH_MIN_ATTACK_TIME" to "0.0001f")
+ float("AL_AUTOWAH_MAX_ATTACK_TIME" to "1.0f")
+ float("AL_AUTOWAH_DEFAULT_ATTACK_TIME" to "0.06f")
+
+ float("AL_AUTOWAH_MIN_RELEASE_TIME" to "0.0001f")
+ float("AL_AUTOWAH_MAX_RELEASE_TIME" to "1.0f")
+ float("AL_AUTOWAH_DEFAULT_RELEASE_TIME" to "0.06f")
+
+ float("AL_AUTOWAH_MIN_RESONANCE" to "2.0f")
+ float("AL_AUTOWAH_MAX_RESONANCE" to "1000.0f")
+ float("AL_AUTOWAH_DEFAULT_RESONANCE" to "1000.0f")
+
+ float("AL_AUTOWAH_MIN_PEAK_GAIN" to "0.00003f")
+ float("AL_AUTOWAH_MAX_PEAK_GAIN" to "31621.0f")
+ float("AL_AUTOWAH_DEFAULT_PEAK_GAIN" to "11.22f")
+
+ int("AL_COMPRESSOR_MIN_ONOFF" to "0")
+ int("AL_COMPRESSOR_MAX_ONOFF" to "1")
+ int("AL_COMPRESSOR_DEFAULT_ONOFF" to "1")
+
+ float("AL_EQUALIZER_MIN_LOW_GAIN" to "0.126f")
+ float("AL_EQUALIZER_MAX_LOW_GAIN" to "7.943f")
+ float("AL_EQUALIZER_DEFAULT_LOW_GAIN" to "1.0f")
+
+ float("AL_EQUALIZER_MIN_LOW_CUTOFF" to "50.0f")
+ float("AL_EQUALIZER_MAX_LOW_CUTOFF" to "800.0f")
+ float("AL_EQUALIZER_DEFAULT_LOW_CUTOFF" to "200.0f")
+
+ float("AL_EQUALIZER_MIN_MID1_GAIN" to "0.126f")
+ float("AL_EQUALIZER_MAX_MID1_GAIN" to "7.943f")
+ float("AL_EQUALIZER_DEFAULT_MID1_GAIN" to "1.0f")
+
+ float("AL_EQUALIZER_MIN_MID1_CENTER" to "200.0f")
+ float("AL_EQUALIZER_MAX_MID1_CENTER" to "3000.0f")
+ float("AL_EQUALIZER_DEFAULT_MID1_CENTER" to "500.0f")
+
+ float("AL_EQUALIZER_MIN_MID1_WIDTH" to "0.01f")
+ float("AL_EQUALIZER_MAX_MID1_WIDTH" to "1.0f")
+ float("AL_EQUALIZER_DEFAULT_MID1_WIDTH" to "1.0f")
+
+ float("AL_EQUALIZER_MIN_MID2_GAIN" to "0.126f")
+ float("AL_EQUALIZER_MAX_MID2_GAIN" to "7.943f")
+ float("AL_EQUALIZER_DEFAULT_MID2_GAIN" to "1.0f")
+
+ float("AL_EQUALIZER_MIN_MID2_CENTER" to "1000.0f")
+ float("AL_EQUALIZER_MAX_MID2_CENTER" to "8000.0f")
+ float("AL_EQUALIZER_DEFAULT_MID2_CENTER" to "3000.0f")
+
+ float("AL_EQUALIZER_MIN_MID2_WIDTH" to "0.01f")
+ float("AL_EQUALIZER_MAX_MID2_WIDTH" to "1.0f")
+ float("AL_EQUALIZER_DEFAULT_MID2_WIDTH" to "1.0f")
+
+ float("AL_EQUALIZER_MIN_HIGH_GAIN" to "0.126f")
+ float("AL_EQUALIZER_MAX_HIGH_GAIN" to "7.943f")
+ float("AL_EQUALIZER_DEFAULT_HIGH_GAIN" to "1.0f")
+
+ float("AL_EQUALIZER_MIN_HIGH_CUTOFF" to "4000.0f")
+ float("AL_EQUALIZER_MAX_HIGH_CUTOFF" to "16000.0f")
+ float("AL_EQUALIZER_DEFAULT_HIGH_CUTOFF" to "6000.0f")
+
+ float("AL_MIN_AIR_ABSORPTION_FACTOR" to "0.0f")
+ float("AL_MAX_AIR_ABSORPTION_FACTOR" to "10.0f")
+ float("AL_DEFAULT_AIR_ABSORPTION_FACTOR" to "0.0f")
+
+ float("AL_MIN_ROOM_ROLLOFF_FACTOR" to "0.0f")
+ float("AL_MAX_ROOM_ROLLOFF_FACTOR" to "10.0f")
+ float("AL_DEFAULT_ROOM_ROLLOFF_FACTOR" to "0.0f")
+
+ float("AL_MIN_CONE_OUTER_GAINHF" to "0.0f")
+ float("AL_MAX_CONE_OUTER_GAINHF" to "1.0f")
+ float("AL_DEFAULT_CONE_OUTER_GAINHF" to "1.0f")
+
+ int("AL_MIN_DIRECT_FILTER_GAINHF_AUTO" to "AL.AL_FALSE")
+ int("AL_MAX_DIRECT_FILTER_GAINHF_AUTO" to "AL.AL_TRUE")
+ int("AL_DEFAULT_DIRECT_FILTER_GAINHF_AUTO" to "AL.AL_TRUE")
+
+ int("AL_MIN_AUXILIARY_SEND_FILTER_GAIN_AUTO" to "AL.AL_FALSE")
+ int("AL_MAX_AUXILIARY_SEND_FILTER_GAIN_AUTO" to "AL.AL_TRUE")
+ int("AL_DEFAULT_AUXILIARY_SEND_FILTER_GAIN_AUTO" to "AL.AL_TRUE")
+
+ int("AL_MIN_AUXILIARY_SEND_FILTER_GAINHF_AUTO" to "AL.AL_FALSE")
+ int("AL_MAX_AUXILIARY_SEND_FILTER_GAINHF_AUTO" to "AL.AL_TRUE")
+ int("AL_DEFAULT_AUXILIARY_SEND_FILTER_GAINHF_AUTO" to "AL.AL_TRUE")
+
+ float("AL_MIN_METERS_PER_UNIT" to "Float.MIN_VALUE")
+ float("AL_MAX_METERS_PER_UNIT" to "Float.MAX_VALUE")
+ float("AL_DEFAULT_METERS_PER_UNIT" to "1.0f")
+ }
+}
diff --git a/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt b/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt
index a909fdca..29ac909e 100644
--- a/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt
+++ b/generators/openal/src/main/kotlin/overrungl/openal/OpenALGenerator.kt
@@ -31,17 +31,26 @@ val ALenum = int c "ALenum"
val ALfloat = float c "ALfloat"
val ALdouble = double c "ALdouble"
+val ALvoid_ptr = address c "ALvoid *"
+val ALvoid_ptr_ptr = address c "ALvoid **"
val ALboolean_ptr = address c "ALboolean *"
+val ALchar_ptr = string_u8 c "ALchar*"
val ALint_ptr = jint_array c "ALint *"
val ALuint_ptr = jint_array c "ALuint *"
+val ALsizei_ptr = jint_array c "ALsizei *"
+val ALenum_ptr = jint_array c "ALenum *"
val ALfloat_ptr = jfloat_array c "ALfloat *"
val ALdouble_ptr = jdouble_array c "ALdouble *"
+val const_ALuint = uint c "const ALuint"
+
val const_ALvoid_ptr = address c "const ALvoid *"
val const_ALchar_ptr = string_u8 c "const ALchar*"
val const_ALint_ptr = address c "const ALint *"
val const_ALuint_ptr = address c "const ALuint *"
+val const_ALenum_ptr = address c "const ALenum *"
val const_ALfloat_ptr = address c "const ALfloat *"
+val const_ALdouble_ptr = address c "const ALdouble *"
val ALCdevice_ptr = address c "ALCdevice *"
@@ -66,6 +75,21 @@ val ALCint_ptr = jint_array c "ALCint *"
val const_ALCvoid_ptr = address c "const ALCvoid *"
val const_ALCchar_ptr = string_u8 c "const ALCchar*"
val const_ALCint_ptr = address c "const ALCint *"
+val const_ALCenum_ptr = address c "const ALCenum *"
+
+val ALint64SOFT = jlong c "ALint64SOFT"
+val ALuint64SOFT = jlong c "ALuint64SOFT"
+val ALint64SOFT_ptr = address c "ALint64SOFT *"
+val ALuint64SOFT_ptr = address c "ALuint64SOFT *"
+val const_ALint64SOFT_ptr = address c "const ALint64SOFT *"
+val const_ALuint64SOFT_ptr = address c "const ALuint64SOFT *"
+
+val ALCint64SOFT = jlong c "ALCint64SOFT"
+val ALCuint64SOFT = jlong c "ALCuint64SOFT"
+val ALCint64SOFT_ptr = address c "ALCint64SOFT *"
+val ALCuint64SOFT_ptr = address c "ALCuint64SOFT *"
+val const_ALCint64SOFT_ptr = address c "const ALCint64SOFT *"
+val const_ALCuint64SOFT_ptr = address c "const ALCuint64SOFT *"
const val alPackage = "overrungl.openal"
@@ -74,4 +98,6 @@ const val alLookup = "ALInternal.lookup()"
fun main() {
AL()
ALC()
+ alext()
+ efx()
}
diff --git a/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt b/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt
index c37b35a1..d79246f3 100644
--- a/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt
+++ b/generators/opengl/src/main/kotlin/overrungl/opengl/OpenGLGenerator.kt
@@ -765,7 +765,7 @@ fun main() {
if (extension.requires.isNotEmpty()) {
val vendor = extension.name.substring(3).substringBefore('_')
val className = extension.name.split('_')
- .joinToString("") { it.replaceFirstChar(Char::uppercase) }
+ .joinToString("") { it.replaceFirstChar(Char::uppercaseChar) }
InstanceDowncall(extPackage(vendor), className) {
modifier = "final"
if (extension.requires.all { it.commands.isEmpty() }) {
diff --git a/generators/src/main/kotlin/overrungl/gen/CustomTypeSpec.kt b/generators/src/main/kotlin/overrungl/gen/CustomTypeSpec.kt
index 049c0419..12b27e2b 100644
--- a/generators/src/main/kotlin/overrungl/gen/CustomTypeSpec.kt
+++ b/generators/src/main/kotlin/overrungl/gen/CustomTypeSpec.kt
@@ -124,3 +124,5 @@ val short_ptr = jshort_array c "short*"
val int_ptr = jint_array c "int*"
val float_ptr = jfloat_array c "float*"
val double_ptr = jdouble_array c "double*"
+
+val void_ptr_ptr = address c "void**"
diff --git a/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt b/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt
index 44c6dd95..82e80986 100644
--- a/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt
+++ b/generators/src/main/kotlin/overrungl/gen/StaticDowncall.kt
@@ -24,6 +24,7 @@ class StaticDowncall(
packageName: String,
name: String,
private val symbolLookup: String,
+ private val writeWholeFile: Boolean = false,
action: StaticDowncall.() -> Unit
) {
private val fields = mutableListOf()
@@ -87,6 +88,34 @@ class StaticDowncall(
fun write(packageName: String, name: String) {
val path = Path("${packageName.replace('.', '/')}/$name.java")
+ val wholeFile = StringBuilder()
+ if (writeWholeFile) {
+ wholeFile.appendLine(commentedFileHeader)
+ wholeFile.appendLine("package $packageName;")
+ if (methods.isNotEmpty()) {
+ wholeFile.appendLine(
+ """
+ import java.lang.foreign.*;
+ import java.lang.invoke.*;
+ import overrungl.annotation.*;
+ import overrungl.internal.*;
+ import overrungl.util.*;
+ """.trimIndent()
+ )
+ }
+ wholeFile.appendLine(
+ """
+ public final class $name {
+ $GENERATOR_BEGIN
+ $GENERATOR_END
+
+ private $name() {
+ }
+ }
+ """.trimIndent()
+ )
+ }
+
val sb = StringBuilder()
sb.appendLine(formatter_off)
@@ -98,175 +127,172 @@ class StaticDowncall(
}
sb.appendLine(" //endregion")
- // method handles
- sb.appendLine(" //region Method handles")
- sb.appendLine(" /// Method handles.")
- sb.appendLine(" public static final class Handles {")
- sb.appendLine(" private Handles() { }")
- mutableListOf().also { l ->
- methods.forEach {
- if (it.entrypoint != null) {
- val functionDescriptor = it.functionDescriptor
- val indexOf = l.indexOfFirst { e -> e.entrypoint == it.entrypoint }
- val m1 = if (indexOf != -1) l[indexOf] else null
- if (m1 != null) {
- if (functionDescriptor != m1.functionDescriptor) {
- error("Redefining method ${it.name} (entrypoint ${it.entrypoint}, descriptor $functionDescriptor) with method ${m1.name} (entrypoint ${m1.entrypoint}, descriptor ${m1.functionDescriptor})")
- }
- } else {
- sb.appendLine(
- """
+ if (methods.isNotEmpty()) {
+ // method handles
+ sb.appendLine(" //region Method handles")
+ sb.appendLine(" /// Method handles.")
+ sb.appendLine(" public static final class Handles {")
+ sb.appendLine(" private Handles() { }")
+ mutableListOf().also { l ->
+ methods.forEach {
+ if (it.entrypoint != null) {
+ val functionDescriptor = it.functionDescriptor
+ val indexOf = l.indexOfFirst { e -> e.entrypoint == it.entrypoint }
+ val m1 = if (indexOf != -1) l[indexOf] else null
+ if (m1 != null) {
+ if (functionDescriptor != m1.functionDescriptor) {
+ error("Redefining method ${it.name} (entrypoint ${it.entrypoint}, descriptor $functionDescriptor) with method ${m1.name} (entrypoint ${m1.entrypoint}, descriptor ${m1.functionDescriptor})")
+ }
+ } else {
+ sb.appendLine(
+ """
| /// The method handle of `${it.entrypoint}`.
| public static final MethodHandle MH_${it.entrypoint} = RuntimeHelper.${if (it.optional) "downcallOrNull" else "downcall"}($symbolLookup, "${it.entrypoint}", $functionDescriptor);
""".trimMargin()
- )
- l.add(it)
+ )
+ l.add(it)
+ }
}
}
}
- }
- sb.appendLine(" }")
- sb.appendLine(" //endregion")
+ sb.appendLine(" }")
+ sb.appendLine(" //endregion")
- sb.appendLine()
+ sb.appendLine()
- // methods
- methods.forEach { m ->
- val chosenReturnType = m.returnType.selectTypeName(m.overload)
- val returnVoid = chosenReturnType == TypeName.VOID
- if (m.javadoc != null) {
- sb.appendLine(m.javadoc.prependIndent(" ///"))
- }
- sb.appendLine(
- " public static ${m.returnType.typeNameWithC(chosenReturnType)} ${m.name}(${
- m.parameters.joinToString { p ->
- p.toString(p.type.selectTypeName(m.overload))
- }
- }) {"
- )
- if (m.code != null) {
- sb.appendLine(m.code.prependIndent(" "))
- } else {
- val finalAllocatorRequirement = if (m.overload) m.allocatorRequirement else AllocatorRequirement.NO
- val allocatorParam: DowncallParameter? = if (m.overload) when (finalAllocatorRequirement) {
- AllocatorRequirement.NO -> null
-
- AllocatorRequirement.STACK ->
- m.parameters.firstOrNull { p ->
- p.type.javaType == Arena_ || p.type.javaType == SegmentAllocator_
+ // methods
+ methods.forEach { m ->
+ val chosenReturnType = m.returnType.selectTypeName(m.overload)
+ val returnVoid = chosenReturnType == TypeName.VOID
+ if (m.javadoc != null) {
+ sb.appendLine(m.javadoc.prependIndent(" ///"))
+ }
+ sb.appendLine(
+ " public static ${m.returnType.typeNameWithC(chosenReturnType)} ${m.name}(${
+ m.parameters.joinToString { p ->
+ p.toString(p.type.selectTypeName(m.overload))
}
+ }) {"
+ )
+ if (m.code != null) {
+ sb.appendLine(m.code.prependIndent(" "))
+ } else {
+ val finalAllocatorRequirement = if (m.overload) m.allocatorRequirement else AllocatorRequirement.NO
+ val allocatorParam: DowncallParameter? = if (m.overload) when (finalAllocatorRequirement) {
+ AllocatorRequirement.NO -> null
- AllocatorRequirement.BY_VALUE_SEGMENT_ALLOCATOR, AllocatorRequirement.SEGMENT_ALLOCATOR ->
- m.parameters.firstOrNull { p ->
- p.type.javaType == Arena_ || p.type.javaType == SegmentAllocator_
- } ?: error("A segment allocator or an Arena is required by ${m.name}")
-
- AllocatorRequirement.ARENA ->
- m.parameters.firstOrNull { p ->
- p.type.javaType == Arena_
- } ?: error("An arena is required by ${m.name}")
- } else null
- val useMemStack = finalAllocatorRequirement == AllocatorRequirement.STACK && allocatorParam == null
- val allocatorName = if (useMemStack) "__overrungl_stack" else allocatorParam?.name
- val refParams = m.parameters.filter { p -> p.marshalRef(m.overload) }
- val writtenParams =
- m.parameters.map { p ->
- if (p.marshalRef(m.overload)) DowncallParameter(address, "__overrungl_ref_${p.name}")
- else p
- }
-
- // optional
- if (m.optional) {
- sb.appendLine(" if (Handles.MH_${m.entrypoint} != null) {")
- }
+ AllocatorRequirement.STACK ->
+ m.parameters.firstOrNull { p ->
+ p.type.javaType == Arena_ || p.type.javaType == SegmentAllocator_
+ }
- // header
- sb.append(" try ")
- if (useMemStack) {
- sb.append("(var __overrungl_stack = MemoryStack.pushLocal()) ")
- }
- sb.appendLine("{")
-
- // ref
- refParams.forEach { p ->
- sb.append(" var __overrungl_ref_${p.name} = ")
- p.type.processor.marshal(
- ProcessorContext(
- allocatorName = allocatorName, sb
- ) { it.append(p.name) })
- sb.appendLine(";")
- }
+ AllocatorRequirement.BY_VALUE_SEGMENT_ALLOCATOR, AllocatorRequirement.SEGMENT_ALLOCATOR ->
+ m.parameters.firstOrNull { p ->
+ p.type.javaType == Arena_ || p.type.javaType == SegmentAllocator_
+ } ?: error("A segment allocator or an Arena is required by ${m.name}")
+
+ AllocatorRequirement.ARENA ->
+ m.parameters.firstOrNull { p ->
+ p.type.javaType == Arena_
+ } ?: error("An arena is required by ${m.name}")
+ } else null
+ val useMemStack = finalAllocatorRequirement == AllocatorRequirement.STACK && allocatorParam == null
+ val allocatorName = if (useMemStack) "__overrungl_stack" else allocatorParam?.name
+ val refParams = m.parameters.filter { p -> p.marshalRef(m.overload) }
+ val writtenParams =
+ m.parameters.map { p ->
+ if (p.marshalRef(m.overload)) DowncallParameter(address, "__overrungl_ref_${p.name}")
+ else p
+ }
- // invocation
- sb.append(" ")
- if (!returnVoid) {
- if (refParams.isNotEmpty()) {
- sb.append("var __overrungl_result = ")
- } else {
- sb.append("return ")
+ // optional
+ if (m.optional) {
+ sb.appendLine(" if (Handles.MH_${m.entrypoint} != null) {")
}
- }
- val invocation = { b: StringBuilder ->
- if (!returnVoid) {
- b.append("(${m.returnType.carrier}) ")
+
+ // header
+ sb.append(" try ")
+ if (useMemStack) {
+ sb.append("(var __overrungl_stack = MemoryStack.pushLocal()) ")
}
- b.append("Handles.MH_${m.entrypoint}.invokeExact(")
- b.append(writtenParams.joinToString { p ->
- if (m.overload) {
- buildString {
- p.type.processor.marshal(
- ProcessorContext(
- allocatorName = allocatorName,
- this
- ) { it.append(p.name) })
- }
- } else p.name
- })
- b.append(")")
- Unit
- }
- if (m.overload) {
- m.returnType.processor.unmarshal(ProcessorContext(allocatorName = null, sb, invocation))
- } else {
- invocation(sb)
- }
- sb.appendLine(";")
+ sb.appendLine("{")
- // ref
- if (refParams.isNotEmpty()) {
+ // ref
refParams.forEach { p ->
- sb.append(" ")
- p.type.processor.copy(
+ sb.append(" var __overrungl_ref_${p.name} = ")
+ p.type.processor.marshal(
ProcessorContext(
- allocatorName = null,
- sb
- ) { it.append("__overrungl_ref_${p.name}, ${p.name}") })
+ allocatorName = allocatorName, sb
+ ) { it.append(p.name) })
sb.appendLine(";")
}
+
+ // invocation
+ sb.append(" ")
if (!returnVoid) {
- sb.appendLine(" return __overrungl_result;")
+ if (refParams.isNotEmpty()) {
+ sb.append("var __overrungl_result = ")
+ } else {
+ sb.append("return ")
+ }
}
- }
+ val invocation = { b: StringBuilder ->
+ if (!returnVoid) {
+ b.append("(${m.returnType.carrier}) ")
+ }
+ b.append("Handles.MH_${m.entrypoint}.invokeExact(")
+ b.append(writtenParams.joinToString { p ->
+ if (m.overload) {
+ buildString {
+ p.type.processor.marshal(
+ ProcessorContext(
+ allocatorName = allocatorName,
+ this
+ ) { it.append(p.name) })
+ }
+ } else p.name
+ })
+ b.append(")")
+ Unit
+ }
+ if (m.overload) {
+ m.returnType.processor.unmarshal(ProcessorContext(allocatorName = null, sb, invocation))
+ } else {
+ invocation(sb)
+ }
+ sb.appendLine(";")
- sb.appendLine(""" } catch (Throwable e) { throw new RuntimeException("error in ${m.entrypoint}", e); }""")
+ // ref
+ if (refParams.isNotEmpty()) {
+ refParams.forEach { p ->
+ sb.append(" ")
+ p.type.processor.copy(
+ ProcessorContext(
+ allocatorName = null,
+ sb
+ ) { it.append("__overrungl_ref_${p.name}, ${p.name}") })
+ sb.appendLine(";")
+ }
+ if (!returnVoid) {
+ sb.appendLine(" return __overrungl_result;")
+ }
+ }
- if (m.optional) {
- sb.append(" }")
- if (m.defaultCode != null) {
- sb.appendLine(" else {")
- sb.appendLine(m.defaultCode.prependIndent(" "))
- sb.append(" }")
+ sb.appendLine(""" } catch (Throwable e) { throw new RuntimeException("error in ${m.entrypoint}", e); }""")
+
+ if (m.optional) {
+ sb.appendLine(""" } else { throw new SymbolNotFoundError("Symbol not found: ${m.entrypoint}"); }""")
}
- sb.appendLine()
}
+ sb.appendLine(" }")
+ sb.appendLine()
}
- sb.appendLine(" }")
- sb.appendLine()
}
sb.appendLine(formatter_on)
- writeString(path, replaceCode(Files.readString(path), sb.toString()))
+ val replaceSrc = if (writeWholeFile) wholeFile.toString() else Files.readString(path)
+ writeString(path, replaceCode(replaceSrc, sb.toString()))
}
}
diff --git a/modules/overrungl.core/src/main/java/module-info.java b/modules/overrungl.core/src/main/java/module-info.java
index fe784f3b..8ee624f8 100644
--- a/modules/overrungl.core/src/main/java/module-info.java
+++ b/modules/overrungl.core/src/main/java/module-info.java
@@ -29,6 +29,7 @@
exports overrungl.internal
to overrungl.glfw,
overrungl.nfd,
+ overrungl.openal,
overrungl.opengl,
overrungl.stb,
overrungl.vulkan;
diff --git a/modules/overrungl.core/src/main/java/overrungl/util/SymbolNotFoundError.java b/modules/overrungl.core/src/main/java/overrungl/util/SymbolNotFoundError.java
new file mode 100644
index 00000000..405e01d8
--- /dev/null
+++ b/modules/overrungl.core/src/main/java/overrungl/util/SymbolNotFoundError.java
@@ -0,0 +1,37 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+package overrungl.util;
+
+/**
+ * Indicates that a symbol of a function in a native library was not found.
+ *
+ * @author squid233
+ * @since 0.1.0
+ */
+public class SymbolNotFoundError extends Error {
+ /**
+ * Constructs a new error with the specified detail message. The
+ * cause is not initialized, and may subsequently be initialized by
+ * a call to {@link #initCause}.
+ *
+ * @param message the detail message. The detail message is saved for
+ * later retrieval by the {@link #getMessage()} method.
+ */
+ public SymbolNotFoundError(String message) {
+ super(message);
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/module-info.java b/modules/overrungl.openal/src/main/java/module-info.java
new file mode 100644
index 00000000..df3b621e
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/module-info.java
@@ -0,0 +1,29 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+/// The [OpenAL](https://www.openal.org/) binding.
+///
+/// OverrunGL uses [openal-soft](https://openal-soft.org/).
+///
+/// - [Source](https://github.com/kcat/openal-soft)
+///
+/// @author squid233
+/// @since 0.1.0
+module overrungl.openal {
+ exports overrungl.openal;
+
+ requires transitive overrungl.core;
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
index e524208b..fb6facb7 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/AL.java
@@ -24,6 +24,7 @@
import overrungl.util.Unmarshal;
import java.lang.foreign.FunctionDescriptor;
+import java.lang.foreign.SymbolLookup;
import java.lang.foreign.ValueLayout;
import java.lang.invoke.MethodHandle;
@@ -37,282 +38,67 @@ public final class AL {
//region ---[BEGIN GENERATOR BEGIN]---
//@formatter:off
//region Fields
- ///No distance model or no buffer
public static final int AL_NONE = 0;
- ///Boolean False.
public static final int AL_FALSE = 0;
- ///Boolean True.
public static final int AL_TRUE = 1;
- ///Relative source.
- ///- Type: ALboolean
- ///- Range: \[AL_FALSE, AL_TRUE\]
- ///- Default: AL_FALSE
- ///
- ///Specifies if the source uses relative coordinates.
public static final int AL_SOURCE_RELATIVE = 0x202;
- ///Inner cone angle, in degrees.
- ///- Type: ALint, ALfloat
- ///- Range: \[0 - 360\]
- ///- Default: 360
- ///
- ///The angle covered by the inner cone, the area within which the source will
- ///not be attenuated by direction.
public static final int AL_CONE_INNER_ANGLE = 0x1001;
- ///Outer cone angle, in degrees.
- ///- Range: \[0 - 360\]
- ///- Default: 360
- ///
- ///The angle covered by the outer cone, the area outside of which the source
- ///will be fully attenuated by direction.
public static final int AL_CONE_OUTER_ANGLE = 0x1002;
- ///Source pitch.
- ///- Type: ALfloat
- ///- Range: \[0.5 - 2.0\]
- ///- Default: 1.0
- ///
- ///A multiplier for the sample rate of the source's buffer.
public static final int AL_PITCH = 0x1003;
- ///Source or listener position.
- ///- Type: ALfloat\[3\], ALint\[3\]
- ///- Default: {0, 0, 0}
- ///
- ///The source or listener location in three dimensional space.
- ///
- ///OpenAL uses a right handed coordinate system, like OpenGL, where with a
- ///default view, X points right (thumb), Y points up (index finger), and Z
- ///points towards the viewer/camera (middle finger).
- ///
- ///To change from or to a left handed coordinate system, negate the Z
- ///component.
public static final int AL_POSITION = 0x1004;
- ///Source direction.
- ///- Type: ALfloat\[3\], ALint\[3\]
- ///- Default: {0, 0, 0}
- ///
- ///Specifies the current direction in local space. A zero-length vector
- ///specifies an omni-directional source (cone is ignored).
- ///
- ///To change from or to a left handed coordinate system, negate the Z
- ///component.
public static final int AL_DIRECTION = 0x1005;
- ///Source or listener velocity.
- ///- Type: ALfloat\[3\], ALint\[3]\
- ///- Default: {0, 0, 0}
- ///
- ///Specifies the current velocity, relative to the position.
- ///
- ///To change from or to a left handed coordinate system, negate the Z
- ///component.
public static final int AL_VELOCITY = 0x1006;
- ///Source looping.
- ///- Type: ALboolean
- ///- Range: \[AL_FALSE, AL_TRUE\]
- ///- Default: AL_FALSE
- ///
- ///Specifies whether source playback loops.
public static final int AL_LOOPING = 0x1007;
- ///Source buffer.
- ///- Type: ALuint
- ///- Range: any valid Buffer ID
- ///- Default: AL_NONE
- ///
- ///Specifies the buffer to provide sound samples for a source.
public static final int AL_BUFFER = 0x1009;
- ///Source or listener gain.
- ///- Type: ALfloat
- ///- Range: \[0.0 - \]
- ///
- ///For sources, an initial linear gain value (before attenuation is applied).
- ///For the listener, an output linear gain adjustment.
- ///
- ///A value of 1.0 means unattenuated. Each division by 2 equals an attenuation
- ///of about -6dB. Each multiplication by 2 equals an amplification of about
- ///+6dB.
public static final int AL_GAIN = 0x100A;
- ///Minimum source gain.
- ///- Type: ALfloat
- ///- Range: \[0.0 - 1.0\]
- ///
- ///The minimum gain allowed for a source, after distance and cone attenuation
- ///are applied (if applicable).
public static final int AL_MIN_GAIN = 0x100D;
- ///Maximum source gain.
- ///- Type: ALfloat
- ///- Range: \[0.0 - 1.0\]
- ///
- ///The maximum gain allowed for a source, after distance and cone attenuation
- ///are applied (if applicable).
public static final int AL_MAX_GAIN = 0x100E;
- ///Listener orientation.
- ///- Type: ALfloat\[6\]
- ///- Default: {0.0, 0.0, -1.0, 0.0, 1.0, 0.0}
- ///
- ///Effectively two three dimensional vectors. The first vector is the front (or
- ///"at") and the second is the top (or "up"). Both vectors are relative to the
- ///listener position.
- ///
- ///To change from or to a left handed coordinate system, negate the Z
- ///component of both vectors.
public static final int AL_ORIENTATION = 0x100F;
- ///Source state (query only).
- ///- Type: ALenum
- ///- Range: \[AL_INITIAL, AL_PLAYING, AL_PAUSED, AL_STOPPED\]
public static final int AL_SOURCE_STATE = 0x1010;
- ///Source state values.
public static final int
AL_INITIAL = 0x1011,
AL_PLAYING = 0x1012,
AL_PAUSED = 0x1013,
AL_STOPPED = 0x1014;
- ///Source Buffer Queue size (query only).
- ///- Type: ALint
- ///
- ///The number of buffers queued using alSourceQueueBuffers, minus the buffers
- ///removed with alSourceUnqueueBuffers.
public static final int AL_BUFFERS_QUEUED = 0x1015;
- ///Source Buffer Queue processed count (query only).
- ///- Type: ALint
- ///
- ///The number of queued buffers that have been fully processed, and can be
- ///removed with alSourceUnqueueBuffers.
- ///
- ///Looping sources will never fully process buffers because they will be set to
- ///play again for when the source loops.
public static final int AL_BUFFERS_PROCESSED = 0x1016;
- ///Source reference distance.
- ///- Type: ALfloat
- ///- Range: \[0.0 - \]
- ///- Default: 1.0
- ///
- ///The distance in units that no distance attenuation occurs.
- ///
- ///At 0.0, no distance attenuation occurs with non-linear attenuation models.
public static final int AL_REFERENCE_DISTANCE = 0x1020;
- ///Source rolloff factor.
- ///- Type: ALfloat
- ///- Range: \[0.0 - \]
- ///- Default: 1.0
- ///
- ///Multiplier to exaggerate or diminish distance attenuation.
- ///
- ///At 0.0, no distance attenuation ever occurs.
public static final int AL_ROLLOFF_FACTOR = 0x1021;
- ///Outer cone gain.
- ///- Type: ALfloat
- ///- Range: \[0.0 - 1.0\]
- ///- Default: 0.0
- ///
- ///The gain attenuation applied when the listener is outside of the source's
- ///outer cone angle.
public static final int AL_CONE_OUTER_GAIN = 0x1022;
- ///Source maximum distance.
- ///- Type: ALfloat
- ///- Range: \[0.0 - \]
- ///- Default: FLT_MAX
- ///
- ///The distance above which the source is not attenuated any further with a
- ///clamped distance model, or where attenuation reaches 0.0 gain for linear
- ///distance models with a default rolloff factor.
public static final int AL_MAX_DISTANCE = 0x1023;
- ///Source buffer offset, in seconds
public static final int AL_SEC_OFFSET = 0x1024;
- ///Source buffer offset, in sample frames
public static final int AL_SAMPLE_OFFSET = 0x1025;
- ///Source buffer offset, in bytes
public static final int AL_BYTE_OFFSET = 0x1026;
- ///Source type (query only).
- ///- Type: ALenum
- ///- Range: \[AL_STATIC, AL_STREAMING, AL_UNDETERMINED\]
- ///
- ///A Source is Static if a Buffer has been attached using AL_BUFFER.
- ///
- ///A Source is Streaming if one or more Buffers have been attached using
- ///alSourceQueueBuffers.
- ///
- ///A Source is Undetermined when it has the NULL buffer attached using
- ///AL_BUFFER.
public static final int AL_SOURCE_TYPE = 0x1027;
- ///Source type values.
public static final int
AL_STATIC = 0x1028,
AL_STREAMING = 0x1029,
AL_UNDETERMINED = 0x1030;
- ///Unsigned 8-bit mono buffer format.
public static final int AL_FORMAT_MONO8 = 0x1100;
- ///Signed 16-bit mono buffer format.
public static final int AL_FORMAT_MONO16 = 0x1101;
- ///Unsigned 8-bit stereo buffer format.
public static final int AL_FORMAT_STEREO8 = 0x1102;
- ///Signed 16-bit stereo buffer format.
public static final int AL_FORMAT_STEREO16 = 0x1103;
- ///Buffer frequency/sample rate (query only).
public static final int AL_FREQUENCY = 0x2001;
- ///Buffer bits per sample (query only).
public static final int AL_BITS = 0x2002;
- ///Buffer channel count (query only).
public static final int AL_CHANNELS = 0x2003;
- ///Buffer data size in bytes (query only).
public static final int AL_SIZE = 0x2004;
- ///Buffer state. Not for public use.
public static final int
AL_UNUSED = 0x2010,
AL_PENDING = 0x2011,
AL_PROCESSED = 0x2012;
- ///No error.
public static final int AL_NO_ERROR = 0;
- ///Invalid name (ID) passed to an AL call.
public static final int AL_INVALID_NAME = 0xA001;
- ///Invalid enumeration passed to AL call.
public static final int AL_INVALID_ENUM = 0xA002;
- ///Invalid value passed to AL call.
public static final int AL_INVALID_VALUE = 0xA003;
- ///Illegal AL call.
public static final int AL_INVALID_OPERATION = 0xA004;
- ///Not enough memory to execute the AL call.
public static final int AL_OUT_OF_MEMORY = 0xA005;
- ///Context string: Vendor name.
public static final int AL_VENDOR = 0xB001;
- ///Context string: Version.
public static final int AL_VERSION = 0xB002;
- ///Context string: Renderer name.
public static final int AL_RENDERER = 0xB003;
- ///Context string: Space-separated extension list.
public static final int AL_EXTENSIONS = 0xB004;
- ///Doppler scale.
- ///- Type: ALfloat
- ///- Range: \[0.0 - \]
- ///- Default: 1.0
- ///
- ///Scale for source and listener velocities.
public static final int AL_DOPPLER_FACTOR = 0xC000;
- ///Doppler velocity (deprecated).
- ///
- ///A multiplier applied to the Speed of Sound.
public static final int AL_DOPPLER_VELOCITY = 0xC001;
- ///Speed of Sound, in units per second.
- ///- Type: ALfloat
- ///- Range: \[0.0001 - \]
- ///- Default: 343.3
- ///
- ///The speed at which sound waves are assumed to travel, when calculating the
- ///doppler effect from source and listener velocities.
public static final int AL_SPEED_OF_SOUND = 0xC003;
- ///Distance attenuation model.
- ///- Type: ALenum
- ///- Range: \[AL_NONE, AL_INVERSE_DISTANCE, AL_INVERSE_DISTANCE_CLAMPED,
- /// AL_LINEAR_DISTANCE, AL_LINEAR_DISTANCE_CLAMPED,
- /// AL_EXPONENT_DISTANCE, AL_EXPONENT_DISTANCE_CLAMPED\]
- ///- Default: AL_INVERSE_DISTANCE_CLAMPED
- ///
- ///The model by which sources attenuate with distance.
- ///
- ///- None - No distance attenuation.
- ///- Inverse - Doubling the distance halves the source gain.
- ///- Linear - Linear gain scaling between the reference and max distances.
- ///- Exponent - Exponential gain dropoff.
- ///
- ///Clamped variations work like the non-clamped counterparts, except the
- ///distance calculated is clamped between the reference and max distances.
public static final int AL_DISTANCE_MODEL = 0xD000;
///Distance model values.
public static final int
@@ -602,52 +388,42 @@ public static void alGetDoublev(@CType("ALenum") int param, @Out @CType("ALdoubl
} catch (Throwable e) { throw new RuntimeException("error in alGetDouble", e); }
}
- ///Obtain the first error generated in the AL context since the last call to
- ///this function.
public static @CType("ALenum") int alGetError() {
try {
return (int) Handles.MH_alGetError.invokeExact();
} catch (Throwable e) { throw new RuntimeException("error in alGetError", e); }
}
- ///Query for the presence of an extension on the AL context.
public static @CType("ALboolean") boolean alIsExtensionPresent(@CType("const ALchar*") java.lang.foreign.MemorySegment extname) {
try {
return (boolean) Handles.MH_alIsExtensionPresent.invokeExact(extname);
} catch (Throwable e) { throw new RuntimeException("error in alIsExtensionPresent", e); }
}
- ///Query for the presence of an extension on the AL context.
public static @CType("ALboolean") boolean alIsExtensionPresent(@CType("const ALchar*") java.lang.String extname) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (boolean) Handles.MH_alIsExtensionPresent.invokeExact(Marshal.marshal(__overrungl_stack, extname));
} catch (Throwable e) { throw new RuntimeException("error in alIsExtensionPresent", e); }
}
- ///Retrieve the address of a function. The returned function may be context-
- ///specific.
public static @CType("void*") java.lang.foreign.MemorySegment alGetProcAddress(@CType("const ALchar*") java.lang.foreign.MemorySegment fname) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alGetProcAddress.invokeExact(fname);
} catch (Throwable e) { throw new RuntimeException("error in alGetProcAddress", e); }
}
- ///Retrieve the address of a function. The returned function may be context-
- ///specific.
public static @CType("void*") java.lang.foreign.MemorySegment alGetProcAddress(@CType("const ALchar*") java.lang.String fname) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (java.lang.foreign.MemorySegment) Handles.MH_alGetProcAddress.invokeExact(Marshal.marshal(__overrungl_stack, fname));
} catch (Throwable e) { throw new RuntimeException("error in alGetProcAddress", e); }
}
- ///Retrieve the value of an enum. The returned value may be context-specific.
public static @CType("ALenum") int alGetEnumValue(@CType("const ALchar*") java.lang.foreign.MemorySegment ename) {
try {
return (int) Handles.MH_alGetEnumValue.invokeExact(ename);
} catch (Throwable e) { throw new RuntimeException("error in alGetEnumValue", e); }
}
- ///Retrieve the value of an enum. The returned value may be context-specific.
public static @CType("ALenum") int alGetEnumValue(@CType("const ALchar*") java.lang.String ename) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (int) Handles.MH_alGetEnumValue.invokeExact(Marshal.marshal(__overrungl_stack, ename));
@@ -782,21 +558,18 @@ public static void alGetListeneriv(@CType("ALenum") int param, @Out @CType("ALin
} catch (Throwable e) { throw new RuntimeException("error in alGetListeneriv", e); }
}
- ///Create source objects.
public static void alGenSources(@CType("ALsizei") int n, @Out @CType("ALuint *") java.lang.foreign.MemorySegment sources) {
try {
Handles.MH_alGenSources.invokeExact(n, sources);
} catch (Throwable e) { throw new RuntimeException("error in alGenSources", e); }
}
- ///Delete source objects.
public static void alDeleteSources(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
Handles.MH_alDeleteSources.invokeExact(n, sources);
} catch (Throwable e) { throw new RuntimeException("error in alDeleteSources", e); }
}
- ///Verify an ID is for a valid source.
public static @CType("ALboolean") boolean alIsSource(@CType("ALuint") int source) {
try {
return (boolean) Handles.MH_alIsSource.invokeExact(source);
@@ -931,99 +704,84 @@ public static void alGetSourceiv(@CType("ALuint") int source, @CType("ALenum") i
} catch (Throwable e) { throw new RuntimeException("error in alGetSourceiv", e); }
}
- ///Play, restart, or resume a source, setting its state to AL_PLAYING.
public static void alSourcePlay(@CType("ALuint") int source) {
try {
Handles.MH_alSourcePlay.invokeExact(source);
} catch (Throwable e) { throw new RuntimeException("error in alSourcePlay", e); }
}
- ///Stop a source, setting its state to AL_STOPPED if playing or paused.
public static void alSourceStop(@CType("ALuint") int source) {
try {
Handles.MH_alSourceStop.invokeExact(source);
} catch (Throwable e) { throw new RuntimeException("error in alSourceStop", e); }
}
- ///Rewind a source, setting its state to AL_INITIAL.
public static void alSourceRewind(@CType("ALuint") int source) {
try {
Handles.MH_alSourceRewind.invokeExact(source);
} catch (Throwable e) { throw new RuntimeException("error in alSourceRewind", e); }
}
- ///Pause a source, setting its state to AL_PAUSED if playing.
public static void alSourcePause(@CType("ALuint") int source) {
try {
Handles.MH_alSourcePause.invokeExact(source);
} catch (Throwable e) { throw new RuntimeException("error in alSourcePause", e); }
}
- ///Play, restart, or resume a list of sources atomically.
public static void alSourcePlayv(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
Handles.MH_alSourcePlayv.invokeExact(n, sources);
} catch (Throwable e) { throw new RuntimeException("error in alSourcePlayv", e); }
}
- ///Stop a list of sources atomically.
public static void alSourceStopv(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
Handles.MH_alSourceStopv.invokeExact(n, sources);
} catch (Throwable e) { throw new RuntimeException("error in alSourceStopv", e); }
}
- ///Rewind a list of sources atomically.
public static void alSourceRewindv(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
Handles.MH_alSourceRewindv.invokeExact(n, sources);
} catch (Throwable e) { throw new RuntimeException("error in alSourceRewindv", e); }
}
- ///Pause a list of sources atomically.
public static void alSourcePausev(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
try {
Handles.MH_alSourcePausev.invokeExact(n, sources);
} catch (Throwable e) { throw new RuntimeException("error in alSourcePausev", e); }
}
- ///Queue buffers onto a source
public static void alSourceQueueBuffers(@CType("ALuint") int source, @CType("ALsizei") int nb, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers) {
try {
Handles.MH_alSourceQueueBuffers.invokeExact(source, nb, buffers);
} catch (Throwable e) { throw new RuntimeException("error in alSourceQueueBuffers", e); }
}
- ///Unqueue processed buffers from a source
public static void alSourceUnqueueBuffers(@CType("ALuint") int source, @CType("ALsizei") int nb, @Out @CType("ALuint *") java.lang.foreign.MemorySegment buffers) {
try {
Handles.MH_alSourceUnqueueBuffers.invokeExact(source, nb, buffers);
} catch (Throwable e) { throw new RuntimeException("error in alSourceUnqueueBuffers", e); }
}
- ///Create buffer objects
public static void alGenBuffers(@CType("ALsizei") int n, @Out @CType("ALuint *") java.lang.foreign.MemorySegment buffers) {
try {
Handles.MH_alGenBuffers.invokeExact(n, buffers);
} catch (Throwable e) { throw new RuntimeException("error in alGenBuffers", e); }
}
- ///Delete buffer objects
public static void alDeleteBuffers(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers) {
try {
Handles.MH_alDeleteBuffers.invokeExact(n, buffers);
} catch (Throwable e) { throw new RuntimeException("error in alDeleteBuffers", e); }
}
- ///Verify an ID is a valid buffer (including the NULL buffer)
public static @CType("ALboolean") boolean alIsBuffer(@CType("ALuint") int source) {
try {
return (boolean) Handles.MH_alIsBuffer.invokeExact(source);
} catch (Throwable e) { throw new RuntimeException("error in alIsBuffer", e); }
}
- ///Copies data into the buffer, interpreting it using the specified format and
- ///samplerate.
public static void alBufferData(@CType("ALuint") int buffer, @CType("ALenum") int format, @CType("const ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int size, @CType("ALsizei") int samplerate) {
try {
Handles.MH_alBufferData.invokeExact(buffer, format, data, size, samplerate);
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALBufferCallbackTypeSOFT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALBufferCallbackTypeSOFT.java
new file mode 100644
index 00000000..f0f2a555
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALBufferCallbackTypeSOFT.java
@@ -0,0 +1,53 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.upcall.*;
+import overrungl.util.*;
+
+@FunctionalInterface
+public interface ALBufferCallbackTypeSOFT extends Upcall {
+ /// The function descriptor.
+ FunctionDescriptor DESCRIPTOR = FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT);
+ /// The method handle of the target method.
+ MethodHandle HANDLE = Upcall.findTarget(ALBufferCallbackTypeSOFT.class, "invoke", DESCRIPTOR);
+
+ ///The target method of the upcall.
+ @CType("ALsizei") int invoke(@CType("ALvoid *") java.lang.foreign.MemorySegment userptr, @CType("ALvoid *") java.lang.foreign.MemorySegment sampledata, @CType("ALsizei") int numbytes);
+
+ @Override
+ default MemorySegment stub(Arena arena) { return Linker.nativeLinker().upcallStub(HANDLE.bindTo(this), DESCRIPTOR, arena); }
+
+ ///A static invoker of the target method.
+ ///@param stub the upcall stub
+ static @CType("ALsizei") int invoke(MemorySegment stub, @CType("ALvoid *") java.lang.foreign.MemorySegment userptr, @CType("ALvoid *") java.lang.foreign.MemorySegment sampledata, @CType("ALsizei") int numbytes) {
+ try { return (int) HANDLE.invokeExact(stub, userptr, sampledata, numbytes); }
+ catch (Throwable e) { throw new RuntimeException("error in ALBufferCallbackTypeSOFT::invoke (static invoker)", e); }
+ }
+
+ /// A wrapper for the target method.
+ /// @param stub the upcall stub
+ /// @return an instance that wraps the static invoker
+ static ALBufferCallbackTypeSOFT wrap(MemorySegment stub) {
+ return (userptr, sampledata, numbytes) ->
+ invoke(stub, userptr, sampledata, numbytes);
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
index e30b3e23..d6f579e8 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALC.java
@@ -36,68 +36,33 @@ public final class ALC {
//region ---[BEGIN GENERATOR BEGIN]---
//@formatter:off
//region Fields
- ///Boolean False.
public static final int ALC_FALSE = 0;
- ///Boolean True.
public static final int ALC_TRUE = 1;
- ///Context attribute: <int> Hz.
public static final int ALC_FREQUENCY = 0x1007;
- ///Context attribute: <int> Hz.
public static final int ALC_REFRESH = 0x1008;
- ///Context attribute: AL_TRUE or AL_FALSE synchronous context?
public static final int ALC_SYNC = 0x1009;
- ///Context attribute: <int> requested Mono (3D) Sources.
public static final int ALC_MONO_SOURCES = 0x1010;
- ///Context attribute: <int> requested Stereo Sources.
public static final int ALC_STEREO_SOURCES = 0x1011;
- ///No error.
public static final int ALC_NO_ERROR = 0;
- ///Invalid device handle.
public static final int ALC_INVALID_DEVICE = 0xA001;
- ///Invalid context handle.
public static final int ALC_INVALID_CONTEXT = 0xA002;
- ///Invalid enumeration passed to an ALC call.
public static final int ALC_INVALID_ENUM = 0xA003;
- ///Invalid value passed to an ALC call.
public static final int ALC_INVALID_VALUE = 0xA004;
- ///Out of memory.
public static final int ALC_OUT_OF_MEMORY = 0xA005;
- ///Runtime ALC major version.
public static final int ALC_MAJOR_VERSION = 0x1000;
- ///Runtime ALC minor version.
public static final int ALC_MINOR_VERSION = 0x1001;
- ///Context attribute list size.
public static final int ALC_ATTRIBUTES_SIZE = 0x1002;
- ///Context attribute list properties.
public static final int ALC_ALL_ATTRIBUTES = 0x1003;
- ///String for the default device specifier.
public static final int ALC_DEFAULT_DEVICE_SPECIFIER = 0x1004;
- ///Device specifier string.
- ///
- ///If device handle is NULL, it is instead a null-character separated list of
- ///strings of known device specifiers (list ends with an empty string).
public static final int ALC_DEVICE_SPECIFIER = 0x1005;
- ///String for space-separated list of ALC extensions.
public static final int ALC_EXTENSIONS = 0x1006;
///Capture extension
public static final int ALC_EXT_CAPTURE = 1;
- ///Capture device specifier string.
- ///
- ///If device handle is NULL, it is instead a null-character separated list of
- ///strings of known capture device specifiers (list ends with an empty string).
public static final int ALC_CAPTURE_DEVICE_SPECIFIER = 0x310;
- ///String for the default capture device specifier.
public static final int ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER = 0x311;
- ///Number of sample frames available for capture.
public static final int ALC_CAPTURE_SAMPLES = 0x312;
- ///Enumerate All extension
public static final int ALC_ENUMERATE_ALL_EXT = 1;
- ///String for the default extended device specifier.
public static final int ALC_DEFAULT_ALL_DEVICES_SPECIFIER = 0x1012;
- ///Device's extended specifier string.
- ///
- ///If device handle is NULL, it is instead a null-character separated list of
- ///strings of known extended device specifiers (list ends with an empty string).
public static final int ALC_ALL_DEVICES_SPECIFIER = 0x1013;
//endregion
//region Method handles
@@ -147,191 +112,156 @@ private Handles() { }
}
//endregion
- ///Create and attach a context to the given device.
public static @CType("ALCcontext *") java.lang.foreign.MemorySegment alcCreateContext(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCint *") java.lang.foreign.MemorySegment attrlist) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcCreateContext.invokeExact(device, attrlist);
} catch (Throwable e) { throw new RuntimeException("error in alcCreateContext", e); }
}
- ///Makes the given context the active process-wide context. Passing NULL clears
- ///the active context.
public static @CType("ALCboolean") boolean alcMakeContextCurrent(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
return (boolean) Handles.MH_alcMakeContextCurrent.invokeExact(context);
} catch (Throwable e) { throw new RuntimeException("error in alcMakeContextCurrent", e); }
}
- ///Resumes processing updates for the given context.
public static void alcProcessContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
Handles.MH_alcProcessContext.invokeExact(context);
} catch (Throwable e) { throw new RuntimeException("error in alcProcessContext", e); }
}
- ///Suspends updates for the given context.
public static void alcSuspendContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
Handles.MH_alcSuspendContext.invokeExact(context);
} catch (Throwable e) { throw new RuntimeException("error in alcSuspendContext", e); }
}
- ///Remove a context from its device and destroys it.
public static void alcDestroyContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
Handles.MH_alcDestroyContext.invokeExact(context);
} catch (Throwable e) { throw new RuntimeException("error in alcDestroyContext", e); }
}
- ///Returns the currently active context.
public static @CType("ALCcontext *") java.lang.foreign.MemorySegment alcGetCurrentContext() {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcGetCurrentContext.invokeExact();
} catch (Throwable e) { throw new RuntimeException("error in alcGetCurrentContext", e); }
}
- ///Returns the device that a particular context is attached to.
public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcGetContextsDevice(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcGetContextsDevice.invokeExact(context);
} catch (Throwable e) { throw new RuntimeException("error in alcGetContextsDevice", e); }
}
- ///Opens the named playback device.
public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcOpenDevice(@CType("const ALCchar*") java.lang.foreign.MemorySegment devicename) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcOpenDevice.invokeExact(devicename);
} catch (Throwable e) { throw new RuntimeException("error in alcOpenDevice", e); }
}
- ///Opens the named playback device.
public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcOpenDevice(@CType("const ALCchar*") java.lang.String devicename) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (java.lang.foreign.MemorySegment) Handles.MH_alcOpenDevice.invokeExact(Marshal.marshal(__overrungl_stack, devicename));
} catch (Throwable e) { throw new RuntimeException("error in alcOpenDevice", e); }
}
- ///Closes the given playback device.
public static @CType("ALCboolean") boolean alcCloseDevice(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
return (boolean) Handles.MH_alcCloseDevice.invokeExact(device);
} catch (Throwable e) { throw new RuntimeException("error in alcCloseDevice", e); }
}
- ///Obtain the most recent Device error.
public static @CType("ALCenum") int alcGetError(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
return (int) Handles.MH_alcGetError.invokeExact(device);
} catch (Throwable e) { throw new RuntimeException("error in alcGetError", e); }
}
- ///Query for the presence of an extension on the device. Pass a NULL device to
- ///query a device-inspecific extension.
public static @CType("ALCboolean") boolean alcIsExtensionPresent(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment extname) {
try {
return (boolean) Handles.MH_alcIsExtensionPresent.invokeExact(device, extname);
} catch (Throwable e) { throw new RuntimeException("error in alcIsExtensionPresent", e); }
}
- ///Query for the presence of an extension on the device. Pass a NULL device to
- ///query a device-inspecific extension.
public static @CType("ALCboolean") boolean alcIsExtensionPresent(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.String extname) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (boolean) Handles.MH_alcIsExtensionPresent.invokeExact(device, Marshal.marshal(__overrungl_stack, extname));
} catch (Throwable e) { throw new RuntimeException("error in alcIsExtensionPresent", e); }
}
- ///Retrieve the address of a function. Given a non-NULL device, the returned
- ///function may be device-specific.
public static @CType("ALCvoid *") java.lang.foreign.MemorySegment alcGetProcAddress(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment funcname) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcGetProcAddress.invokeExact(device, funcname);
} catch (Throwable e) { throw new RuntimeException("error in alcGetProcAddress", e); }
}
- ///Retrieve the address of a function. Given a non-NULL device, the returned
- ///function may be device-specific.
public static @CType("ALCvoid *") java.lang.foreign.MemorySegment alcGetProcAddress(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.String funcname) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (java.lang.foreign.MemorySegment) Handles.MH_alcGetProcAddress.invokeExact(device, Marshal.marshal(__overrungl_stack, funcname));
} catch (Throwable e) { throw new RuntimeException("error in alcGetProcAddress", e); }
}
- ///Retrieve the value of an enum. Given a non-NULL device, the returned value
- ///may be device-specific.
public static @CType("ALCenum") int alcGetEnumValue(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment enumname) {
try {
return (int) Handles.MH_alcGetEnumValue.invokeExact(device, enumname);
} catch (Throwable e) { throw new RuntimeException("error in alcGetEnumValue", e); }
}
- ///Retrieve the value of an enum. Given a non-NULL device, the returned value
- ///may be device-specific.
public static @CType("ALCenum") int alcGetEnumValue(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.String enumname) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (int) Handles.MH_alcGetEnumValue.invokeExact(device, Marshal.marshal(__overrungl_stack, enumname));
} catch (Throwable e) { throw new RuntimeException("error in alcGetEnumValue", e); }
}
- ///Returns information about the device, and error strings.
public static @CType("const ALCchar*") java.lang.foreign.MemorySegment alcGetString_(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int param) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcGetString.invokeExact(device, param);
} catch (Throwable e) { throw new RuntimeException("error in alcGetString", e); }
}
- ///Returns information about the device, and error strings.
public static @CType("const ALCchar*") java.lang.String alcGetString(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int param) {
try {
return Unmarshal.unmarshalAsString((java.lang.foreign.MemorySegment) Handles.MH_alcGetString.invokeExact(device, param));
} catch (Throwable e) { throw new RuntimeException("error in alcGetString", e); }
}
- ///Returns information about the device and the version of OpenAL.
public static void alcGetIntegerv(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int param, @CType("ALCsizei") int size, @CType("ALCint *") java.lang.foreign.MemorySegment values) {
try {
Handles.MH_alcGetIntegerv.invokeExact(device, param, size, values);
} catch (Throwable e) { throw new RuntimeException("error in alcGetIntegerv", e); }
}
- ///Opens the named capture device with the given frequency, format, and buffer
- ///size.
public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcCaptureOpenDevice(@CType("const ALCchar*") java.lang.foreign.MemorySegment devicename, @CType("ALCuint") int frequency, @CType("ALCenum") int format, @CType("ALCsizei") int buffersize) {
try {
return (java.lang.foreign.MemorySegment) Handles.MH_alcCaptureOpenDevice.invokeExact(devicename, frequency, format, buffersize);
} catch (Throwable e) { throw new RuntimeException("error in alcCaptureOpenDevice", e); }
}
- ///Opens the named capture device with the given frequency, format, and buffer
- ///size.
public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcCaptureOpenDevice(@CType("const ALCchar*") java.lang.String devicename, @CType("ALCuint") int frequency, @CType("ALCenum") int format, @CType("ALCsizei") int buffersize) {
try (var __overrungl_stack = MemoryStack.pushLocal()) {
return (java.lang.foreign.MemorySegment) Handles.MH_alcCaptureOpenDevice.invokeExact(Marshal.marshal(__overrungl_stack, devicename), frequency, format, buffersize);
} catch (Throwable e) { throw new RuntimeException("error in alcCaptureOpenDevice", e); }
}
- ///Closes the given capture device.
public static @CType("ALCboolean") boolean alcCaptureCloseDevice(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
return (boolean) Handles.MH_alcCaptureCloseDevice.invokeExact(device);
} catch (Throwable e) { throw new RuntimeException("error in alcCaptureCloseDevice", e); }
}
- ///Starts capturing samples into the device buffer.
public static void alcCaptureStart(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
Handles.MH_alcCaptureStart.invokeExact(device);
} catch (Throwable e) { throw new RuntimeException("error in alcCaptureStart", e); }
}
- ///Stops capturing samples. Samples in the device buffer remain available.
public static void alcCaptureStop(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
try {
Handles.MH_alcCaptureStop.invokeExact(device);
} catch (Throwable e) { throw new RuntimeException("error in alcCaptureStop", e); }
}
- ///Reads samples from the device buffer.
public static void alcCaptureSamples(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCvoid *") java.lang.foreign.MemorySegment buffer, @CType("ALCsizei") int samples) {
try {
Handles.MH_alcCaptureSamples.invokeExact(device, buffer, samples);
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEDICATED.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEDICATED.java
new file mode 100644
index 00000000..a43e2456
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEDICATED.java
@@ -0,0 +1,32 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCEXTDEDICATED {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_DEDICATED_GAIN = 0x0001;
+ public static final int AL_EFFECT_DEDICATED_DIALOGUE = 0x9001;
+ public static final int AL_EFFECT_DEDICATED_LOW_FREQUENCY_EFFECT = 0x9000;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCEXTDEDICATED() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEFAULTFILTERORDER.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEFAULTFILTERORDER.java
new file mode 100644
index 00000000..92895c40
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDEFAULTFILTERORDER.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCEXTDEFAULTFILTERORDER {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_DEFAULT_FILTER_ORDER = 0x1100;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCEXTDEFAULTFILTERORDER() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDebug.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDebug.java
new file mode 100644
index 00000000..59b8f2fd
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDebug.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCEXTDebug {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_CONTEXT_FLAGS_EXT = 0x19CF;
+ public static final int ALC_CONTEXT_DEBUG_BIT_EXT = 0x0001;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCEXTDebug() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDisconnect.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDisconnect.java
new file mode 100644
index 00000000..a6ae965a
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTDisconnect.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCEXTDisconnect {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_CONNECTED = 0x313;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCEXTDisconnect() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTEFX.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTEFX.java
new file mode 100644
index 00000000..5cbcab6c
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTEFX.java
@@ -0,0 +1,848 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCEXTEFX {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final java.lang.String ALC_EXT_EFX_NAME = "ALC_EXT_EFX";
+ public static final int ALC_EFX_MAJOR_VERSION = 0x20001;
+ public static final int ALC_EFX_MINOR_VERSION = 0x20002;
+ public static final int ALC_MAX_AUXILIARY_SENDS = 0x20003;
+ public static final int AL_METERS_PER_UNIT = 0x20004;
+ public static final int AL_DIRECT_FILTER = 0x20005;
+ public static final int AL_AUXILIARY_SEND_FILTER = 0x20006;
+ public static final int AL_AIR_ABSORPTION_FACTOR = 0x20007;
+ public static final int AL_ROOM_ROLLOFF_FACTOR = 0x20008;
+ public static final int AL_CONE_OUTER_GAINHF = 0x20009;
+ public static final int AL_DIRECT_FILTER_GAINHF_AUTO = 0x2000A;
+ public static final int AL_AUXILIARY_SEND_FILTER_GAIN_AUTO = 0x2000B;
+ public static final int AL_AUXILIARY_SEND_FILTER_GAINHF_AUTO = 0x2000C;
+ public static final int AL_REVERB_DENSITY = 0x0001;
+ public static final int AL_REVERB_DIFFUSION = 0x0002;
+ public static final int AL_REVERB_GAIN = 0x0003;
+ public static final int AL_REVERB_GAINHF = 0x0004;
+ public static final int AL_REVERB_DECAY_TIME = 0x0005;
+ public static final int AL_REVERB_DECAY_HFRATIO = 0x0006;
+ public static final int AL_REVERB_REFLECTIONS_GAIN = 0x0007;
+ public static final int AL_REVERB_REFLECTIONS_DELAY = 0x0008;
+ public static final int AL_REVERB_LATE_REVERB_GAIN = 0x0009;
+ public static final int AL_REVERB_LATE_REVERB_DELAY = 0x000A;
+ public static final int AL_REVERB_AIR_ABSORPTION_GAINHF = 0x000B;
+ public static final int AL_REVERB_ROOM_ROLLOFF_FACTOR = 0x000C;
+ public static final int AL_REVERB_DECAY_HFLIMIT = 0x000D;
+ public static final int AL_EAXREVERB_DENSITY = 0x0001;
+ public static final int AL_EAXREVERB_DIFFUSION = 0x0002;
+ public static final int AL_EAXREVERB_GAIN = 0x0003;
+ public static final int AL_EAXREVERB_GAINHF = 0x0004;
+ public static final int AL_EAXREVERB_GAINLF = 0x0005;
+ public static final int AL_EAXREVERB_DECAY_TIME = 0x0006;
+ public static final int AL_EAXREVERB_DECAY_HFRATIO = 0x0007;
+ public static final int AL_EAXREVERB_DECAY_LFRATIO = 0x0008;
+ public static final int AL_EAXREVERB_REFLECTIONS_GAIN = 0x0009;
+ public static final int AL_EAXREVERB_REFLECTIONS_DELAY = 0x000A;
+ public static final int AL_EAXREVERB_REFLECTIONS_PAN = 0x000B;
+ public static final int AL_EAXREVERB_LATE_REVERB_GAIN = 0x000C;
+ public static final int AL_EAXREVERB_LATE_REVERB_DELAY = 0x000D;
+ public static final int AL_EAXREVERB_LATE_REVERB_PAN = 0x000E;
+ public static final int AL_EAXREVERB_ECHO_TIME = 0x000F;
+ public static final int AL_EAXREVERB_ECHO_DEPTH = 0x0010;
+ public static final int AL_EAXREVERB_MODULATION_TIME = 0x0011;
+ public static final int AL_EAXREVERB_MODULATION_DEPTH = 0x0012;
+ public static final int AL_EAXREVERB_AIR_ABSORPTION_GAINHF = 0x0013;
+ public static final int AL_EAXREVERB_HFREFERENCE = 0x0014;
+ public static final int AL_EAXREVERB_LFREFERENCE = 0x0015;
+ public static final int AL_EAXREVERB_ROOM_ROLLOFF_FACTOR = 0x0016;
+ public static final int AL_EAXREVERB_DECAY_HFLIMIT = 0x0017;
+ public static final int AL_CHORUS_WAVEFORM = 0x0001;
+ public static final int AL_CHORUS_PHASE = 0x0002;
+ public static final int AL_CHORUS_RATE = 0x0003;
+ public static final int AL_CHORUS_DEPTH = 0x0004;
+ public static final int AL_CHORUS_FEEDBACK = 0x0005;
+ public static final int AL_CHORUS_DELAY = 0x0006;
+ public static final int AL_DISTORTION_EDGE = 0x0001;
+ public static final int AL_DISTORTION_GAIN = 0x0002;
+ public static final int AL_DISTORTION_LOWPASS_CUTOFF = 0x0003;
+ public static final int AL_DISTORTION_EQCENTER = 0x0004;
+ public static final int AL_DISTORTION_EQBANDWIDTH = 0x0005;
+ public static final int AL_ECHO_DELAY = 0x0001;
+ public static final int AL_ECHO_LRDELAY = 0x0002;
+ public static final int AL_ECHO_DAMPING = 0x0003;
+ public static final int AL_ECHO_FEEDBACK = 0x0004;
+ public static final int AL_ECHO_SPREAD = 0x0005;
+ public static final int AL_FLANGER_WAVEFORM = 0x0001;
+ public static final int AL_FLANGER_PHASE = 0x0002;
+ public static final int AL_FLANGER_RATE = 0x0003;
+ public static final int AL_FLANGER_DEPTH = 0x0004;
+ public static final int AL_FLANGER_FEEDBACK = 0x0005;
+ public static final int AL_FLANGER_DELAY = 0x0006;
+ public static final int AL_FREQUENCY_SHIFTER_FREQUENCY = 0x0001;
+ public static final int AL_FREQUENCY_SHIFTER_LEFT_DIRECTION = 0x0002;
+ public static final int AL_FREQUENCY_SHIFTER_RIGHT_DIRECTION = 0x0003;
+ public static final int AL_VOCAL_MORPHER_PHONEMEA = 0x0001;
+ public static final int AL_VOCAL_MORPHER_PHONEMEA_COARSE_TUNING = 0x0002;
+ public static final int AL_VOCAL_MORPHER_PHONEMEB = 0x0003;
+ public static final int AL_VOCAL_MORPHER_PHONEMEB_COARSE_TUNING = 0x0004;
+ public static final int AL_VOCAL_MORPHER_WAVEFORM = 0x0005;
+ public static final int AL_VOCAL_MORPHER_RATE = 0x0006;
+ public static final int AL_PITCH_SHIFTER_COARSE_TUNE = 0x0001;
+ public static final int AL_PITCH_SHIFTER_FINE_TUNE = 0x0002;
+ public static final int AL_RING_MODULATOR_FREQUENCY = 0x0001;
+ public static final int AL_RING_MODULATOR_HIGHPASS_CUTOFF = 0x0002;
+ public static final int AL_RING_MODULATOR_WAVEFORM = 0x0003;
+ public static final int AL_AUTOWAH_ATTACK_TIME = 0x0001;
+ public static final int AL_AUTOWAH_RELEASE_TIME = 0x0002;
+ public static final int AL_AUTOWAH_RESONANCE = 0x0003;
+ public static final int AL_AUTOWAH_PEAK_GAIN = 0x0004;
+ public static final int AL_COMPRESSOR_ONOFF = 0x0001;
+ public static final int AL_EQUALIZER_LOW_GAIN = 0x0001;
+ public static final int AL_EQUALIZER_LOW_CUTOFF = 0x0002;
+ public static final int AL_EQUALIZER_MID1_GAIN = 0x0003;
+ public static final int AL_EQUALIZER_MID1_CENTER = 0x0004;
+ public static final int AL_EQUALIZER_MID1_WIDTH = 0x0005;
+ public static final int AL_EQUALIZER_MID2_GAIN = 0x0006;
+ public static final int AL_EQUALIZER_MID2_CENTER = 0x0007;
+ public static final int AL_EQUALIZER_MID2_WIDTH = 0x0008;
+ public static final int AL_EQUALIZER_HIGH_GAIN = 0x0009;
+ public static final int AL_EQUALIZER_HIGH_CUTOFF = 0x000A;
+ public static final int AL_EFFECT_FIRST_PARAMETER = 0x0000;
+ public static final int AL_EFFECT_LAST_PARAMETER = 0x8000;
+ public static final int AL_EFFECT_TYPE = 0x8001;
+ public static final int AL_EFFECT_NULL = 0x0000;
+ public static final int AL_EFFECT_REVERB = 0x0001;
+ public static final int AL_EFFECT_CHORUS = 0x0002;
+ public static final int AL_EFFECT_DISTORTION = 0x0003;
+ public static final int AL_EFFECT_ECHO = 0x0004;
+ public static final int AL_EFFECT_FLANGER = 0x0005;
+ public static final int AL_EFFECT_FREQUENCY_SHIFTER = 0x0006;
+ public static final int AL_EFFECT_VOCAL_MORPHER = 0x0007;
+ public static final int AL_EFFECT_PITCH_SHIFTER = 0x0008;
+ public static final int AL_EFFECT_RING_MODULATOR = 0x0009;
+ public static final int AL_EFFECT_AUTOWAH = 0x000A;
+ public static final int AL_EFFECT_COMPRESSOR = 0x000B;
+ public static final int AL_EFFECT_EQUALIZER = 0x000C;
+ public static final int AL_EFFECT_EAXREVERB = 0x8000;
+ public static final int AL_EFFECTSLOT_EFFECT = 0x0001;
+ public static final int AL_EFFECTSLOT_GAIN = 0x0002;
+ public static final int AL_EFFECTSLOT_AUXILIARY_SEND_AUTO = 0x0003;
+ public static final int AL_EFFECTSLOT_NULL = 0x0000;
+ public static final int AL_LOWPASS_GAIN = 0x0001;
+ public static final int AL_LOWPASS_GAINHF = 0x0002;
+ public static final int AL_HIGHPASS_GAIN = 0x0001;
+ public static final int AL_HIGHPASS_GAINLF = 0x0002;
+ public static final int AL_BANDPASS_GAIN = 0x0001;
+ public static final int AL_BANDPASS_GAINLF = 0x0002;
+ public static final int AL_BANDPASS_GAINHF = 0x0003;
+ public static final int AL_FILTER_FIRST_PARAMETER = 0x0000;
+ public static final int AL_FILTER_LAST_PARAMETER = 0x8000;
+ public static final int AL_FILTER_TYPE = 0x8001;
+ public static final int AL_FILTER_NULL = 0x0000;
+ public static final int AL_FILTER_LOWPASS = 0x0001;
+ public static final int AL_FILTER_HIGHPASS = 0x0002;
+ public static final int AL_FILTER_BANDPASS = 0x0003;
+ public static final float AL_LOWPASS_MIN_GAIN = 0.0f;
+ public static final float AL_LOWPASS_MAX_GAIN = 1.0f;
+ public static final float AL_LOWPASS_DEFAULT_GAIN = 1.0f;
+ public static final float AL_LOWPASS_MIN_GAINHF = 0.0f;
+ public static final float AL_LOWPASS_MAX_GAINHF = 1.0f;
+ public static final float AL_LOWPASS_DEFAULT_GAINHF = 1.0f;
+ public static final float AL_HIGHPASS_MIN_GAIN = 0.0f;
+ public static final float AL_HIGHPASS_MAX_GAIN = 1.0f;
+ public static final float AL_HIGHPASS_DEFAULT_GAIN = 1.0f;
+ public static final float AL_HIGHPASS_MIN_GAINLF = 0.0f;
+ public static final float AL_HIGHPASS_MAX_GAINLF = 1.0f;
+ public static final float AL_HIGHPASS_DEFAULT_GAINLF = 1.0f;
+ public static final float AL_BANDPASS_MIN_GAIN = 0.0f;
+ public static final float AL_BANDPASS_MAX_GAIN = 1.0f;
+ public static final float AL_BANDPASS_DEFAULT_GAIN = 1.0f;
+ public static final float AL_BANDPASS_MIN_GAINHF = 0.0f;
+ public static final float AL_BANDPASS_MAX_GAINHF = 1.0f;
+ public static final float AL_BANDPASS_DEFAULT_GAINHF = 1.0f;
+ public static final float AL_BANDPASS_MIN_GAINLF = 0.0f;
+ public static final float AL_BANDPASS_MAX_GAINLF = 1.0f;
+ public static final float AL_BANDPASS_DEFAULT_GAINLF = 1.0f;
+ public static final float AL_REVERB_MIN_DENSITY = 0.0f;
+ public static final float AL_REVERB_MAX_DENSITY = 1.0f;
+ public static final float AL_REVERB_DEFAULT_DENSITY = 1.0f;
+ public static final float AL_REVERB_MIN_DIFFUSION = 0.0f;
+ public static final float AL_REVERB_MAX_DIFFUSION = 1.0f;
+ public static final float AL_REVERB_DEFAULT_DIFFUSION = 1.0f;
+ public static final float AL_REVERB_MIN_GAIN = 0.0f;
+ public static final float AL_REVERB_MAX_GAIN = 1.0f;
+ public static final float AL_REVERB_DEFAULT_GAIN = 0.32f;
+ public static final float AL_REVERB_MIN_GAINHF = 0.0f;
+ public static final float AL_REVERB_MAX_GAINHF = 1.0f;
+ public static final float AL_REVERB_DEFAULT_GAINHF = 0.89f;
+ public static final float AL_REVERB_MIN_DECAY_TIME = 0.1f;
+ public static final float AL_REVERB_MAX_DECAY_TIME = 20.0f;
+ public static final float AL_REVERB_DEFAULT_DECAY_TIME = 1.49f;
+ public static final float AL_REVERB_MIN_DECAY_HFRATIO = 0.1f;
+ public static final float AL_REVERB_MAX_DECAY_HFRATIO = 2.0f;
+ public static final float AL_REVERB_DEFAULT_DECAY_HFRATIO = 0.83f;
+ public static final float AL_REVERB_MIN_REFLECTIONS_GAIN = 0.0f;
+ public static final float AL_REVERB_MAX_REFLECTIONS_GAIN = 3.16f;
+ public static final float AL_REVERB_DEFAULT_REFLECTIONS_GAIN = 0.05f;
+ public static final float AL_REVERB_MIN_REFLECTIONS_DELAY = 0.0f;
+ public static final float AL_REVERB_MAX_REFLECTIONS_DELAY = 0.3f;
+ public static final float AL_REVERB_DEFAULT_REFLECTIONS_DELAY = 0.007f;
+ public static final float AL_REVERB_MIN_LATE_REVERB_GAIN = 0.0f;
+ public static final float AL_REVERB_MAX_LATE_REVERB_GAIN = 10.0f;
+ public static final float AL_REVERB_DEFAULT_LATE_REVERB_GAIN = 1.26f;
+ public static final float AL_REVERB_MIN_LATE_REVERB_DELAY = 0.0f;
+ public static final float AL_REVERB_MAX_LATE_REVERB_DELAY = 0.1f;
+ public static final float AL_REVERB_DEFAULT_LATE_REVERB_DELAY = 0.011f;
+ public static final float AL_REVERB_MIN_AIR_ABSORPTION_GAINHF = 0.892f;
+ public static final float AL_REVERB_MAX_AIR_ABSORPTION_GAINHF = 1.0f;
+ public static final float AL_REVERB_DEFAULT_AIR_ABSORPTION_GAINHF = 0.994f;
+ public static final float AL_REVERB_MIN_ROOM_ROLLOFF_FACTOR = 0.0f;
+ public static final float AL_REVERB_MAX_ROOM_ROLLOFF_FACTOR = 10.0f;
+ public static final float AL_REVERB_DEFAULT_ROOM_ROLLOFF_FACTOR = 0.0f;
+ public static final int AL_REVERB_MIN_DECAY_HFLIMIT = AL.AL_FALSE;
+ public static final int AL_REVERB_MAX_DECAY_HFLIMIT = AL.AL_TRUE;
+ public static final int AL_REVERB_DEFAULT_DECAY_HFLIMIT = AL.AL_TRUE;
+ public static final float AL_EAXREVERB_MIN_DENSITY = 0.0f;
+ public static final float AL_EAXREVERB_MAX_DENSITY = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_DENSITY = 1.0f;
+ public static final float AL_EAXREVERB_MIN_DIFFUSION = 0.0f;
+ public static final float AL_EAXREVERB_MAX_DIFFUSION = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_DIFFUSION = 1.0f;
+ public static final float AL_EAXREVERB_MIN_GAIN = 0.0f;
+ public static final float AL_EAXREVERB_MAX_GAIN = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_GAIN = 0.32f;
+ public static final float AL_EAXREVERB_MIN_GAINHF = 0.0f;
+ public static final float AL_EAXREVERB_MAX_GAINHF = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_GAINHF = 0.89f;
+ public static final float AL_EAXREVERB_MIN_GAINLF = 0.0f;
+ public static final float AL_EAXREVERB_MAX_GAINLF = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_GAINLF = 1.0f;
+ public static final float AL_EAXREVERB_MIN_DECAY_TIME = 0.1f;
+ public static final float AL_EAXREVERB_MAX_DECAY_TIME = 20.0f;
+ public static final float AL_EAXREVERB_DEFAULT_DECAY_TIME = 1.49f;
+ public static final float AL_EAXREVERB_MIN_DECAY_HFRATIO = 0.1f;
+ public static final float AL_EAXREVERB_MAX_DECAY_HFRATIO = 2.0f;
+ public static final float AL_EAXREVERB_DEFAULT_DECAY_HFRATIO = 0.83f;
+ public static final float AL_EAXREVERB_MIN_DECAY_LFRATIO = 0.1f;
+ public static final float AL_EAXREVERB_MAX_DECAY_LFRATIO = 2.0f;
+ public static final float AL_EAXREVERB_DEFAULT_DECAY_LFRATIO = 1.0f;
+ public static final float AL_EAXREVERB_MIN_REFLECTIONS_GAIN = 0.0f;
+ public static final float AL_EAXREVERB_MAX_REFLECTIONS_GAIN = 3.16f;
+ public static final float AL_EAXREVERB_DEFAULT_REFLECTIONS_GAIN = 0.05f;
+ public static final float AL_EAXREVERB_MIN_REFLECTIONS_DELAY = 0.0f;
+ public static final float AL_EAXREVERB_MAX_REFLECTIONS_DELAY = 0.3f;
+ public static final float AL_EAXREVERB_DEFAULT_REFLECTIONS_DELAY = 0.007f;
+ public static final float AL_EAXREVERB_DEFAULT_REFLECTIONS_PAN_XYZ = 0.0f;
+ public static final float AL_EAXREVERB_MIN_LATE_REVERB_GAIN = 0.0f;
+ public static final float AL_EAXREVERB_MAX_LATE_REVERB_GAIN = 10.0f;
+ public static final float AL_EAXREVERB_DEFAULT_LATE_REVERB_GAIN = 1.26f;
+ public static final float AL_EAXREVERB_MIN_LATE_REVERB_DELAY = 0.0f;
+ public static final float AL_EAXREVERB_MAX_LATE_REVERB_DELAY = 0.1f;
+ public static final float AL_EAXREVERB_DEFAULT_LATE_REVERB_DELAY = 0.011f;
+ public static final float AL_EAXREVERB_DEFAULT_LATE_REVERB_PAN_XYZ = 0.0f;
+ public static final float AL_EAXREVERB_MIN_ECHO_TIME = 0.075f;
+ public static final float AL_EAXREVERB_MAX_ECHO_TIME = 0.25f;
+ public static final float AL_EAXREVERB_DEFAULT_ECHO_TIME = 0.25f;
+ public static final float AL_EAXREVERB_MIN_ECHO_DEPTH = 0.0f;
+ public static final float AL_EAXREVERB_MAX_ECHO_DEPTH = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_ECHO_DEPTH = 0.0f;
+ public static final float AL_EAXREVERB_MIN_MODULATION_TIME = 0.04f;
+ public static final float AL_EAXREVERB_MAX_MODULATION_TIME = 4.0f;
+ public static final float AL_EAXREVERB_DEFAULT_MODULATION_TIME = 0.25f;
+ public static final float AL_EAXREVERB_MIN_MODULATION_DEPTH = 0.0f;
+ public static final float AL_EAXREVERB_MAX_MODULATION_DEPTH = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_MODULATION_DEPTH = 0.0f;
+ public static final float AL_EAXREVERB_MIN_AIR_ABSORPTION_GAINHF = 0.892f;
+ public static final float AL_EAXREVERB_MAX_AIR_ABSORPTION_GAINHF = 1.0f;
+ public static final float AL_EAXREVERB_DEFAULT_AIR_ABSORPTION_GAINHF = 0.994f;
+ public static final float AL_EAXREVERB_MIN_HFREFERENCE = 1000.0f;
+ public static final float AL_EAXREVERB_MAX_HFREFERENCE = 20000.0f;
+ public static final float AL_EAXREVERB_DEFAULT_HFREFERENCE = 5000.0f;
+ public static final float AL_EAXREVERB_MIN_LFREFERENCE = 20.0f;
+ public static final float AL_EAXREVERB_MAX_LFREFERENCE = 1000.0f;
+ public static final float AL_EAXREVERB_DEFAULT_LFREFERENCE = 250.0f;
+ public static final float AL_EAXREVERB_MIN_ROOM_ROLLOFF_FACTOR = 0.0f;
+ public static final float AL_EAXREVERB_MAX_ROOM_ROLLOFF_FACTOR = 10.0f;
+ public static final float AL_EAXREVERB_DEFAULT_ROOM_ROLLOFF_FACTOR = 0.0f;
+ public static final int AL_EAXREVERB_MIN_DECAY_HFLIMIT = AL.AL_FALSE;
+ public static final int AL_EAXREVERB_MAX_DECAY_HFLIMIT = AL.AL_TRUE;
+ public static final int AL_EAXREVERB_DEFAULT_DECAY_HFLIMIT = AL.AL_TRUE;
+ public static final int AL_CHORUS_WAVEFORM_SINUSOID = 0;
+ public static final int AL_CHORUS_WAVEFORM_TRIANGLE = 1;
+ public static final int AL_CHORUS_MIN_WAVEFORM = 0;
+ public static final int AL_CHORUS_MAX_WAVEFORM = 1;
+ public static final int AL_CHORUS_DEFAULT_WAVEFORM = 1;
+ public static final int AL_CHORUS_MIN_PHASE = -180;
+ public static final int AL_CHORUS_MAX_PHASE = 180;
+ public static final int AL_CHORUS_DEFAULT_PHASE = 90;
+ public static final float AL_CHORUS_MIN_RATE = 0.0f;
+ public static final float AL_CHORUS_MAX_RATE = 10.0f;
+ public static final float AL_CHORUS_DEFAULT_RATE = 1.1f;
+ public static final float AL_CHORUS_MIN_DEPTH = 0.0f;
+ public static final float AL_CHORUS_MAX_DEPTH = 1.0f;
+ public static final float AL_CHORUS_DEFAULT_DEPTH = 0.1f;
+ public static final float AL_CHORUS_MIN_FEEDBACK = -1.0f;
+ public static final float AL_CHORUS_MAX_FEEDBACK = 1.0f;
+ public static final float AL_CHORUS_DEFAULT_FEEDBACK = 0.25f;
+ public static final float AL_CHORUS_MIN_DELAY = 0.0f;
+ public static final float AL_CHORUS_MAX_DELAY = 0.016f;
+ public static final float AL_CHORUS_DEFAULT_DELAY = 0.016f;
+ public static final float AL_DISTORTION_MIN_EDGE = 0.0f;
+ public static final float AL_DISTORTION_MAX_EDGE = 1.0f;
+ public static final float AL_DISTORTION_DEFAULT_EDGE = 0.2f;
+ public static final float AL_DISTORTION_MIN_GAIN = 0.01f;
+ public static final float AL_DISTORTION_MAX_GAIN = 1.0f;
+ public static final float AL_DISTORTION_DEFAULT_GAIN = 0.05f;
+ public static final float AL_DISTORTION_MIN_LOWPASS_CUTOFF = 80.0f;
+ public static final float AL_DISTORTION_MAX_LOWPASS_CUTOFF = 24000.0f;
+ public static final float AL_DISTORTION_DEFAULT_LOWPASS_CUTOFF = 8000.0f;
+ public static final float AL_DISTORTION_MIN_EQCENTER = 80.0f;
+ public static final float AL_DISTORTION_MAX_EQCENTER = 24000.0f;
+ public static final float AL_DISTORTION_DEFAULT_EQCENTER = 3600.0f;
+ public static final float AL_DISTORTION_MIN_EQBANDWIDTH = 80.0f;
+ public static final float AL_DISTORTION_MAX_EQBANDWIDTH = 24000.0f;
+ public static final float AL_DISTORTION_DEFAULT_EQBANDWIDTH = 3600.0f;
+ public static final float AL_ECHO_MIN_DELAY = 0.0f;
+ public static final float AL_ECHO_MAX_DELAY = 0.207f;
+ public static final float AL_ECHO_DEFAULT_DELAY = 0.1f;
+ public static final float AL_ECHO_MIN_LRDELAY = 0.0f;
+ public static final float AL_ECHO_MAX_LRDELAY = 0.404f;
+ public static final float AL_ECHO_DEFAULT_LRDELAY = 0.1f;
+ public static final float AL_ECHO_MIN_DAMPING = 0.0f;
+ public static final float AL_ECHO_MAX_DAMPING = 0.99f;
+ public static final float AL_ECHO_DEFAULT_DAMPING = 0.5f;
+ public static final float AL_ECHO_MIN_FEEDBACK = 0.0f;
+ public static final float AL_ECHO_MAX_FEEDBACK = 1.0f;
+ public static final float AL_ECHO_DEFAULT_FEEDBACK = 0.5f;
+ public static final float AL_ECHO_MIN_SPREAD = -1.0f;
+ public static final float AL_ECHO_MAX_SPREAD = 1.0f;
+ public static final float AL_ECHO_DEFAULT_SPREAD = -1.0f;
+ public static final int AL_FLANGER_WAVEFORM_SINUSOID = 0;
+ public static final int AL_FLANGER_WAVEFORM_TRIANGLE = 1;
+ public static final int AL_FLANGER_MIN_WAVEFORM = 0;
+ public static final int AL_FLANGER_MAX_WAVEFORM = 1;
+ public static final int AL_FLANGER_DEFAULT_WAVEFORM = 1;
+ public static final int AL_FLANGER_MIN_PHASE = -180;
+ public static final int AL_FLANGER_MAX_PHASE = 180;
+ public static final int AL_FLANGER_DEFAULT_PHASE = 0;
+ public static final float AL_FLANGER_MIN_RATE = 0.0f;
+ public static final float AL_FLANGER_MAX_RATE = 10.0f;
+ public static final float AL_FLANGER_DEFAULT_RATE = 0.27f;
+ public static final float AL_FLANGER_MIN_DEPTH = 0.0f;
+ public static final float AL_FLANGER_MAX_DEPTH = 1.0f;
+ public static final float AL_FLANGER_DEFAULT_DEPTH = 1.0f;
+ public static final float AL_FLANGER_MIN_FEEDBACK = -1.0f;
+ public static final float AL_FLANGER_MAX_FEEDBACK = 1.0f;
+ public static final float AL_FLANGER_DEFAULT_FEEDBACK = -0.5f;
+ public static final float AL_FLANGER_MIN_DELAY = 0.0f;
+ public static final float AL_FLANGER_MAX_DELAY = 0.004f;
+ public static final float AL_FLANGER_DEFAULT_DELAY = 0.002f;
+ public static final float AL_FREQUENCY_SHIFTER_MIN_FREQUENCY = 0.0f;
+ public static final float AL_FREQUENCY_SHIFTER_MAX_FREQUENCY = 24000.0f;
+ public static final float AL_FREQUENCY_SHIFTER_DEFAULT_FREQUENCY = 0.0f;
+ public static final int AL_FREQUENCY_SHIFTER_MIN_LEFT_DIRECTION = 0;
+ public static final int AL_FREQUENCY_SHIFTER_MAX_LEFT_DIRECTION = 2;
+ public static final int AL_FREQUENCY_SHIFTER_DEFAULT_LEFT_DIRECTION = 0;
+ public static final int AL_FREQUENCY_SHIFTER_DIRECTION_DOWN = 0;
+ public static final int AL_FREQUENCY_SHIFTER_DIRECTION_UP = 1;
+ public static final int AL_FREQUENCY_SHIFTER_DIRECTION_OFF = 2;
+ public static final int AL_FREQUENCY_SHIFTER_MIN_RIGHT_DIRECTION = 0;
+ public static final int AL_FREQUENCY_SHIFTER_MAX_RIGHT_DIRECTION = 2;
+ public static final int AL_FREQUENCY_SHIFTER_DEFAULT_RIGHT_DIRECTION = 0;
+ public static final int AL_VOCAL_MORPHER_MIN_PHONEMEA = 0;
+ public static final int AL_VOCAL_MORPHER_MAX_PHONEMEA = 29;
+ public static final int AL_VOCAL_MORPHER_DEFAULT_PHONEMEA = 0;
+ public static final int AL_VOCAL_MORPHER_MIN_PHONEMEA_COARSE_TUNING = -24;
+ public static final int AL_VOCAL_MORPHER_MAX_PHONEMEA_COARSE_TUNING = 24;
+ public static final int AL_VOCAL_MORPHER_DEFAULT_PHONEMEA_COARSE_TUNING = 0;
+ public static final int AL_VOCAL_MORPHER_MIN_PHONEMEB = 0;
+ public static final int AL_VOCAL_MORPHER_MAX_PHONEMEB = 29;
+ public static final int AL_VOCAL_MORPHER_DEFAULT_PHONEMEB = 10;
+ public static final int AL_VOCAL_MORPHER_MIN_PHONEMEB_COARSE_TUNING = -24;
+ public static final int AL_VOCAL_MORPHER_MAX_PHONEMEB_COARSE_TUNING = 24;
+ public static final int AL_VOCAL_MORPHER_DEFAULT_PHONEMEB_COARSE_TUNING = 0;
+ public static final int AL_VOCAL_MORPHER_PHONEME_A = 0;
+ public static final int AL_VOCAL_MORPHER_PHONEME_E = 1;
+ public static final int AL_VOCAL_MORPHER_PHONEME_I = 2;
+ public static final int AL_VOCAL_MORPHER_PHONEME_O = 3;
+ public static final int AL_VOCAL_MORPHER_PHONEME_U = 4;
+ public static final int AL_VOCAL_MORPHER_PHONEME_AA = 5;
+ public static final int AL_VOCAL_MORPHER_PHONEME_AE = 6;
+ public static final int AL_VOCAL_MORPHER_PHONEME_AH = 7;
+ public static final int AL_VOCAL_MORPHER_PHONEME_AO = 8;
+ public static final int AL_VOCAL_MORPHER_PHONEME_EH = 9;
+ public static final int AL_VOCAL_MORPHER_PHONEME_ER = 10;
+ public static final int AL_VOCAL_MORPHER_PHONEME_IH = 11;
+ public static final int AL_VOCAL_MORPHER_PHONEME_IY = 12;
+ public static final int AL_VOCAL_MORPHER_PHONEME_UH = 13;
+ public static final int AL_VOCAL_MORPHER_PHONEME_UW = 14;
+ public static final int AL_VOCAL_MORPHER_PHONEME_B = 15;
+ public static final int AL_VOCAL_MORPHER_PHONEME_D = 16;
+ public static final int AL_VOCAL_MORPHER_PHONEME_F = 17;
+ public static final int AL_VOCAL_MORPHER_PHONEME_G = 18;
+ public static final int AL_VOCAL_MORPHER_PHONEME_J = 19;
+ public static final int AL_VOCAL_MORPHER_PHONEME_K = 20;
+ public static final int AL_VOCAL_MORPHER_PHONEME_L = 21;
+ public static final int AL_VOCAL_MORPHER_PHONEME_M = 22;
+ public static final int AL_VOCAL_MORPHER_PHONEME_N = 23;
+ public static final int AL_VOCAL_MORPHER_PHONEME_P = 24;
+ public static final int AL_VOCAL_MORPHER_PHONEME_R = 25;
+ public static final int AL_VOCAL_MORPHER_PHONEME_S = 26;
+ public static final int AL_VOCAL_MORPHER_PHONEME_T = 27;
+ public static final int AL_VOCAL_MORPHER_PHONEME_V = 28;
+ public static final int AL_VOCAL_MORPHER_PHONEME_Z = 29;
+ public static final int AL_VOCAL_MORPHER_WAVEFORM_SINUSOID = 0;
+ public static final int AL_VOCAL_MORPHER_WAVEFORM_TRIANGLE = 1;
+ public static final int AL_VOCAL_MORPHER_WAVEFORM_SAWTOOTH = 2;
+ public static final int AL_VOCAL_MORPHER_MIN_WAVEFORM = 0;
+ public static final int AL_VOCAL_MORPHER_MAX_WAVEFORM = 2;
+ public static final int AL_VOCAL_MORPHER_DEFAULT_WAVEFORM = 0;
+ public static final float AL_VOCAL_MORPHER_MIN_RATE = 0.0f;
+ public static final float AL_VOCAL_MORPHER_MAX_RATE = 10.0f;
+ public static final float AL_VOCAL_MORPHER_DEFAULT_RATE = 1.41f;
+ public static final int AL_PITCH_SHIFTER_MIN_COARSE_TUNE = -12;
+ public static final int AL_PITCH_SHIFTER_MAX_COARSE_TUNE = 12;
+ public static final int AL_PITCH_SHIFTER_DEFAULT_COARSE_TUNE = 12;
+ public static final int AL_PITCH_SHIFTER_MIN_FINE_TUNE = -50;
+ public static final int AL_PITCH_SHIFTER_MAX_FINE_TUNE = 50;
+ public static final int AL_PITCH_SHIFTER_DEFAULT_FINE_TUNE = 0;
+ public static final float AL_RING_MODULATOR_MIN_FREQUENCY = 0.0f;
+ public static final float AL_RING_MODULATOR_MAX_FREQUENCY = 8000.0f;
+ public static final float AL_RING_MODULATOR_DEFAULT_FREQUENCY = 440.0f;
+ public static final float AL_RING_MODULATOR_MIN_HIGHPASS_CUTOFF = 0.0f;
+ public static final float AL_RING_MODULATOR_MAX_HIGHPASS_CUTOFF = 24000.0f;
+ public static final float AL_RING_MODULATOR_DEFAULT_HIGHPASS_CUTOFF = 800.0f;
+ public static final int AL_RING_MODULATOR_SINUSOID = 0;
+ public static final int AL_RING_MODULATOR_SAWTOOTH = 1;
+ public static final int AL_RING_MODULATOR_SQUARE = 2;
+ public static final int AL_RING_MODULATOR_MIN_WAVEFORM = 0;
+ public static final int AL_RING_MODULATOR_MAX_WAVEFORM = 2;
+ public static final int AL_RING_MODULATOR_DEFAULT_WAVEFORM = 0;
+ public static final float AL_AUTOWAH_MIN_ATTACK_TIME = 0.0001f;
+ public static final float AL_AUTOWAH_MAX_ATTACK_TIME = 1.0f;
+ public static final float AL_AUTOWAH_DEFAULT_ATTACK_TIME = 0.06f;
+ public static final float AL_AUTOWAH_MIN_RELEASE_TIME = 0.0001f;
+ public static final float AL_AUTOWAH_MAX_RELEASE_TIME = 1.0f;
+ public static final float AL_AUTOWAH_DEFAULT_RELEASE_TIME = 0.06f;
+ public static final float AL_AUTOWAH_MIN_RESONANCE = 2.0f;
+ public static final float AL_AUTOWAH_MAX_RESONANCE = 1000.0f;
+ public static final float AL_AUTOWAH_DEFAULT_RESONANCE = 1000.0f;
+ public static final float AL_AUTOWAH_MIN_PEAK_GAIN = 0.00003f;
+ public static final float AL_AUTOWAH_MAX_PEAK_GAIN = 31621.0f;
+ public static final float AL_AUTOWAH_DEFAULT_PEAK_GAIN = 11.22f;
+ public static final int AL_COMPRESSOR_MIN_ONOFF = 0;
+ public static final int AL_COMPRESSOR_MAX_ONOFF = 1;
+ public static final int AL_COMPRESSOR_DEFAULT_ONOFF = 1;
+ public static final float AL_EQUALIZER_MIN_LOW_GAIN = 0.126f;
+ public static final float AL_EQUALIZER_MAX_LOW_GAIN = 7.943f;
+ public static final float AL_EQUALIZER_DEFAULT_LOW_GAIN = 1.0f;
+ public static final float AL_EQUALIZER_MIN_LOW_CUTOFF = 50.0f;
+ public static final float AL_EQUALIZER_MAX_LOW_CUTOFF = 800.0f;
+ public static final float AL_EQUALIZER_DEFAULT_LOW_CUTOFF = 200.0f;
+ public static final float AL_EQUALIZER_MIN_MID1_GAIN = 0.126f;
+ public static final float AL_EQUALIZER_MAX_MID1_GAIN = 7.943f;
+ public static final float AL_EQUALIZER_DEFAULT_MID1_GAIN = 1.0f;
+ public static final float AL_EQUALIZER_MIN_MID1_CENTER = 200.0f;
+ public static final float AL_EQUALIZER_MAX_MID1_CENTER = 3000.0f;
+ public static final float AL_EQUALIZER_DEFAULT_MID1_CENTER = 500.0f;
+ public static final float AL_EQUALIZER_MIN_MID1_WIDTH = 0.01f;
+ public static final float AL_EQUALIZER_MAX_MID1_WIDTH = 1.0f;
+ public static final float AL_EQUALIZER_DEFAULT_MID1_WIDTH = 1.0f;
+ public static final float AL_EQUALIZER_MIN_MID2_GAIN = 0.126f;
+ public static final float AL_EQUALIZER_MAX_MID2_GAIN = 7.943f;
+ public static final float AL_EQUALIZER_DEFAULT_MID2_GAIN = 1.0f;
+ public static final float AL_EQUALIZER_MIN_MID2_CENTER = 1000.0f;
+ public static final float AL_EQUALIZER_MAX_MID2_CENTER = 8000.0f;
+ public static final float AL_EQUALIZER_DEFAULT_MID2_CENTER = 3000.0f;
+ public static final float AL_EQUALIZER_MIN_MID2_WIDTH = 0.01f;
+ public static final float AL_EQUALIZER_MAX_MID2_WIDTH = 1.0f;
+ public static final float AL_EQUALIZER_DEFAULT_MID2_WIDTH = 1.0f;
+ public static final float AL_EQUALIZER_MIN_HIGH_GAIN = 0.126f;
+ public static final float AL_EQUALIZER_MAX_HIGH_GAIN = 7.943f;
+ public static final float AL_EQUALIZER_DEFAULT_HIGH_GAIN = 1.0f;
+ public static final float AL_EQUALIZER_MIN_HIGH_CUTOFF = 4000.0f;
+ public static final float AL_EQUALIZER_MAX_HIGH_CUTOFF = 16000.0f;
+ public static final float AL_EQUALIZER_DEFAULT_HIGH_CUTOFF = 6000.0f;
+ public static final float AL_MIN_AIR_ABSORPTION_FACTOR = 0.0f;
+ public static final float AL_MAX_AIR_ABSORPTION_FACTOR = 10.0f;
+ public static final float AL_DEFAULT_AIR_ABSORPTION_FACTOR = 0.0f;
+ public static final float AL_MIN_ROOM_ROLLOFF_FACTOR = 0.0f;
+ public static final float AL_MAX_ROOM_ROLLOFF_FACTOR = 10.0f;
+ public static final float AL_DEFAULT_ROOM_ROLLOFF_FACTOR = 0.0f;
+ public static final float AL_MIN_CONE_OUTER_GAINHF = 0.0f;
+ public static final float AL_MAX_CONE_OUTER_GAINHF = 1.0f;
+ public static final float AL_DEFAULT_CONE_OUTER_GAINHF = 1.0f;
+ public static final int AL_MIN_DIRECT_FILTER_GAINHF_AUTO = AL.AL_FALSE;
+ public static final int AL_MAX_DIRECT_FILTER_GAINHF_AUTO = AL.AL_TRUE;
+ public static final int AL_DEFAULT_DIRECT_FILTER_GAINHF_AUTO = AL.AL_TRUE;
+ public static final int AL_MIN_AUXILIARY_SEND_FILTER_GAIN_AUTO = AL.AL_FALSE;
+ public static final int AL_MAX_AUXILIARY_SEND_FILTER_GAIN_AUTO = AL.AL_TRUE;
+ public static final int AL_DEFAULT_AUXILIARY_SEND_FILTER_GAIN_AUTO = AL.AL_TRUE;
+ public static final int AL_MIN_AUXILIARY_SEND_FILTER_GAINHF_AUTO = AL.AL_FALSE;
+ public static final int AL_MAX_AUXILIARY_SEND_FILTER_GAINHF_AUTO = AL.AL_TRUE;
+ public static final int AL_DEFAULT_AUXILIARY_SEND_FILTER_GAINHF_AUTO = AL.AL_TRUE;
+ public static final float AL_MIN_METERS_PER_UNIT = Float.MIN_VALUE;
+ public static final float AL_MAX_METERS_PER_UNIT = Float.MAX_VALUE;
+ public static final float AL_DEFAULT_METERS_PER_UNIT = 1.0f;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alGenEffects`.
+ public static final MethodHandle MH_alGenEffects = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenEffects", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteEffects`.
+ public static final MethodHandle MH_alDeleteEffects = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteEffects", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsEffect`.
+ public static final MethodHandle MH_alIsEffect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsEffect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alEffecti`.
+ public static final MethodHandle MH_alEffecti = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffecti", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alEffectiv`.
+ public static final MethodHandle MH_alEffectiv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alEffectf`.
+ public static final MethodHandle MH_alEffectf = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alEffectfv`.
+ public static final MethodHandle MH_alEffectfv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffecti`.
+ public static final MethodHandle MH_alGetEffecti = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffecti", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectiv`.
+ public static final MethodHandle MH_alGetEffectiv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectf`.
+ public static final MethodHandle MH_alGetEffectf = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectfv`.
+ public static final MethodHandle MH_alGetEffectfv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenFilters`.
+ public static final MethodHandle MH_alGenFilters = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenFilters", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteFilters`.
+ public static final MethodHandle MH_alDeleteFilters = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteFilters", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsFilter`.
+ public static final MethodHandle MH_alIsFilter = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsFilter", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alFilteri`.
+ public static final MethodHandle MH_alFilteri = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilteri", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alFilteriv`.
+ public static final MethodHandle MH_alFilteriv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilteriv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alFilterf`.
+ public static final MethodHandle MH_alFilterf = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilterf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alFilterfv`.
+ public static final MethodHandle MH_alFilterfv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilterfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilteri`.
+ public static final MethodHandle MH_alGetFilteri = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilteri", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilteriv`.
+ public static final MethodHandle MH_alGetFilteriv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilteriv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilterf`.
+ public static final MethodHandle MH_alGetFilterf = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilterf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilterfv`.
+ public static final MethodHandle MH_alGetFilterfv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilterfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenAuxiliaryEffectSlots`.
+ public static final MethodHandle MH_alGenAuxiliaryEffectSlots = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenAuxiliaryEffectSlots", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteAuxiliaryEffectSlots`.
+ public static final MethodHandle MH_alDeleteAuxiliaryEffectSlots = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteAuxiliaryEffectSlots", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsAuxiliaryEffectSlot`.
+ public static final MethodHandle MH_alIsAuxiliaryEffectSlot = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsAuxiliaryEffectSlot", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ /// The method handle of `alAuxiliaryEffectSloti`.
+ public static final MethodHandle MH_alAuxiliaryEffectSloti = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSloti", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alAuxiliaryEffectSlotiv`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotiv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alAuxiliaryEffectSlotf`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotf = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alAuxiliaryEffectSlotfv`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotfv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSloti`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSloti = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSloti", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotiv`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotiv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotiv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotf`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotf = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotf", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotfv`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotfv = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotfv", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alGenEffects(@CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment effects) {
+ if (Handles.MH_alGenEffects != null) {
+ try {
+ Handles.MH_alGenEffects.invokeExact(n, effects);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenEffects", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenEffects"); }
+ }
+
+ public static void alDeleteEffects(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment effects) {
+ if (Handles.MH_alDeleteEffects != null) {
+ try {
+ Handles.MH_alDeleteEffects.invokeExact(n, effects);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteEffects", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteEffects"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsEffect(@CType("ALuint") int effect) {
+ if (Handles.MH_alIsEffect != null) {
+ try {
+ return (boolean) Handles.MH_alIsEffect.invokeExact(effect);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsEffect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsEffect"); }
+ }
+
+ public static void alEffecti(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALint") int iValue) {
+ if (Handles.MH_alEffecti != null) {
+ try {
+ Handles.MH_alEffecti.invokeExact(effect, param, iValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffecti", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffecti"); }
+ }
+
+ public static void alEffectiv(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alEffectiv != null) {
+ try {
+ Handles.MH_alEffectiv.invokeExact(effect, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectiv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectiv"); }
+ }
+
+ public static void alEffectf(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALfloat") float flValue) {
+ if (Handles.MH_alEffectf != null) {
+ try {
+ Handles.MH_alEffectf.invokeExact(effect, param, flValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectf", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectf"); }
+ }
+
+ public static void alEffectfv(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alEffectfv != null) {
+ try {
+ Handles.MH_alEffectfv.invokeExact(effect, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectfv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectfv"); }
+ }
+
+ public static void alGetEffecti(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValue) {
+ if (Handles.MH_alGetEffecti != null) {
+ try {
+ Handles.MH_alGetEffecti.invokeExact(effect, param, piValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffecti", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffecti"); }
+ }
+
+ public static void alGetEffectiv(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alGetEffectiv != null) {
+ try {
+ Handles.MH_alGetEffectiv.invokeExact(effect, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectiv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectiv"); }
+ }
+
+ public static void alGetEffectf(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValue) {
+ if (Handles.MH_alGetEffectf != null) {
+ try {
+ Handles.MH_alGetEffectf.invokeExact(effect, param, pflValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectf", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectf"); }
+ }
+
+ public static void alGetEffectfv(@CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alGetEffectfv != null) {
+ try {
+ Handles.MH_alGetEffectfv.invokeExact(effect, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectfv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectfv"); }
+ }
+
+ public static void alGenFilters(@CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment filters) {
+ if (Handles.MH_alGenFilters != null) {
+ try {
+ Handles.MH_alGenFilters.invokeExact(n, filters);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenFilters", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenFilters"); }
+ }
+
+ public static void alDeleteFilters(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment filters) {
+ if (Handles.MH_alDeleteFilters != null) {
+ try {
+ Handles.MH_alDeleteFilters.invokeExact(n, filters);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteFilters", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteFilters"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsFilter(@CType("ALuint") int filter) {
+ if (Handles.MH_alIsFilter != null) {
+ try {
+ return (boolean) Handles.MH_alIsFilter.invokeExact(filter);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsFilter", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsFilter"); }
+ }
+
+ public static void alFilteri(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALint") int iValue) {
+ if (Handles.MH_alFilteri != null) {
+ try {
+ Handles.MH_alFilteri.invokeExact(filter, param, iValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilteri", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilteri"); }
+ }
+
+ public static void alFilteriv(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alFilteriv != null) {
+ try {
+ Handles.MH_alFilteriv.invokeExact(filter, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilteriv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilteriv"); }
+ }
+
+ public static void alFilterf(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALfloat") float flValue) {
+ if (Handles.MH_alFilterf != null) {
+ try {
+ Handles.MH_alFilterf.invokeExact(filter, param, flValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilterf", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilterf"); }
+ }
+
+ public static void alFilterfv(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alFilterfv != null) {
+ try {
+ Handles.MH_alFilterfv.invokeExact(filter, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilterfv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilterfv"); }
+ }
+
+ public static void alGetFilteri(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValue) {
+ if (Handles.MH_alGetFilteri != null) {
+ try {
+ Handles.MH_alGetFilteri.invokeExact(filter, param, piValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilteri", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilteri"); }
+ }
+
+ public static void alGetFilteriv(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alGetFilteriv != null) {
+ try {
+ Handles.MH_alGetFilteriv.invokeExact(filter, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilteriv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilteriv"); }
+ }
+
+ public static void alGetFilterf(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValue) {
+ if (Handles.MH_alGetFilterf != null) {
+ try {
+ Handles.MH_alGetFilterf.invokeExact(filter, param, pflValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilterf", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilterf"); }
+ }
+
+ public static void alGetFilterfv(@CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alGetFilterfv != null) {
+ try {
+ Handles.MH_alGetFilterfv.invokeExact(filter, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilterfv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilterfv"); }
+ }
+
+ public static void alGenAuxiliaryEffectSlots(@CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment effectslots) {
+ if (Handles.MH_alGenAuxiliaryEffectSlots != null) {
+ try {
+ Handles.MH_alGenAuxiliaryEffectSlots.invokeExact(n, effectslots);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenAuxiliaryEffectSlots", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenAuxiliaryEffectSlots"); }
+ }
+
+ public static void alDeleteAuxiliaryEffectSlots(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment effectslots) {
+ if (Handles.MH_alDeleteAuxiliaryEffectSlots != null) {
+ try {
+ Handles.MH_alDeleteAuxiliaryEffectSlots.invokeExact(n, effectslots);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteAuxiliaryEffectSlots", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteAuxiliaryEffectSlots"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsAuxiliaryEffectSlot(@CType("ALuint") int effectslot) {
+ if (Handles.MH_alIsAuxiliaryEffectSlot != null) {
+ try {
+ return (boolean) Handles.MH_alIsAuxiliaryEffectSlot.invokeExact(effectslot);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsAuxiliaryEffectSlot", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsAuxiliaryEffectSlot"); }
+ }
+
+ public static void alAuxiliaryEffectSloti(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALint") int iValue) {
+ if (Handles.MH_alAuxiliaryEffectSloti != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSloti.invokeExact(effectslot, param, iValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSloti", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSloti"); }
+ }
+
+ public static void alAuxiliaryEffectSlotiv(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alAuxiliaryEffectSlotiv != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotiv.invokeExact(effectslot, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotiv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotiv"); }
+ }
+
+ public static void alAuxiliaryEffectSlotf(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALfloat") float flValue) {
+ if (Handles.MH_alAuxiliaryEffectSlotf != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotf.invokeExact(effectslot, param, flValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotf", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotf"); }
+ }
+
+ public static void alAuxiliaryEffectSlotfv(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alAuxiliaryEffectSlotfv != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotfv.invokeExact(effectslot, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotfv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotfv"); }
+ }
+
+ public static void alGetAuxiliaryEffectSloti(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValue) {
+ if (Handles.MH_alGetAuxiliaryEffectSloti != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSloti.invokeExact(effectslot, param, piValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSloti", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSloti"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotiv(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotiv != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotiv.invokeExact(effectslot, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotiv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotiv"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotf(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValue) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotf != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotf.invokeExact(effectslot, param, pflValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotf", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotf"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotfv(@CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotfv != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotfv.invokeExact(effectslot, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotfv", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotfv"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCEXTEFX() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTThreadLocalContext.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTThreadLocalContext.java
new file mode 100644
index 00000000..4fc02d27
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEXTThreadLocalContext.java
@@ -0,0 +1,61 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCEXTThreadLocalContext {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcSetThreadContext`.
+ public static final MethodHandle MH_alcSetThreadContext = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcSetThreadContext", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS));
+ /// The method handle of `alcGetThreadContext`.
+ public static final MethodHandle MH_alcGetThreadContext = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcGetThreadContext", FunctionDescriptor.of(ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static @CType("ALCboolean") boolean alcSetThreadContext(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
+ if (Handles.MH_alcSetThreadContext != null) {
+ try {
+ return (boolean) Handles.MH_alcSetThreadContext.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alcSetThreadContext", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcSetThreadContext"); }
+ }
+
+ public static @CType("ALCcontext *") java.lang.foreign.MemorySegment alcGetThreadContext() {
+ if (Handles.MH_alcGetThreadContext != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetThreadContext.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetThreadContext", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcGetThreadContext"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCEXTThreadLocalContext() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java
new file mode 100644
index 00000000..f0d49d58
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java
@@ -0,0 +1,54 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.upcall.*;
+import overrungl.util.*;
+
+@FunctionalInterface
+public interface ALCEventProcTypeSOFT extends Upcall {
+ /// The function descriptor.
+ FunctionDescriptor DESCRIPTOR = FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS);
+ /// The method handle of the target method.
+ MethodHandle HANDLE = Upcall.findTarget(ALCEventProcTypeSOFT.class, "invoke", DESCRIPTOR);
+
+ ///The target method of the upcall.
+ void invoke(@CType("ALCenum") int eventType, @CType("ALCenum") int deviceType, @CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCsizei") int length, @CType("const ALCchar*") java.lang.foreign.MemorySegment message, @CType("void*") java.lang.foreign.MemorySegment userParam);
+
+ @Override
+ default MemorySegment stub(Arena arena) { return Linker.nativeLinker().upcallStub(HANDLE.bindTo(this), DESCRIPTOR, arena); }
+
+ ///A static invoker of the target method.
+ ///@param stub the upcall stub
+ static void invoke(MemorySegment stub, @CType("ALCenum") int eventType, @CType("ALCenum") int deviceType, @CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCsizei") int length, @CType("const ALCchar*") java.lang.foreign.MemorySegment message, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ try { HANDLE.invokeExact(stub, eventType, deviceType, device, length, message, userParam); }
+ catch (Throwable e) { throw new RuntimeException("error in ALCEventProcTypeSOFT::invoke (static invoker)", e); }
+ }
+
+ /// A wrapper for the target method.
+ /// @param stub the upcall stub
+ /// @return an instance that wraps the static invoker
+ static ALCEventProcTypeSOFT wrap(MemorySegment stub) {
+ return (eventType, deviceType, device, length, message, userParam) -> { try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ invoke(stub, eventType, deviceType, device, length, Marshal.marshal(__overrungl_stack, message), userParam);
+ } };
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCLOKIAudioChannel.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCLOKIAudioChannel.java
new file mode 100644
index 00000000..91bf7e86
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCLOKIAudioChannel.java
@@ -0,0 +1,32 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCLOKIAudioChannel {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_CHAN_MAIN_LOKI = 0x500001;
+ public static final int ALC_CHAN_PCM_LOKI = 0x500002;
+ public static final int ALC_CHAN_CD_LOKI = 0x500003;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCLOKIAudioChannel() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTDeviceClock.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTDeviceClock.java
new file mode 100644
index 00000000..e517e2e6
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTDeviceClock.java
@@ -0,0 +1,56 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCSOFTDeviceClock {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_DEVICE_CLOCK_SOFT = 0x1600;
+ public static final int ALC_DEVICE_LATENCY_SOFT = 0x1601;
+ public static final int ALC_DEVICE_CLOCK_LATENCY_SOFT = 0x1602;
+ public static final int AL_SAMPLE_OFFSET_CLOCK_SOFT = 0x1202;
+ public static final int AL_SEC_OFFSET_CLOCK_SOFT = 0x1203;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcGetInteger64vSOFT`.
+ public static final MethodHandle MH_alcGetInteger64vSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcGetInteger64vSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alcGetInteger64vSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int pname, @CType("ALsizei") int size, @CType("ALCint64SOFT *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alcGetInteger64vSOFT != null) {
+ try {
+ Handles.MH_alcGetInteger64vSOFT.invokeExact(device, pname, size, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetInteger64vSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcGetInteger64vSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTDeviceClock() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTHRTF.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTHRTF.java
new file mode 100644
index 00000000..9f741db0
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTHRTF.java
@@ -0,0 +1,73 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCSOFTHRTF {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_HRTF_SOFT = 0x1992;
+ public static final int ALC_DONT_CARE_SOFT = 0x0002;
+ public static final int ALC_HRTF_STATUS_SOFT = 0x1993;
+ public static final int ALC_HRTF_DISABLED_SOFT = 0x0000;
+ public static final int ALC_HRTF_ENABLED_SOFT = 0x0001;
+ public static final int ALC_HRTF_DENIED_SOFT = 0x0002;
+ public static final int ALC_HRTF_REQUIRED_SOFT = 0x0003;
+ public static final int ALC_HRTF_HEADPHONES_DETECTED_SOFT = 0x0004;
+ public static final int ALC_HRTF_UNSUPPORTED_FORMAT_SOFT = 0x0005;
+ public static final int ALC_NUM_HRTF_SPECIFIERS_SOFT = 0x1994;
+ public static final int ALC_HRTF_SPECIFIER_SOFT = 0x1995;
+ public static final int ALC_HRTF_ID_SOFT = 0x1996;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcGetStringiSOFT`.
+ public static final MethodHandle MH_alcGetStringiSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcGetStringiSOFT", FunctionDescriptor.of(Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alcResetDeviceSOFT`.
+ public static final MethodHandle MH_alcResetDeviceSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcResetDeviceSOFT", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static @CType("const ALCchar*") java.lang.foreign.MemorySegment alcGetStringiSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCenum") int paramName, @CType("ALCsizei") int index) {
+ if (Handles.MH_alcGetStringiSOFT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetStringiSOFT.invokeExact(device, paramName, index);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetStringiSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcGetStringiSOFT"); }
+ }
+
+ public static @CType("ALCboolean") boolean alcResetDeviceSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCint *") java.lang.foreign.MemorySegment attribs) {
+ if (Handles.MH_alcResetDeviceSOFT != null) {
+ try {
+ return (boolean) Handles.MH_alcResetDeviceSOFT.invokeExact(device, attribs);
+ } catch (Throwable e) { throw new RuntimeException("error in alcResetDeviceSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcResetDeviceSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTHRTF() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopback.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopback.java
new file mode 100644
index 00000000..a4fcee2d
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopback.java
@@ -0,0 +1,86 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCSOFTLoopback {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_FORMAT_CHANNELS_SOFT = 0x1990;
+ public static final int ALC_FORMAT_TYPE_SOFT = 0x1991;
+ public static final int ALC_BYTE_SOFT = 0x1400;
+ public static final int ALC_UNSIGNED_BYTE_SOFT = 0x1401;
+ public static final int ALC_SHORT_SOFT = 0x1402;
+ public static final int ALC_UNSIGNED_SHORT_SOFT = 0x1403;
+ public static final int ALC_INT_SOFT = 0x1404;
+ public static final int ALC_UNSIGNED_INT_SOFT = 0x1405;
+ public static final int ALC_FLOAT_SOFT = 0x1406;
+ public static final int ALC_MONO_SOFT = 0x1500;
+ public static final int ALC_STEREO_SOFT = 0x1501;
+ public static final int ALC_QUAD_SOFT = 0x1503;
+ public static final int ALC_5POINT1_SOFT = 0x1504;
+ public static final int ALC_6POINT1_SOFT = 0x1505;
+ public static final int ALC_7POINT1_SOFT = 0x1506;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcLoopbackOpenDeviceSOFT`.
+ public static final MethodHandle MH_alcLoopbackOpenDeviceSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcLoopbackOpenDeviceSOFT", FunctionDescriptor.of(ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alcIsRenderFormatSupportedSOFT`.
+ public static final MethodHandle MH_alcIsRenderFormatSupportedSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcIsRenderFormatSupportedSOFT", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alcRenderSamplesSOFT`.
+ public static final MethodHandle MH_alcRenderSamplesSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcRenderSamplesSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ }
+ //endregion
+
+ public static @CType("ALCdevice *") java.lang.foreign.MemorySegment alcLoopbackOpenDeviceSOFT(@CType("const ALCchar*") java.lang.foreign.MemorySegment deviceName) {
+ if (Handles.MH_alcLoopbackOpenDeviceSOFT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcLoopbackOpenDeviceSOFT.invokeExact(deviceName);
+ } catch (Throwable e) { throw new RuntimeException("error in alcLoopbackOpenDeviceSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcLoopbackOpenDeviceSOFT"); }
+ }
+
+ public static @CType("ALCboolean") boolean alcIsRenderFormatSupportedSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCsizei") int freq, @CType("ALCenum") int channels, @CType("ALCenum") int type) {
+ if (Handles.MH_alcIsRenderFormatSupportedSOFT != null) {
+ try {
+ return (boolean) Handles.MH_alcIsRenderFormatSupportedSOFT.invokeExact(device, freq, channels, type);
+ } catch (Throwable e) { throw new RuntimeException("error in alcIsRenderFormatSupportedSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcIsRenderFormatSupportedSOFT"); }
+ }
+
+ public static void alcRenderSamplesSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("ALCvoid *") java.lang.foreign.MemorySegment buffer, @CType("ALCsizei") int samples) {
+ if (Handles.MH_alcRenderSamplesSOFT != null) {
+ try {
+ Handles.MH_alcRenderSamplesSOFT.invokeExact(device, buffer, samples);
+ } catch (Throwable e) { throw new RuntimeException("error in alcRenderSamplesSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcRenderSamplesSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTLoopback() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopbackBformat.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopbackBformat.java
new file mode 100644
index 00000000..d9c78928
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTLoopbackBformat.java
@@ -0,0 +1,38 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCSOFTLoopbackBformat {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_AMBISONIC_LAYOUT_SOFT = 0x1997;
+ public static final int ALC_AMBISONIC_SCALING_SOFT = 0x1998;
+ public static final int ALC_AMBISONIC_ORDER_SOFT = 0x1999;
+ public static final int ALC_MAX_AMBISONIC_ORDER_SOFT = 0x199B;
+ public static final int ALC_BFORMAT3D_SOFT = 0x1507;
+ public static final int ALC_FUMA_SOFT = 0x0000;
+ public static final int ALC_ACN_SOFT = 0x0001;
+ public static final int ALC_SN3D_SOFT = 0x0001;
+ public static final int ALC_N3D_SOFT = 0x0002;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTLoopbackBformat() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputLimiter.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputLimiter.java
new file mode 100644
index 00000000..bd893441
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputLimiter.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCSOFTOutputLimiter {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_OUTPUT_LIMITER_SOFT = 0x199A;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTOutputLimiter() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputMode.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputMode.java
new file mode 100644
index 00000000..34d46550
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTOutputMode.java
@@ -0,0 +1,37 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALCSOFTOutputMode {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_OUTPUT_MODE_SOFT = 0x19AC;
+ public static final int ALC_ANY_SOFT = 0x19AD;
+ public static final int ALC_STEREO_BASIC_SOFT = 0x19AE;
+ public static final int ALC_STEREO_UHJ_SOFT = 0x19AF;
+ public static final int ALC_STEREO_HRTF_SOFT = 0x19B2;
+ public static final int ALC_SURROUND_5_1_SOFT = 0x1504;
+ public static final int ALC_SURROUND_6_1_SOFT = 0x1505;
+ public static final int ALC_SURROUND_7_1_SOFT = 0x1506;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTOutputMode() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTPauseDevice.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTPauseDevice.java
new file mode 100644
index 00000000..f94ba70c
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTPauseDevice.java
@@ -0,0 +1,61 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCSOFTPauseDevice {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcDevicePauseSOFT`.
+ public static final MethodHandle MH_alcDevicePauseSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcDevicePauseSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alcDeviceResumeSOFT`.
+ public static final MethodHandle MH_alcDeviceResumeSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcDeviceResumeSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alcDevicePauseSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
+ if (Handles.MH_alcDevicePauseSOFT != null) {
+ try {
+ Handles.MH_alcDevicePauseSOFT.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcDevicePauseSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcDevicePauseSOFT"); }
+ }
+
+ public static void alcDeviceResumeSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device) {
+ if (Handles.MH_alcDeviceResumeSOFT != null) {
+ try {
+ Handles.MH_alcDeviceResumeSOFT.invokeExact(device);
+ } catch (Throwable e) { throw new RuntimeException("error in alcDeviceResumeSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcDeviceResumeSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTPauseDevice() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTReopenDevice.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTReopenDevice.java
new file mode 100644
index 00000000..0d20a4c7
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTReopenDevice.java
@@ -0,0 +1,51 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCSOFTReopenDevice {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcReopenDeviceSOFT`.
+ public static final MethodHandle MH_alcReopenDeviceSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcReopenDeviceSOFT", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static @CType("ALCboolean") boolean alcReopenDeviceSOFT(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment deviceName, @CType("const ALCint *") java.lang.foreign.MemorySegment attribs) {
+ if (Handles.MH_alcReopenDeviceSOFT != null) {
+ try {
+ return (boolean) Handles.MH_alcReopenDeviceSOFT.invokeExact(device, deviceName, attribs);
+ } catch (Throwable e) { throw new RuntimeException("error in alcReopenDeviceSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcReopenDeviceSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTReopenDevice() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTSystemEvents.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTSystemEvents.java
new file mode 100644
index 00000000..78c6eaa5
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCSOFTSystemEvents.java
@@ -0,0 +1,78 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALCSOFTSystemEvents {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int ALC_PLAYBACK_DEVICE_SOFT = 0x19D4;
+ public static final int ALC_CAPTURE_DEVICE_SOFT = 0x19D5;
+ public static final int ALC_EVENT_TYPE_DEFAULT_DEVICE_CHANGED_SOFT = 0x19D6;
+ public static final int ALC_EVENT_TYPE_DEVICE_ADDED_SOFT = 0x19D7;
+ public static final int ALC_EVENT_TYPE_DEVICE_REMOVED_SOFT = 0x19D8;
+ public static final int ALC_EVENT_SUPPORTED_SOFT = 0x19D9;
+ public static final int ALC_EVENT_NOT_SUPPORTED_SOFT = 0x19DA;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcEventIsSupportedSOFT`.
+ public static final MethodHandle MH_alcEventIsSupportedSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcEventIsSupportedSOFT", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alcEventControlSOFT`.
+ public static final MethodHandle MH_alcEventControlSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcEventControlSOFT", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_BOOLEAN));
+ /// The method handle of `alcEventCallbackSOFT`.
+ public static final MethodHandle MH_alcEventCallbackSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcEventCallbackSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static @CType("ALCenum") int alcEventIsSupportedSOFT(@CType("ALCenum") int eventType, @CType("ALCenum") int deviceType) {
+ if (Handles.MH_alcEventIsSupportedSOFT != null) {
+ try {
+ return (int) Handles.MH_alcEventIsSupportedSOFT.invokeExact(eventType, deviceType);
+ } catch (Throwable e) { throw new RuntimeException("error in alcEventIsSupportedSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcEventIsSupportedSOFT"); }
+ }
+
+ public static @CType("ALCboolean") boolean alcEventControlSOFT(@CType("ALCsizei") int count, @CType("const ALCenum *") java.lang.foreign.MemorySegment events, @CType("ALCboolean") boolean enable) {
+ if (Handles.MH_alcEventControlSOFT != null) {
+ try {
+ return (boolean) Handles.MH_alcEventControlSOFT.invokeExact(count, events, enable);
+ } catch (Throwable e) { throw new RuntimeException("error in alcEventControlSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcEventControlSOFT"); }
+ }
+
+ public static void alcEventCallbackSOFT(@CType("ALCEVENTPROCTYPESOFT") java.lang.foreign.MemorySegment callback, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ if (Handles.MH_alcEventCallbackSOFT != null) {
+ try {
+ Handles.MH_alcEventCallbackSOFT.invokeExact(callback, userParam);
+ } catch (Throwable e) { throw new RuntimeException("error in alcEventCallbackSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcEventCallbackSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALCSOFTSystemEvents() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java
new file mode 100644
index 00000000..b1ba18bf
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java
@@ -0,0 +1,54 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.upcall.*;
+import overrungl.util.*;
+
+@FunctionalInterface
+public interface ALDebugProcEXT extends Upcall {
+ /// The function descriptor.
+ FunctionDescriptor DESCRIPTOR = FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS);
+ /// The method handle of the target method.
+ MethodHandle HANDLE = Upcall.findTarget(ALDebugProcEXT.class, "invoke", DESCRIPTOR);
+
+ ///The target method of the upcall.
+ void invoke(@CType("ALenum") int source, @CType("ALenum") int type, @CType("ALuint") int id, @CType("ALenum") int severity, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message, @CType("void*") java.lang.foreign.MemorySegment userParam);
+
+ @Override
+ default MemorySegment stub(Arena arena) { return Linker.nativeLinker().upcallStub(HANDLE.bindTo(this), DESCRIPTOR, arena); }
+
+ ///A static invoker of the target method.
+ ///@param stub the upcall stub
+ static void invoke(MemorySegment stub, @CType("ALenum") int source, @CType("ALenum") int type, @CType("ALuint") int id, @CType("ALenum") int severity, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ try { HANDLE.invokeExact(stub, source, type, id, severity, length, message, userParam); }
+ catch (Throwable e) { throw new RuntimeException("error in ALDebugProcEXT::invoke (static invoker)", e); }
+ }
+
+ /// A wrapper for the target method.
+ /// @param stub the upcall stub
+ /// @return an instance that wraps the static invoker
+ static ALDebugProcEXT wrap(MemorySegment stub) {
+ return (source, type, id, severity, length, message, userParam) -> { try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ invoke(stub, source, type, id, severity, length, Marshal.marshal(__overrungl_stack, message), userParam);
+ } };
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTALAW.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTALAW.java
new file mode 100644
index 00000000..b71eb672
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTALAW.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTALAW {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_ALAW_EXT = 0x10016;
+ public static final int AL_FORMAT_STEREO_ALAW_EXT = 0x10017;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTALAW() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTBFORMAT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTBFORMAT.java
new file mode 100644
index 00000000..70623253
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTBFORMAT.java
@@ -0,0 +1,35 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTBFORMAT {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_BFORMAT2D_8 = 0x20021;
+ public static final int AL_FORMAT_BFORMAT2D_16 = 0x20022;
+ public static final int AL_FORMAT_BFORMAT2D_FLOAT32 = 0x20023;
+ public static final int AL_FORMAT_BFORMAT3D_8 = 0x20031;
+ public static final int AL_FORMAT_BFORMAT3D_16 = 0x20032;
+ public static final int AL_FORMAT_BFORMAT3D_FLOAT32 = 0x20033;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTBFORMAT() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDebug.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDebug.java
new file mode 100644
index 00000000..c871e2a1
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDebug.java
@@ -0,0 +1,177 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALEXTDebug {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_DONT_CARE_EXT = 0x0002;
+ public static final int AL_DEBUG_OUTPUT_EXT = 0x19B2;
+ public static final int AL_DEBUG_CALLBACK_FUNCTION_EXT = 0x19B3;
+ public static final int AL_DEBUG_CALLBACK_USER_PARAM_EXT = 0x19B4;
+ public static final int AL_DEBUG_SOURCE_API_EXT = 0x19B5;
+ public static final int AL_DEBUG_SOURCE_AUDIO_SYSTEM_EXT = 0x19B6;
+ public static final int AL_DEBUG_SOURCE_THIRD_PARTY_EXT = 0x19B7;
+ public static final int AL_DEBUG_SOURCE_APPLICATION_EXT = 0x19B8;
+ public static final int AL_DEBUG_SOURCE_OTHER_EXT = 0x19B9;
+ public static final int AL_DEBUG_TYPE_ERROR_EXT = 0x19BA;
+ public static final int AL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_EXT = 0x19BB;
+ public static final int AL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_EXT = 0x19BC;
+ public static final int AL_DEBUG_TYPE_PORTABILITY_EXT = 0x19BD;
+ public static final int AL_DEBUG_TYPE_PERFORMANCE_EXT = 0x19BE;
+ public static final int AL_DEBUG_TYPE_MARKER_EXT = 0x19BF;
+ public static final int AL_DEBUG_TYPE_PUSH_GROUP_EXT = 0x19C0;
+ public static final int AL_DEBUG_TYPE_POP_GROUP_EXT = 0x19C1;
+ public static final int AL_DEBUG_TYPE_OTHER_EXT = 0x19C2;
+ public static final int AL_DEBUG_SEVERITY_HIGH_EXT = 0x19C3;
+ public static final int AL_DEBUG_SEVERITY_MEDIUM_EXT = 0x19C4;
+ public static final int AL_DEBUG_SEVERITY_LOW_EXT = 0x19C5;
+ public static final int AL_DEBUG_SEVERITY_NOTIFICATION_EXT = 0x19C6;
+ public static final int AL_DEBUG_LOGGED_MESSAGES_EXT = 0x19C7;
+ public static final int AL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_EXT = 0x19C8;
+ public static final int AL_MAX_DEBUG_MESSAGE_LENGTH_EXT = 0x19C9;
+ public static final int AL_MAX_DEBUG_LOGGED_MESSAGES_EXT = 0x19CA;
+ public static final int AL_MAX_DEBUG_GROUP_STACK_DEPTH_EXT = 0x19CB;
+ public static final int AL_MAX_LABEL_LENGTH_EXT = 0x19CC;
+ public static final int AL_STACK_OVERFLOW_EXT = 0x19CD;
+ public static final int AL_STACK_UNDERFLOW_EXT = 0x19CE;
+ public static final int AL_CONTEXT_FLAGS_EXT = 0x19CF;
+ public static final int AL_BUFFER_EXT = 0x1009;
+ public static final int AL_SOURCE_EXT = 0x19D0;
+ public static final int AL_FILTER_EXT = 0x19D1;
+ public static final int AL_EFFECT_EXT = 0x19D2;
+ public static final int AL_AUXILIARY_EFFECT_SLOT_EXT = 0x19D3;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alDebugMessageCallbackEXT`.
+ public static final MethodHandle MH_alDebugMessageCallbackEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDebugMessageCallbackEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alDebugMessageInsertEXT`.
+ public static final MethodHandle MH_alDebugMessageInsertEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDebugMessageInsertEXT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alDebugMessageControlEXT`.
+ public static final MethodHandle MH_alDebugMessageControlEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDebugMessageControlEXT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_BOOLEAN));
+ /// The method handle of `alPushDebugGroupEXT`.
+ public static final MethodHandle MH_alPushDebugGroupEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alPushDebugGroupEXT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alPopDebugGroupEXT`.
+ public static final MethodHandle MH_alPopDebugGroupEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alPopDebugGroupEXT", FunctionDescriptor.ofVoid());
+ /// The method handle of `alGetDebugMessageLogEXT`.
+ public static final MethodHandle MH_alGetDebugMessageLogEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetDebugMessageLogEXT", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alObjectLabelEXT`.
+ public static final MethodHandle MH_alObjectLabelEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alObjectLabelEXT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetObjectLabelEXT`.
+ public static final MethodHandle MH_alGetObjectLabelEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetObjectLabelEXT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetPointerEXT`.
+ public static final MethodHandle MH_alGetPointerEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointerEXT", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetPointervEXT`.
+ public static final MethodHandle MH_alGetPointervEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointervEXT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alDebugMessageCallbackEXT(@CType("ALDEBUGPROCEXT") java.lang.foreign.MemorySegment callback, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ if (Handles.MH_alDebugMessageCallbackEXT != null) {
+ try {
+ Handles.MH_alDebugMessageCallbackEXT.invokeExact(callback, userParam);
+ } catch (Throwable e) { throw new RuntimeException("error in alDebugMessageCallbackEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDebugMessageCallbackEXT"); }
+ }
+
+ public static void alDebugMessageInsertEXT(@CType("ALenum") int source, @CType("ALenum") int type, @CType("ALuint") int id, @CType("ALenum") int severity, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message) {
+ if (Handles.MH_alDebugMessageInsertEXT != null) {
+ try {
+ Handles.MH_alDebugMessageInsertEXT.invokeExact(source, type, id, severity, length, message);
+ } catch (Throwable e) { throw new RuntimeException("error in alDebugMessageInsertEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDebugMessageInsertEXT"); }
+ }
+
+ public static void alDebugMessageControlEXT(@CType("ALenum") int source, @CType("ALenum") int type, @CType("ALenum") int severity, @CType("ALsizei") int count, @CType("const ALuint *") java.lang.foreign.MemorySegment ids, @CType("ALboolean") boolean enable) {
+ if (Handles.MH_alDebugMessageControlEXT != null) {
+ try {
+ Handles.MH_alDebugMessageControlEXT.invokeExact(source, type, severity, count, ids, enable);
+ } catch (Throwable e) { throw new RuntimeException("error in alDebugMessageControlEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDebugMessageControlEXT"); }
+ }
+
+ public static void alPushDebugGroupEXT(@CType("ALenum") int source, @CType("ALuint") int id, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message) {
+ if (Handles.MH_alPushDebugGroupEXT != null) {
+ try {
+ Handles.MH_alPushDebugGroupEXT.invokeExact(source, id, length, message);
+ } catch (Throwable e) { throw new RuntimeException("error in alPushDebugGroupEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alPushDebugGroupEXT"); }
+ }
+
+ public static void alPopDebugGroupEXT() {
+ if (Handles.MH_alPopDebugGroupEXT != null) {
+ try {
+ Handles.MH_alPopDebugGroupEXT.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alPopDebugGroupEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alPopDebugGroupEXT"); }
+ }
+
+ public static @CType("ALuint") int alGetDebugMessageLogEXT(@CType("ALuint") int count, @CType("ALsizei") int logBufSize, @CType("ALenum *") java.lang.foreign.MemorySegment sources, @CType("ALenum *") java.lang.foreign.MemorySegment types, @CType("ALuint *") java.lang.foreign.MemorySegment ids, @CType("ALenum *") java.lang.foreign.MemorySegment severities, @CType("ALsizei *") java.lang.foreign.MemorySegment lengths, @CType("ALchar*") java.lang.foreign.MemorySegment logBuf) {
+ if (Handles.MH_alGetDebugMessageLogEXT != null) {
+ try {
+ return (int) Handles.MH_alGetDebugMessageLogEXT.invokeExact(count, logBufSize, sources, types, ids, severities, lengths, logBuf);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDebugMessageLogEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetDebugMessageLogEXT"); }
+ }
+
+ public static void alObjectLabelEXT(@CType("ALenum") int identifier, @CType("ALuint") int name, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment label) {
+ if (Handles.MH_alObjectLabelEXT != null) {
+ try {
+ Handles.MH_alObjectLabelEXT.invokeExact(identifier, name, length, label);
+ } catch (Throwable e) { throw new RuntimeException("error in alObjectLabelEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alObjectLabelEXT"); }
+ }
+
+ public static void alGetObjectLabelEXT(@CType("ALenum") int identifier, @CType("ALuint") int name, @CType("ALsizei") int bufSize, @CType("ALsizei *") java.lang.foreign.MemorySegment length, @CType("ALchar*") java.lang.foreign.MemorySegment label) {
+ if (Handles.MH_alGetObjectLabelEXT != null) {
+ try {
+ Handles.MH_alGetObjectLabelEXT.invokeExact(identifier, name, bufSize, length, label);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetObjectLabelEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetObjectLabelEXT"); }
+ }
+
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetPointerEXT(@CType("ALenum") int pname) {
+ if (Handles.MH_alGetPointerEXT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetPointerEXT.invokeExact(pname);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointerEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointerEXT"); }
+ }
+
+ public static void alGetPointervEXT(@CType("ALenum") int pname, @CType("void**") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetPointervEXT != null) {
+ try {
+ Handles.MH_alGetPointervEXT.invokeExact(pname, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointervEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointervEXT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTDebug() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDirectContext.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDirectContext.java
new file mode 100644
index 00000000..4fbd3f6a
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDirectContext.java
@@ -0,0 +1,1531 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALEXTDirectContext {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alcGetProcAddress2`.
+ public static final MethodHandle MH_alcGetProcAddress2 = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alcGetProcAddress2", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alEnableDirect`.
+ public static final MethodHandle MH_alEnableDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEnableDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alDisableDirect`.
+ public static final MethodHandle MH_alDisableDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDisableDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alIsEnabledDirect`.
+ public static final MethodHandle MH_alIsEnabledDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsEnabledDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alDopplerFactorDirect`.
+ public static final MethodHandle MH_alDopplerFactorDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDopplerFactorDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alSpeedOfSoundDirect`.
+ public static final MethodHandle MH_alSpeedOfSoundDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSpeedOfSoundDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alDistanceModelDirect`.
+ public static final MethodHandle MH_alDistanceModelDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDistanceModelDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetStringDirect`.
+ public static final MethodHandle MH_alGetStringDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetStringDirect", FunctionDescriptor.of(Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetBooleanvDirect`.
+ public static final MethodHandle MH_alGetBooleanvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBooleanvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetIntegervDirect`.
+ public static final MethodHandle MH_alGetIntegervDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetIntegervDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFloatvDirect`.
+ public static final MethodHandle MH_alGetFloatvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFloatvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetDoublevDirect`.
+ public static final MethodHandle MH_alGetDoublevDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetDoublevDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBooleanDirect`.
+ public static final MethodHandle MH_alGetBooleanDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBooleanDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetIntegerDirect`.
+ public static final MethodHandle MH_alGetIntegerDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetIntegerDirect", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetFloatDirect`.
+ public static final MethodHandle MH_alGetFloatDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFloatDirect", FunctionDescriptor.of(ValueLayout.JAVA_FLOAT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetDoubleDirect`.
+ public static final MethodHandle MH_alGetDoubleDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetDoubleDirect", FunctionDescriptor.of(ValueLayout.JAVA_DOUBLE, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetErrorDirect`.
+ public static final MethodHandle MH_alGetErrorDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetErrorDirect", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsExtensionPresentDirect`.
+ public static final MethodHandle MH_alIsExtensionPresentDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsExtensionPresentDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetProcAddressDirect`.
+ public static final MethodHandle MH_alGetProcAddressDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetProcAddressDirect", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetEnumValueDirect`.
+ public static final MethodHandle MH_alGetEnumValueDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEnumValueDirect", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alListenerfDirect`.
+ public static final MethodHandle MH_alListenerfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alListenerfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alListener3fDirect`.
+ public static final MethodHandle MH_alListener3fDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alListener3fDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alListenerfvDirect`.
+ public static final MethodHandle MH_alListenerfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alListenerfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alListeneriDirect`.
+ public static final MethodHandle MH_alListeneriDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alListeneriDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alListener3iDirect`.
+ public static final MethodHandle MH_alListener3iDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alListener3iDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alListenerivDirect`.
+ public static final MethodHandle MH_alListenerivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alListenerivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListenerfDirect`.
+ public static final MethodHandle MH_alGetListenerfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetListenerfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListener3fDirect`.
+ public static final MethodHandle MH_alGetListener3fDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetListener3fDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListenerfvDirect`.
+ public static final MethodHandle MH_alGetListenerfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetListenerfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListeneriDirect`.
+ public static final MethodHandle MH_alGetListeneriDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetListeneriDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListener3iDirect`.
+ public static final MethodHandle MH_alGetListener3iDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetListener3iDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetListenerivDirect`.
+ public static final MethodHandle MH_alGetListenerivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetListenerivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenSourcesDirect`.
+ public static final MethodHandle MH_alGenSourcesDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenSourcesDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteSourcesDirect`.
+ public static final MethodHandle MH_alDeleteSourcesDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteSourcesDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsSourceDirect`.
+ public static final MethodHandle MH_alIsSourceDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsSourceDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcefDirect`.
+ public static final MethodHandle MH_alSourcefDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcefDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alSource3fDirect`.
+ public static final MethodHandle MH_alSource3fDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSource3fDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alSourcefvDirect`.
+ public static final MethodHandle MH_alSourcefvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcefvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceiDirect`.
+ public static final MethodHandle MH_alSourceiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alSource3iDirect`.
+ public static final MethodHandle MH_alSource3iDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSource3iDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourceivDirect`.
+ public static final MethodHandle MH_alSourceivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcefDirect`.
+ public static final MethodHandle MH_alGetSourcefDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcefDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3fDirect`.
+ public static final MethodHandle MH_alGetSource3fDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSource3fDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcefvDirect`.
+ public static final MethodHandle MH_alGetSourcefvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcefvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourceiDirect`.
+ public static final MethodHandle MH_alGetSourceiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourceiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3iDirect`.
+ public static final MethodHandle MH_alGetSource3iDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSource3iDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourceivDirect`.
+ public static final MethodHandle MH_alGetSourceivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourceivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcePlayDirect`.
+ public static final MethodHandle MH_alSourcePlayDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePlayDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourceStopDirect`.
+ public static final MethodHandle MH_alSourceStopDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceStopDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourceRewindDirect`.
+ public static final MethodHandle MH_alSourceRewindDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceRewindDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcePauseDirect`.
+ public static final MethodHandle MH_alSourcePauseDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePauseDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcePlayvDirect`.
+ public static final MethodHandle MH_alSourcePlayvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePlayvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceStopvDirect`.
+ public static final MethodHandle MH_alSourceStopvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceStopvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceRewindvDirect`.
+ public static final MethodHandle MH_alSourceRewindvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceRewindvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcePausevDirect`.
+ public static final MethodHandle MH_alSourcePausevDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePausevDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceQueueBuffersDirect`.
+ public static final MethodHandle MH_alSourceQueueBuffersDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceQueueBuffersDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourceUnqueueBuffersDirect`.
+ public static final MethodHandle MH_alSourceUnqueueBuffersDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourceUnqueueBuffersDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenBuffersDirect`.
+ public static final MethodHandle MH_alGenBuffersDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenBuffersDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteBuffersDirect`.
+ public static final MethodHandle MH_alDeleteBuffersDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteBuffersDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsBufferDirect`.
+ public static final MethodHandle MH_alIsBufferDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsBufferDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alBufferDataDirect`.
+ public static final MethodHandle MH_alBufferDataDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferDataDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alBufferfDirect`.
+ public static final MethodHandle MH_alBufferfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alBuffer3fDirect`.
+ public static final MethodHandle MH_alBuffer3fDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBuffer3fDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alBufferfvDirect`.
+ public static final MethodHandle MH_alBufferfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alBufferiDirect`.
+ public static final MethodHandle MH_alBufferiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alBuffer3iDirect`.
+ public static final MethodHandle MH_alBuffer3iDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBuffer3iDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alBufferivDirect`.
+ public static final MethodHandle MH_alBufferivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferfDirect`.
+ public static final MethodHandle MH_alGetBufferfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBuffer3fDirect`.
+ public static final MethodHandle MH_alGetBuffer3fDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBuffer3fDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferfvDirect`.
+ public static final MethodHandle MH_alGetBufferfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferiDirect`.
+ public static final MethodHandle MH_alGetBufferiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBuffer3iDirect`.
+ public static final MethodHandle MH_alGetBuffer3iDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBuffer3iDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferivDirect`.
+ public static final MethodHandle MH_alGetBufferivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenEffectsDirect`.
+ public static final MethodHandle MH_alGenEffectsDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenEffectsDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteEffectsDirect`.
+ public static final MethodHandle MH_alDeleteEffectsDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteEffectsDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsEffectDirect`.
+ public static final MethodHandle MH_alIsEffectDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsEffectDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alEffectiDirect`.
+ public static final MethodHandle MH_alEffectiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alEffectivDirect`.
+ public static final MethodHandle MH_alEffectivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alEffectfDirect`.
+ public static final MethodHandle MH_alEffectfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alEffectfvDirect`.
+ public static final MethodHandle MH_alEffectfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEffectfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectiDirect`.
+ public static final MethodHandle MH_alGetEffectiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectivDirect`.
+ public static final MethodHandle MH_alGetEffectivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectfDirect`.
+ public static final MethodHandle MH_alGetEffectfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetEffectfvDirect`.
+ public static final MethodHandle MH_alGetEffectfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetEffectfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenFiltersDirect`.
+ public static final MethodHandle MH_alGenFiltersDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenFiltersDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteFiltersDirect`.
+ public static final MethodHandle MH_alDeleteFiltersDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteFiltersDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsFilterDirect`.
+ public static final MethodHandle MH_alIsFilterDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsFilterDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alFilteriDirect`.
+ public static final MethodHandle MH_alFilteriDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilteriDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alFilterivDirect`.
+ public static final MethodHandle MH_alFilterivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilterivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alFilterfDirect`.
+ public static final MethodHandle MH_alFilterfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilterfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alFilterfvDirect`.
+ public static final MethodHandle MH_alFilterfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alFilterfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilteriDirect`.
+ public static final MethodHandle MH_alGetFilteriDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilteriDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilterivDirect`.
+ public static final MethodHandle MH_alGetFilterivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilterivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilterfDirect`.
+ public static final MethodHandle MH_alGetFilterfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilterfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetFilterfvDirect`.
+ public static final MethodHandle MH_alGetFilterfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetFilterfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGenAuxiliaryEffectSlotsDirect`.
+ public static final MethodHandle MH_alGenAuxiliaryEffectSlotsDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGenAuxiliaryEffectSlotsDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeleteAuxiliaryEffectSlotsDirect`.
+ public static final MethodHandle MH_alDeleteAuxiliaryEffectSlotsDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeleteAuxiliaryEffectSlotsDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsAuxiliaryEffectSlotDirect`.
+ public static final MethodHandle MH_alIsAuxiliaryEffectSlotDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsAuxiliaryEffectSlotDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alAuxiliaryEffectSlotiDirect`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alAuxiliaryEffectSlotivDirect`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alAuxiliaryEffectSlotfDirect`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_FLOAT));
+ /// The method handle of `alAuxiliaryEffectSlotfvDirect`.
+ public static final MethodHandle MH_alAuxiliaryEffectSlotfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alAuxiliaryEffectSlotfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotiDirect`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotiDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotiDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotivDirect`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotivDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotivDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotfDirect`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotfDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotfDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetAuxiliaryEffectSlotfvDirect`.
+ public static final MethodHandle MH_alGetAuxiliaryEffectSlotfvDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetAuxiliaryEffectSlotfvDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alBufferDataStaticDirect`.
+ public static final MethodHandle MH_alBufferDataStaticDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferDataStaticDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alDebugMessageCallbackDirectEXT`.
+ public static final MethodHandle MH_alDebugMessageCallbackDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDebugMessageCallbackDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alDebugMessageInsertDirectEXT`.
+ public static final MethodHandle MH_alDebugMessageInsertDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDebugMessageInsertDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alDebugMessageControlDirectEXT`.
+ public static final MethodHandle MH_alDebugMessageControlDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDebugMessageControlDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_BOOLEAN));
+ /// The method handle of `alPushDebugGroupDirectEXT`.
+ public static final MethodHandle MH_alPushDebugGroupDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alPushDebugGroupDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alPopDebugGroupDirectEXT`.
+ public static final MethodHandle MH_alPopDebugGroupDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alPopDebugGroupDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alGetDebugMessageLogDirectEXT`.
+ public static final MethodHandle MH_alGetDebugMessageLogDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetDebugMessageLogDirectEXT", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alObjectLabelDirectEXT`.
+ public static final MethodHandle MH_alObjectLabelDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alObjectLabelDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetObjectLabelDirectEXT`.
+ public static final MethodHandle MH_alGetObjectLabelDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetObjectLabelDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, Unmarshal.STR_LAYOUT));
+ /// The method handle of `alGetPointerDirectEXT`.
+ public static final MethodHandle MH_alGetPointerDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointerDirectEXT", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetPointervDirectEXT`.
+ public static final MethodHandle MH_alGetPointervDirectEXT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointervDirectEXT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alRequestFoldbackStartDirect`.
+ public static final MethodHandle MH_alRequestFoldbackStartDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alRequestFoldbackStartDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alRequestFoldbackStopDirect`.
+ public static final MethodHandle MH_alRequestFoldbackStopDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alRequestFoldbackStopDirect", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alBufferSubDataDirectSOFT`.
+ public static final MethodHandle MH_alBufferSubDataDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferSubDataDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alSourcedDirectSOFT`.
+ public static final MethodHandle MH_alSourcedDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcedDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_DOUBLE));
+ /// The method handle of `alSource3dDirectSOFT`.
+ public static final MethodHandle MH_alSource3dDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSource3dDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_DOUBLE, ValueLayout.JAVA_DOUBLE, ValueLayout.JAVA_DOUBLE));
+ /// The method handle of `alSourcedvDirectSOFT`.
+ public static final MethodHandle MH_alSourcedvDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcedvDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcedDirectSOFT`.
+ public static final MethodHandle MH_alGetSourcedDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcedDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3dDirectSOFT`.
+ public static final MethodHandle MH_alGetSource3dDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSource3dDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcedvDirectSOFT`.
+ public static final MethodHandle MH_alGetSourcedvDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcedvDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcei64DirectSOFT`.
+ public static final MethodHandle MH_alSourcei64DirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcei64DirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_LONG));
+ /// The method handle of `alSource3i64DirectSOFT`.
+ public static final MethodHandle MH_alSource3i64DirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSource3i64DirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_LONG, ValueLayout.JAVA_LONG, ValueLayout.JAVA_LONG));
+ /// The method handle of `alSourcei64vDirectSOFT`.
+ public static final MethodHandle MH_alSourcei64vDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcei64vDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcei64DirectSOFT`.
+ public static final MethodHandle MH_alGetSourcei64DirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcei64DirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3i64DirectSOFT`.
+ public static final MethodHandle MH_alGetSource3i64DirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSource3i64DirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcei64vDirectSOFT`.
+ public static final MethodHandle MH_alGetSourcei64vDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcei64vDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alDeferUpdatesDirectSOFT`.
+ public static final MethodHandle MH_alDeferUpdatesDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeferUpdatesDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alProcessUpdatesDirectSOFT`.
+ public static final MethodHandle MH_alProcessUpdatesDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alProcessUpdatesDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS));
+ /// The method handle of `alGetStringiDirectSOFT`.
+ public static final MethodHandle MH_alGetStringiDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetStringiDirectSOFT", FunctionDescriptor.of(Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ /// The method handle of `alEventControlDirectSOFT`.
+ public static final MethodHandle MH_alEventControlDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEventControlDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_BOOLEAN));
+ /// The method handle of `alEventCallbackDirectSOFT`.
+ public static final MethodHandle MH_alEventCallbackDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEventCallbackDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetPointerDirectSOFT`.
+ public static final MethodHandle MH_alGetPointerDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointerDirectSOFT", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetPointervDirectSOFT`.
+ public static final MethodHandle MH_alGetPointervDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointervDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alBufferCallbackDirectSOFT`.
+ public static final MethodHandle MH_alBufferCallbackDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferCallbackDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferPtrDirectSOFT`.
+ public static final MethodHandle MH_alGetBufferPtrDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferPtrDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBuffer3PtrDirectSOFT`.
+ public static final MethodHandle MH_alGetBuffer3PtrDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBuffer3PtrDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferPtrvDirectSOFT`.
+ public static final MethodHandle MH_alGetBufferPtrvDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferPtrvDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcePlayAtTimeDirectSOFT`.
+ public static final MethodHandle MH_alSourcePlayAtTimeDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePlayAtTimeDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_LONG));
+ /// The method handle of `alSourcePlayAtTimevDirectSOFT`.
+ public static final MethodHandle MH_alSourcePlayAtTimevDirectSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePlayAtTimevDirectSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_LONG));
+ /// The method handle of `EAXSetDirect`.
+ public static final MethodHandle MH_EAXSetDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "EAXSetDirect", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `EAXGetDirect`.
+ public static final MethodHandle MH_EAXGetDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "EAXGetDirect", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `EAXSetBufferModeDirect`.
+ public static final MethodHandle MH_EAXSetBufferModeDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "EAXSetBufferModeDirect", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `EAXGetBufferModeDirect`.
+ public static final MethodHandle MH_EAXGetBufferModeDirect = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "EAXGetBufferModeDirect", FunctionDescriptor.of(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static @CType("ALCvoid *") java.lang.foreign.MemorySegment alcGetProcAddress2(@CType("ALCdevice *") java.lang.foreign.MemorySegment device, @CType("const ALCchar*") java.lang.foreign.MemorySegment funcName) {
+ if (Handles.MH_alcGetProcAddress2 != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alcGetProcAddress2.invokeExact(device, funcName);
+ } catch (Throwable e) { throw new RuntimeException("error in alcGetProcAddress2", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alcGetProcAddress2"); }
+ }
+
+ public static void alEnableDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int capability) {
+ if (Handles.MH_alEnableDirect != null) {
+ try {
+ Handles.MH_alEnableDirect.invokeExact(context, capability);
+ } catch (Throwable e) { throw new RuntimeException("error in alEnableDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEnableDirect"); }
+ }
+
+ public static void alDisableDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int capability) {
+ if (Handles.MH_alDisableDirect != null) {
+ try {
+ Handles.MH_alDisableDirect.invokeExact(context, capability);
+ } catch (Throwable e) { throw new RuntimeException("error in alDisableDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDisableDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsEnabledDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int capability) {
+ if (Handles.MH_alIsEnabledDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsEnabledDirect.invokeExact(context, capability);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsEnabledDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsEnabledDirect"); }
+ }
+
+ public static void alDopplerFactorDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALfloat") float value) {
+ if (Handles.MH_alDopplerFactorDirect != null) {
+ try {
+ Handles.MH_alDopplerFactorDirect.invokeExact(context, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alDopplerFactorDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDopplerFactorDirect"); }
+ }
+
+ public static void alSpeedOfSoundDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALfloat") float value) {
+ if (Handles.MH_alSpeedOfSoundDirect != null) {
+ try {
+ Handles.MH_alSpeedOfSoundDirect.invokeExact(context, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSpeedOfSoundDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSpeedOfSoundDirect"); }
+ }
+
+ public static void alDistanceModelDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int distanceModel) {
+ if (Handles.MH_alDistanceModelDirect != null) {
+ try {
+ Handles.MH_alDistanceModelDirect.invokeExact(context, distanceModel);
+ } catch (Throwable e) { throw new RuntimeException("error in alDistanceModelDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDistanceModelDirect"); }
+ }
+
+ public static @CType("const ALchar*") java.lang.foreign.MemorySegment alGetStringDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param) {
+ if (Handles.MH_alGetStringDirect != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetStringDirect.invokeExact(context, param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetStringDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetStringDirect"); }
+ }
+
+ public static void alGetBooleanvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALboolean *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetBooleanvDirect != null) {
+ try {
+ Handles.MH_alGetBooleanvDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBooleanvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBooleanvDirect"); }
+ }
+
+ public static void alGetIntegervDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetIntegervDirect != null) {
+ try {
+ Handles.MH_alGetIntegervDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetIntegervDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetIntegervDirect"); }
+ }
+
+ public static void alGetFloatvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetFloatvDirect != null) {
+ try {
+ Handles.MH_alGetFloatvDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFloatvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFloatvDirect"); }
+ }
+
+ public static void alGetDoublevDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetDoublevDirect != null) {
+ try {
+ Handles.MH_alGetDoublevDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDoublevDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetDoublevDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alGetBooleanDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param) {
+ if (Handles.MH_alGetBooleanDirect != null) {
+ try {
+ return (boolean) Handles.MH_alGetBooleanDirect.invokeExact(context, param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBooleanDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBooleanDirect"); }
+ }
+
+ public static @CType("ALint") int alGetIntegerDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param) {
+ if (Handles.MH_alGetIntegerDirect != null) {
+ try {
+ return (int) Handles.MH_alGetIntegerDirect.invokeExact(context, param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetIntegerDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetIntegerDirect"); }
+ }
+
+ public static @CType("ALfloat") float alGetFloatDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param) {
+ if (Handles.MH_alGetFloatDirect != null) {
+ try {
+ return (float) Handles.MH_alGetFloatDirect.invokeExact(context, param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFloatDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFloatDirect"); }
+ }
+
+ public static @CType("ALdouble") double alGetDoubleDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param) {
+ if (Handles.MH_alGetDoubleDirect != null) {
+ try {
+ return (double) Handles.MH_alGetDoubleDirect.invokeExact(context, param);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDoubleDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetDoubleDirect"); }
+ }
+
+ public static @CType("ALenum") int alGetErrorDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
+ if (Handles.MH_alGetErrorDirect != null) {
+ try {
+ return (int) Handles.MH_alGetErrorDirect.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetErrorDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetErrorDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsExtensionPresentDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("const ALchar*") java.lang.foreign.MemorySegment extname) {
+ if (Handles.MH_alIsExtensionPresentDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsExtensionPresentDirect.invokeExact(context, extname);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsExtensionPresentDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsExtensionPresentDirect"); }
+ }
+
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetProcAddressDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("const ALchar*") java.lang.foreign.MemorySegment fname) {
+ if (Handles.MH_alGetProcAddressDirect != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetProcAddressDirect.invokeExact(context, fname);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetProcAddressDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetProcAddressDirect"); }
+ }
+
+ public static @CType("ALenum") int alGetEnumValueDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("const ALchar*") java.lang.foreign.MemorySegment ename) {
+ if (Handles.MH_alGetEnumValueDirect != null) {
+ try {
+ return (int) Handles.MH_alGetEnumValueDirect.invokeExact(context, ename);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEnumValueDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEnumValueDirect"); }
+ }
+
+ public static void alListenerfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALfloat") float value) {
+ if (Handles.MH_alListenerfDirect != null) {
+ try {
+ Handles.MH_alListenerfDirect.invokeExact(context, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alListenerfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alListenerfDirect"); }
+ }
+
+ public static void alListener3fDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALfloat") float value1, @CType("ALfloat") float value2, @CType("ALfloat") float value3) {
+ if (Handles.MH_alListener3fDirect != null) {
+ try {
+ Handles.MH_alListener3fDirect.invokeExact(context, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alListener3fDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alListener3fDirect"); }
+ }
+
+ public static void alListenerfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alListenerfvDirect != null) {
+ try {
+ Handles.MH_alListenerfvDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alListenerfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alListenerfvDirect"); }
+ }
+
+ public static void alListeneriDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALint") int value) {
+ if (Handles.MH_alListeneriDirect != null) {
+ try {
+ Handles.MH_alListeneriDirect.invokeExact(context, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alListeneriDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alListeneriDirect"); }
+ }
+
+ public static void alListener3iDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALint") int value1, @CType("ALint") int value2, @CType("ALint") int value3) {
+ if (Handles.MH_alListener3iDirect != null) {
+ try {
+ Handles.MH_alListener3iDirect.invokeExact(context, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alListener3iDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alListener3iDirect"); }
+ }
+
+ public static void alListenerivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alListenerivDirect != null) {
+ try {
+ Handles.MH_alListenerivDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alListenerivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alListenerivDirect"); }
+ }
+
+ public static void alGetListenerfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetListenerfDirect != null) {
+ try {
+ Handles.MH_alGetListenerfDirect.invokeExact(context, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetListenerfDirect"); }
+ }
+
+ public static void alGetListener3fDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment value1, @CType("ALfloat *") java.lang.foreign.MemorySegment value2, @CType("ALfloat *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetListener3fDirect != null) {
+ try {
+ Handles.MH_alGetListener3fDirect.invokeExact(context, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListener3fDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetListener3fDirect"); }
+ }
+
+ public static void alGetListenerfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetListenerfvDirect != null) {
+ try {
+ Handles.MH_alGetListenerfvDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetListenerfvDirect"); }
+ }
+
+ public static void alGetListeneriDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetListeneriDirect != null) {
+ try {
+ Handles.MH_alGetListeneriDirect.invokeExact(context, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListeneriDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetListeneriDirect"); }
+ }
+
+ public static void alGetListener3iDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment value1, @CType("ALint *") java.lang.foreign.MemorySegment value2, @CType("ALint *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetListener3iDirect != null) {
+ try {
+ Handles.MH_alGetListener3iDirect.invokeExact(context, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListener3iDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetListener3iDirect"); }
+ }
+
+ public static void alGetListenerivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetListenerivDirect != null) {
+ try {
+ Handles.MH_alGetListenerivDirect.invokeExact(context, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetListenerivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetListenerivDirect"); }
+ }
+
+ public static void alGenSourcesDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment sources) {
+ if (Handles.MH_alGenSourcesDirect != null) {
+ try {
+ Handles.MH_alGenSourcesDirect.invokeExact(context, n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenSourcesDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenSourcesDirect"); }
+ }
+
+ public static void alDeleteSourcesDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ if (Handles.MH_alDeleteSourcesDirect != null) {
+ try {
+ Handles.MH_alDeleteSourcesDirect.invokeExact(context, n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteSourcesDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteSourcesDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsSourceDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source) {
+ if (Handles.MH_alIsSourceDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsSourceDirect.invokeExact(context, source);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsSourceDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsSourceDirect"); }
+ }
+
+ public static void alSourcefDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat") float value) {
+ if (Handles.MH_alSourcefDirect != null) {
+ try {
+ Handles.MH_alSourcefDirect.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcefDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcefDirect"); }
+ }
+
+ public static void alSource3fDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat") float value1, @CType("ALfloat") float value2, @CType("ALfloat") float value3) {
+ if (Handles.MH_alSource3fDirect != null) {
+ try {
+ Handles.MH_alSource3fDirect.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3fDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSource3fDirect"); }
+ }
+
+ public static void alSourcefvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alSourcefvDirect != null) {
+ try {
+ Handles.MH_alSourcefvDirect.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcefvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcefvDirect"); }
+ }
+
+ public static void alSourceiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint") int value) {
+ if (Handles.MH_alSourceiDirect != null) {
+ try {
+ Handles.MH_alSourceiDirect.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceiDirect"); }
+ }
+
+ public static void alSource3iDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint") int value1, @CType("ALint") int value2, @CType("ALint") int value3) {
+ if (Handles.MH_alSource3iDirect != null) {
+ try {
+ Handles.MH_alSource3iDirect.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3iDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSource3iDirect"); }
+ }
+
+ public static void alSourceivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alSourceivDirect != null) {
+ try {
+ Handles.MH_alSourceivDirect.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceivDirect"); }
+ }
+
+ public static void alGetSourcefDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetSourcefDirect != null) {
+ try {
+ Handles.MH_alGetSourcefDirect.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcefDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcefDirect"); }
+ }
+
+ public static void alGetSource3fDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment value1, @CType("ALfloat *") java.lang.foreign.MemorySegment value2, @CType("ALfloat *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetSource3fDirect != null) {
+ try {
+ Handles.MH_alGetSource3fDirect.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3fDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSource3fDirect"); }
+ }
+
+ public static void alGetSourcefvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetSourcefvDirect != null) {
+ try {
+ Handles.MH_alGetSourcefvDirect.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcefvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcefvDirect"); }
+ }
+
+ public static void alGetSourceiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetSourceiDirect != null) {
+ try {
+ Handles.MH_alGetSourceiDirect.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourceiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourceiDirect"); }
+ }
+
+ public static void alGetSource3iDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment value1, @CType("ALint *") java.lang.foreign.MemorySegment value2, @CType("ALint *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetSource3iDirect != null) {
+ try {
+ Handles.MH_alGetSource3iDirect.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3iDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSource3iDirect"); }
+ }
+
+ public static void alGetSourceivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetSourceivDirect != null) {
+ try {
+ Handles.MH_alGetSourceivDirect.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourceivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourceivDirect"); }
+ }
+
+ public static void alSourcePlayDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source) {
+ if (Handles.MH_alSourcePlayDirect != null) {
+ try {
+ Handles.MH_alSourcePlayDirect.invokeExact(context, source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePlayDirect"); }
+ }
+
+ public static void alSourceStopDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source) {
+ if (Handles.MH_alSourceStopDirect != null) {
+ try {
+ Handles.MH_alSourceStopDirect.invokeExact(context, source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceStopDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceStopDirect"); }
+ }
+
+ public static void alSourceRewindDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source) {
+ if (Handles.MH_alSourceRewindDirect != null) {
+ try {
+ Handles.MH_alSourceRewindDirect.invokeExact(context, source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceRewindDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceRewindDirect"); }
+ }
+
+ public static void alSourcePauseDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source) {
+ if (Handles.MH_alSourcePauseDirect != null) {
+ try {
+ Handles.MH_alSourcePauseDirect.invokeExact(context, source);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePauseDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePauseDirect"); }
+ }
+
+ public static void alSourcePlayvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ if (Handles.MH_alSourcePlayvDirect != null) {
+ try {
+ Handles.MH_alSourcePlayvDirect.invokeExact(context, n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePlayvDirect"); }
+ }
+
+ public static void alSourceStopvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ if (Handles.MH_alSourceStopvDirect != null) {
+ try {
+ Handles.MH_alSourceStopvDirect.invokeExact(context, n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceStopvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceStopvDirect"); }
+ }
+
+ public static void alSourceRewindvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ if (Handles.MH_alSourceRewindvDirect != null) {
+ try {
+ Handles.MH_alSourceRewindvDirect.invokeExact(context, n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceRewindvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceRewindvDirect"); }
+ }
+
+ public static void alSourcePausevDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources) {
+ if (Handles.MH_alSourcePausevDirect != null) {
+ try {
+ Handles.MH_alSourcePausevDirect.invokeExact(context, n, sources);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePausevDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePausevDirect"); }
+ }
+
+ public static void alSourceQueueBuffersDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALsizei") int nb, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers) {
+ if (Handles.MH_alSourceQueueBuffersDirect != null) {
+ try {
+ Handles.MH_alSourceQueueBuffersDirect.invokeExact(context, source, nb, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceQueueBuffersDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceQueueBuffersDirect"); }
+ }
+
+ public static void alSourceUnqueueBuffersDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALsizei") int nb, @CType("ALuint *") java.lang.foreign.MemorySegment buffers) {
+ if (Handles.MH_alSourceUnqueueBuffersDirect != null) {
+ try {
+ Handles.MH_alSourceUnqueueBuffersDirect.invokeExact(context, source, nb, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourceUnqueueBuffersDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourceUnqueueBuffersDirect"); }
+ }
+
+ public static void alGenBuffersDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment buffers) {
+ if (Handles.MH_alGenBuffersDirect != null) {
+ try {
+ Handles.MH_alGenBuffersDirect.invokeExact(context, n, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenBuffersDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenBuffersDirect"); }
+ }
+
+ public static void alDeleteBuffersDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers) {
+ if (Handles.MH_alDeleteBuffersDirect != null) {
+ try {
+ Handles.MH_alDeleteBuffersDirect.invokeExact(context, n, buffers);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteBuffersDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteBuffersDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsBufferDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer) {
+ if (Handles.MH_alIsBufferDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsBufferDirect.invokeExact(context, buffer);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsBufferDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsBufferDirect"); }
+ }
+
+ public static void alBufferDataDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int format, @CType("const ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int size, @CType("ALsizei") int samplerate) {
+ if (Handles.MH_alBufferDataDirect != null) {
+ try {
+ Handles.MH_alBufferDataDirect.invokeExact(context, buffer, format, data, size, samplerate);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferDataDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferDataDirect"); }
+ }
+
+ public static void alBufferfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat") float value) {
+ if (Handles.MH_alBufferfDirect != null) {
+ try {
+ Handles.MH_alBufferfDirect.invokeExact(context, buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferfDirect"); }
+ }
+
+ public static void alBuffer3fDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat") float value1, @CType("ALfloat") float value2, @CType("ALfloat") float value3) {
+ if (Handles.MH_alBuffer3fDirect != null) {
+ try {
+ Handles.MH_alBuffer3fDirect.invokeExact(context, buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alBuffer3fDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBuffer3fDirect"); }
+ }
+
+ public static void alBufferfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alBufferfvDirect != null) {
+ try {
+ Handles.MH_alBufferfvDirect.invokeExact(context, buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferfvDirect"); }
+ }
+
+ public static void alBufferiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint") int value) {
+ if (Handles.MH_alBufferiDirect != null) {
+ try {
+ Handles.MH_alBufferiDirect.invokeExact(context, buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferiDirect"); }
+ }
+
+ public static void alBuffer3iDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint") int value1, @CType("ALint") int value2, @CType("ALint") int value3) {
+ if (Handles.MH_alBuffer3iDirect != null) {
+ try {
+ Handles.MH_alBuffer3iDirect.invokeExact(context, buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alBuffer3iDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBuffer3iDirect"); }
+ }
+
+ public static void alBufferivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alBufferivDirect != null) {
+ try {
+ Handles.MH_alBufferivDirect.invokeExact(context, buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferivDirect"); }
+ }
+
+ public static void alGetBufferfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetBufferfDirect != null) {
+ try {
+ Handles.MH_alGetBufferfDirect.invokeExact(context, buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferfDirect"); }
+ }
+
+ public static void alGetBuffer3fDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment value1, @CType("ALfloat *") java.lang.foreign.MemorySegment value2, @CType("ALfloat *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetBuffer3fDirect != null) {
+ try {
+ Handles.MH_alGetBuffer3fDirect.invokeExact(context, buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3fDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBuffer3fDirect"); }
+ }
+
+ public static void alGetBufferfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetBufferfvDirect != null) {
+ try {
+ Handles.MH_alGetBufferfvDirect.invokeExact(context, buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferfvDirect"); }
+ }
+
+ public static void alGetBufferiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetBufferiDirect != null) {
+ try {
+ Handles.MH_alGetBufferiDirect.invokeExact(context, buffer, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferiDirect"); }
+ }
+
+ public static void alGetBuffer3iDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment value1, @CType("ALint *") java.lang.foreign.MemorySegment value2, @CType("ALint *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetBuffer3iDirect != null) {
+ try {
+ Handles.MH_alGetBuffer3iDirect.invokeExact(context, buffer, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3iDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBuffer3iDirect"); }
+ }
+
+ public static void alGetBufferivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetBufferivDirect != null) {
+ try {
+ Handles.MH_alGetBufferivDirect.invokeExact(context, buffer, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferivDirect"); }
+ }
+
+ public static void alGenEffectsDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment effects) {
+ if (Handles.MH_alGenEffectsDirect != null) {
+ try {
+ Handles.MH_alGenEffectsDirect.invokeExact(context, n, effects);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenEffectsDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenEffectsDirect"); }
+ }
+
+ public static void alDeleteEffectsDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment effects) {
+ if (Handles.MH_alDeleteEffectsDirect != null) {
+ try {
+ Handles.MH_alDeleteEffectsDirect.invokeExact(context, n, effects);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteEffectsDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteEffectsDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsEffectDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect) {
+ if (Handles.MH_alIsEffectDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsEffectDirect.invokeExact(context, effect);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsEffectDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsEffectDirect"); }
+ }
+
+ public static void alEffectiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALint") int iValue) {
+ if (Handles.MH_alEffectiDirect != null) {
+ try {
+ Handles.MH_alEffectiDirect.invokeExact(context, effect, param, iValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectiDirect"); }
+ }
+
+ public static void alEffectivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alEffectivDirect != null) {
+ try {
+ Handles.MH_alEffectivDirect.invokeExact(context, effect, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectivDirect"); }
+ }
+
+ public static void alEffectfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALfloat") float flValue) {
+ if (Handles.MH_alEffectfDirect != null) {
+ try {
+ Handles.MH_alEffectfDirect.invokeExact(context, effect, param, flValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectfDirect"); }
+ }
+
+ public static void alEffectfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alEffectfvDirect != null) {
+ try {
+ Handles.MH_alEffectfvDirect.invokeExact(context, effect, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alEffectfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEffectfvDirect"); }
+ }
+
+ public static void alGetEffectiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValue) {
+ if (Handles.MH_alGetEffectiDirect != null) {
+ try {
+ Handles.MH_alGetEffectiDirect.invokeExact(context, effect, param, piValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectiDirect"); }
+ }
+
+ public static void alGetEffectivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alGetEffectivDirect != null) {
+ try {
+ Handles.MH_alGetEffectivDirect.invokeExact(context, effect, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectivDirect"); }
+ }
+
+ public static void alGetEffectfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValue) {
+ if (Handles.MH_alGetEffectfDirect != null) {
+ try {
+ Handles.MH_alGetEffectfDirect.invokeExact(context, effect, param, pflValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectfDirect"); }
+ }
+
+ public static void alGetEffectfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effect, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alGetEffectfvDirect != null) {
+ try {
+ Handles.MH_alGetEffectfvDirect.invokeExact(context, effect, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetEffectfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetEffectfvDirect"); }
+ }
+
+ public static void alGenFiltersDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment filters) {
+ if (Handles.MH_alGenFiltersDirect != null) {
+ try {
+ Handles.MH_alGenFiltersDirect.invokeExact(context, n, filters);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenFiltersDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenFiltersDirect"); }
+ }
+
+ public static void alDeleteFiltersDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment filters) {
+ if (Handles.MH_alDeleteFiltersDirect != null) {
+ try {
+ Handles.MH_alDeleteFiltersDirect.invokeExact(context, n, filters);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteFiltersDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteFiltersDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsFilterDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter) {
+ if (Handles.MH_alIsFilterDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsFilterDirect.invokeExact(context, filter);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsFilterDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsFilterDirect"); }
+ }
+
+ public static void alFilteriDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALint") int iValue) {
+ if (Handles.MH_alFilteriDirect != null) {
+ try {
+ Handles.MH_alFilteriDirect.invokeExact(context, filter, param, iValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilteriDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilteriDirect"); }
+ }
+
+ public static void alFilterivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alFilterivDirect != null) {
+ try {
+ Handles.MH_alFilterivDirect.invokeExact(context, filter, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilterivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilterivDirect"); }
+ }
+
+ public static void alFilterfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALfloat") float flValue) {
+ if (Handles.MH_alFilterfDirect != null) {
+ try {
+ Handles.MH_alFilterfDirect.invokeExact(context, filter, param, flValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilterfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilterfDirect"); }
+ }
+
+ public static void alFilterfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alFilterfvDirect != null) {
+ try {
+ Handles.MH_alFilterfvDirect.invokeExact(context, filter, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alFilterfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alFilterfvDirect"); }
+ }
+
+ public static void alGetFilteriDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValue) {
+ if (Handles.MH_alGetFilteriDirect != null) {
+ try {
+ Handles.MH_alGetFilteriDirect.invokeExact(context, filter, param, piValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilteriDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilteriDirect"); }
+ }
+
+ public static void alGetFilterivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alGetFilterivDirect != null) {
+ try {
+ Handles.MH_alGetFilterivDirect.invokeExact(context, filter, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilterivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilterivDirect"); }
+ }
+
+ public static void alGetFilterfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValue) {
+ if (Handles.MH_alGetFilterfDirect != null) {
+ try {
+ Handles.MH_alGetFilterfDirect.invokeExact(context, filter, param, pflValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilterfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilterfDirect"); }
+ }
+
+ public static void alGetFilterfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int filter, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alGetFilterfvDirect != null) {
+ try {
+ Handles.MH_alGetFilterfvDirect.invokeExact(context, filter, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetFilterfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetFilterfvDirect"); }
+ }
+
+ public static void alGenAuxiliaryEffectSlotsDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("ALuint *") java.lang.foreign.MemorySegment effectslots) {
+ if (Handles.MH_alGenAuxiliaryEffectSlotsDirect != null) {
+ try {
+ Handles.MH_alGenAuxiliaryEffectSlotsDirect.invokeExact(context, n, effectslots);
+ } catch (Throwable e) { throw new RuntimeException("error in alGenAuxiliaryEffectSlotsDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGenAuxiliaryEffectSlotsDirect"); }
+ }
+
+ public static void alDeleteAuxiliaryEffectSlotsDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment effectslots) {
+ if (Handles.MH_alDeleteAuxiliaryEffectSlotsDirect != null) {
+ try {
+ Handles.MH_alDeleteAuxiliaryEffectSlotsDirect.invokeExact(context, n, effectslots);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeleteAuxiliaryEffectSlotsDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeleteAuxiliaryEffectSlotsDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsAuxiliaryEffectSlotDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot) {
+ if (Handles.MH_alIsAuxiliaryEffectSlotDirect != null) {
+ try {
+ return (boolean) Handles.MH_alIsAuxiliaryEffectSlotDirect.invokeExact(context, effectslot);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsAuxiliaryEffectSlotDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsAuxiliaryEffectSlotDirect"); }
+ }
+
+ public static void alAuxiliaryEffectSlotiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALint") int iValue) {
+ if (Handles.MH_alAuxiliaryEffectSlotiDirect != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotiDirect.invokeExact(context, effectslot, param, iValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotiDirect"); }
+ }
+
+ public static void alAuxiliaryEffectSlotivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("const ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alAuxiliaryEffectSlotivDirect != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotivDirect.invokeExact(context, effectslot, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotivDirect"); }
+ }
+
+ public static void alAuxiliaryEffectSlotfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALfloat") float flValue) {
+ if (Handles.MH_alAuxiliaryEffectSlotfDirect != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotfDirect.invokeExact(context, effectslot, param, flValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotfDirect"); }
+ }
+
+ public static void alAuxiliaryEffectSlotfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("const ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alAuxiliaryEffectSlotfvDirect != null) {
+ try {
+ Handles.MH_alAuxiliaryEffectSlotfvDirect.invokeExact(context, effectslot, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alAuxiliaryEffectSlotfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alAuxiliaryEffectSlotfvDirect"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotiDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValue) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotiDirect != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotiDirect.invokeExact(context, effectslot, param, piValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotiDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotiDirect"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotivDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALint *") java.lang.foreign.MemorySegment piValues) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotivDirect != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotivDirect.invokeExact(context, effectslot, param, piValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotivDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotivDirect"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotfDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValue) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotfDirect != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotfDirect.invokeExact(context, effectslot, param, pflValue);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotfDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotfDirect"); }
+ }
+
+ public static void alGetAuxiliaryEffectSlotfvDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int effectslot, @CType("ALenum") int param, @CType("ALfloat *") java.lang.foreign.MemorySegment pflValues) {
+ if (Handles.MH_alGetAuxiliaryEffectSlotfvDirect != null) {
+ try {
+ Handles.MH_alGetAuxiliaryEffectSlotfvDirect.invokeExact(context, effectslot, param, pflValues);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetAuxiliaryEffectSlotfvDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetAuxiliaryEffectSlotfvDirect"); }
+ }
+
+ public static void alBufferDataStaticDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int format, @CType("ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int size, @CType("ALsizei") int freq) {
+ if (Handles.MH_alBufferDataStaticDirect != null) {
+ try {
+ Handles.MH_alBufferDataStaticDirect.invokeExact(context, buffer, format, data, size, freq);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferDataStaticDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferDataStaticDirect"); }
+ }
+
+ public static void alDebugMessageCallbackDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALDEBUGPROCEXT") java.lang.foreign.MemorySegment callback, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ if (Handles.MH_alDebugMessageCallbackDirectEXT != null) {
+ try {
+ Handles.MH_alDebugMessageCallbackDirectEXT.invokeExact(context, callback, userParam);
+ } catch (Throwable e) { throw new RuntimeException("error in alDebugMessageCallbackDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDebugMessageCallbackDirectEXT"); }
+ }
+
+ public static void alDebugMessageInsertDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int source, @CType("ALenum") int type, @CType("ALuint") int id, @CType("ALenum") int severity, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message) {
+ if (Handles.MH_alDebugMessageInsertDirectEXT != null) {
+ try {
+ Handles.MH_alDebugMessageInsertDirectEXT.invokeExact(context, source, type, id, severity, length, message);
+ } catch (Throwable e) { throw new RuntimeException("error in alDebugMessageInsertDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDebugMessageInsertDirectEXT"); }
+ }
+
+ public static void alDebugMessageControlDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int source, @CType("ALenum") int type, @CType("ALenum") int severity, @CType("ALsizei") int count, @CType("const ALuint *") java.lang.foreign.MemorySegment ids, @CType("ALboolean") boolean enable) {
+ if (Handles.MH_alDebugMessageControlDirectEXT != null) {
+ try {
+ Handles.MH_alDebugMessageControlDirectEXT.invokeExact(context, source, type, severity, count, ids, enable);
+ } catch (Throwable e) { throw new RuntimeException("error in alDebugMessageControlDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDebugMessageControlDirectEXT"); }
+ }
+
+ public static void alPushDebugGroupDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int source, @CType("ALuint") int id, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message) {
+ if (Handles.MH_alPushDebugGroupDirectEXT != null) {
+ try {
+ Handles.MH_alPushDebugGroupDirectEXT.invokeExact(context, source, id, length, message);
+ } catch (Throwable e) { throw new RuntimeException("error in alPushDebugGroupDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alPushDebugGroupDirectEXT"); }
+ }
+
+ public static void alPopDebugGroupDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
+ if (Handles.MH_alPopDebugGroupDirectEXT != null) {
+ try {
+ Handles.MH_alPopDebugGroupDirectEXT.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alPopDebugGroupDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alPopDebugGroupDirectEXT"); }
+ }
+
+ public static @CType("ALuint") int alGetDebugMessageLogDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int count, @CType("ALsizei") int logBufSize, @CType("ALenum *") java.lang.foreign.MemorySegment sources, @CType("ALenum *") java.lang.foreign.MemorySegment types, @CType("ALuint *") java.lang.foreign.MemorySegment ids, @CType("ALenum *") java.lang.foreign.MemorySegment severities, @CType("ALsizei *") java.lang.foreign.MemorySegment lengths, @CType("ALchar*") java.lang.foreign.MemorySegment logBuf) {
+ if (Handles.MH_alGetDebugMessageLogDirectEXT != null) {
+ try {
+ return (int) Handles.MH_alGetDebugMessageLogDirectEXT.invokeExact(context, count, logBufSize, sources, types, ids, severities, lengths, logBuf);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetDebugMessageLogDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetDebugMessageLogDirectEXT"); }
+ }
+
+ public static void alObjectLabelDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int identifier, @CType("ALuint") int name, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment label) {
+ if (Handles.MH_alObjectLabelDirectEXT != null) {
+ try {
+ Handles.MH_alObjectLabelDirectEXT.invokeExact(context, identifier, name, length, label);
+ } catch (Throwable e) { throw new RuntimeException("error in alObjectLabelDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alObjectLabelDirectEXT"); }
+ }
+
+ public static void alGetObjectLabelDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int identifier, @CType("ALuint") int name, @CType("ALsizei") int bufSize, @CType("ALsizei *") java.lang.foreign.MemorySegment length, @CType("ALchar*") java.lang.foreign.MemorySegment label) {
+ if (Handles.MH_alGetObjectLabelDirectEXT != null) {
+ try {
+ Handles.MH_alGetObjectLabelDirectEXT.invokeExact(context, identifier, name, bufSize, length, label);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetObjectLabelDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetObjectLabelDirectEXT"); }
+ }
+
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetPointerDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int pname) {
+ if (Handles.MH_alGetPointerDirectEXT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetPointerDirectEXT.invokeExact(context, pname);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointerDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointerDirectEXT"); }
+ }
+
+ public static void alGetPointervDirectEXT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int pname, @CType("void**") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetPointervDirectEXT != null) {
+ try {
+ Handles.MH_alGetPointervDirectEXT.invokeExact(context, pname, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointervDirectEXT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointervDirectEXT"); }
+ }
+
+ public static void alRequestFoldbackStartDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int mode, @CType("ALsizei") int count, @CType("ALsizei") int length, @CType("ALfloat *") java.lang.foreign.MemorySegment mem, @CType("LPALFOLDBACKCALLBACK") java.lang.foreign.MemorySegment callback) {
+ if (Handles.MH_alRequestFoldbackStartDirect != null) {
+ try {
+ Handles.MH_alRequestFoldbackStartDirect.invokeExact(context, mode, count, length, mem, callback);
+ } catch (Throwable e) { throw new RuntimeException("error in alRequestFoldbackStartDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alRequestFoldbackStartDirect"); }
+ }
+
+ public static void alRequestFoldbackStopDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
+ if (Handles.MH_alRequestFoldbackStopDirect != null) {
+ try {
+ Handles.MH_alRequestFoldbackStopDirect.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alRequestFoldbackStopDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alRequestFoldbackStopDirect"); }
+ }
+
+ public static void alBufferSubDataDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int format, @CType("const ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int offset, @CType("ALsizei") int length) {
+ if (Handles.MH_alBufferSubDataDirectSOFT != null) {
+ try {
+ Handles.MH_alBufferSubDataDirectSOFT.invokeExact(context, buffer, format, data, offset, length);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferSubDataDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferSubDataDirectSOFT"); }
+ }
+
+ public static void alSourcedDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble") double value) {
+ if (Handles.MH_alSourcedDirectSOFT != null) {
+ try {
+ Handles.MH_alSourcedDirectSOFT.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcedDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcedDirectSOFT"); }
+ }
+
+ public static void alSource3dDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble") double value1, @CType("ALdouble") double value2, @CType("ALdouble") double value3) {
+ if (Handles.MH_alSource3dDirectSOFT != null) {
+ try {
+ Handles.MH_alSource3dDirectSOFT.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3dDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSource3dDirectSOFT"); }
+ }
+
+ public static void alSourcedvDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALdouble *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alSourcedvDirectSOFT != null) {
+ try {
+ Handles.MH_alSourcedvDirectSOFT.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcedvDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcedvDirectSOFT"); }
+ }
+
+ public static void alGetSourcedDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetSourcedDirectSOFT != null) {
+ try {
+ Handles.MH_alGetSourcedDirectSOFT.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcedDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcedDirectSOFT"); }
+ }
+
+ public static void alGetSource3dDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment value1, @CType("ALdouble *") java.lang.foreign.MemorySegment value2, @CType("ALdouble *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetSource3dDirectSOFT != null) {
+ try {
+ Handles.MH_alGetSource3dDirectSOFT.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3dDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSource3dDirectSOFT"); }
+ }
+
+ public static void alGetSourcedvDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetSourcedvDirectSOFT != null) {
+ try {
+ Handles.MH_alGetSourcedvDirectSOFT.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcedvDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcedvDirectSOFT"); }
+ }
+
+ public static void alSourcei64DirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT") long value) {
+ if (Handles.MH_alSourcei64DirectSOFT != null) {
+ try {
+ Handles.MH_alSourcei64DirectSOFT.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcei64DirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcei64DirectSOFT"); }
+ }
+
+ public static void alSource3i64DirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT") long value1, @CType("ALint64SOFT") long value2, @CType("ALint64SOFT") long value3) {
+ if (Handles.MH_alSource3i64DirectSOFT != null) {
+ try {
+ Handles.MH_alSource3i64DirectSOFT.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3i64DirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSource3i64DirectSOFT"); }
+ }
+
+ public static void alSourcei64vDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALint64SOFT *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alSourcei64vDirectSOFT != null) {
+ try {
+ Handles.MH_alSourcei64vDirectSOFT.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcei64vDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcei64vDirectSOFT"); }
+ }
+
+ public static void alGetSourcei64DirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetSourcei64DirectSOFT != null) {
+ try {
+ Handles.MH_alGetSourcei64DirectSOFT.invokeExact(context, source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcei64DirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcei64DirectSOFT"); }
+ }
+
+ public static void alGetSource3i64DirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value1, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value2, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetSource3i64DirectSOFT != null) {
+ try {
+ Handles.MH_alGetSource3i64DirectSOFT.invokeExact(context, source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3i64DirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSource3i64DirectSOFT"); }
+ }
+
+ public static void alGetSourcei64vDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetSourcei64vDirectSOFT != null) {
+ try {
+ Handles.MH_alGetSourcei64vDirectSOFT.invokeExact(context, source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcei64vDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcei64vDirectSOFT"); }
+ }
+
+ public static void alDeferUpdatesDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
+ if (Handles.MH_alDeferUpdatesDirectSOFT != null) {
+ try {
+ Handles.MH_alDeferUpdatesDirectSOFT.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alDeferUpdatesDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeferUpdatesDirectSOFT"); }
+ }
+
+ public static void alProcessUpdatesDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context) {
+ if (Handles.MH_alProcessUpdatesDirectSOFT != null) {
+ try {
+ Handles.MH_alProcessUpdatesDirectSOFT.invokeExact(context);
+ } catch (Throwable e) { throw new RuntimeException("error in alProcessUpdatesDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alProcessUpdatesDirectSOFT"); }
+ }
+
+ public static @CType("const ALchar*") java.lang.foreign.MemorySegment alGetStringiDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int pname, @CType("ALsizei") int index) {
+ if (Handles.MH_alGetStringiDirectSOFT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetStringiDirectSOFT.invokeExact(context, pname, index);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetStringiDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetStringiDirectSOFT"); }
+ }
+
+ public static void alEventControlDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int count, @CType("const ALenum *") java.lang.foreign.MemorySegment types, @CType("ALboolean") boolean enable) {
+ if (Handles.MH_alEventControlDirectSOFT != null) {
+ try {
+ Handles.MH_alEventControlDirectSOFT.invokeExact(context, count, types, enable);
+ } catch (Throwable e) { throw new RuntimeException("error in alEventControlDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEventControlDirectSOFT"); }
+ }
+
+ public static void alEventCallbackDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALEVENTPROCSOFT") java.lang.foreign.MemorySegment callback, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ if (Handles.MH_alEventCallbackDirectSOFT != null) {
+ try {
+ Handles.MH_alEventCallbackDirectSOFT.invokeExact(context, callback, userParam);
+ } catch (Throwable e) { throw new RuntimeException("error in alEventCallbackDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEventCallbackDirectSOFT"); }
+ }
+
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetPointerDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int pname) {
+ if (Handles.MH_alGetPointerDirectSOFT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetPointerDirectSOFT.invokeExact(context, pname);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointerDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointerDirectSOFT"); }
+ }
+
+ public static void alGetPointervDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALenum") int pname, @CType("void**") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetPointervDirectSOFT != null) {
+ try {
+ Handles.MH_alGetPointervDirectSOFT.invokeExact(context, pname, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointervDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointervDirectSOFT"); }
+ }
+
+ public static void alBufferCallbackDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int format, @CType("ALsizei") int freq, @CType("ALBUFFERCALLBACKTYPESOFT") java.lang.foreign.MemorySegment callback, @CType("ALvoid *") java.lang.foreign.MemorySegment userptr) {
+ if (Handles.MH_alBufferCallbackDirectSOFT != null) {
+ try {
+ Handles.MH_alBufferCallbackDirectSOFT.invokeExact(context, buffer, format, freq, callback, userptr);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferCallbackDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferCallbackDirectSOFT"); }
+ }
+
+ public static void alGetBufferPtrDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr) {
+ if (Handles.MH_alGetBufferPtrDirectSOFT != null) {
+ try {
+ Handles.MH_alGetBufferPtrDirectSOFT.invokeExact(context, buffer, param, ptr);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferPtrDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferPtrDirectSOFT"); }
+ }
+
+ public static void alGetBuffer3PtrDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr0, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr1, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr2) {
+ if (Handles.MH_alGetBuffer3PtrDirectSOFT != null) {
+ try {
+ Handles.MH_alGetBuffer3PtrDirectSOFT.invokeExact(context, buffer, param, ptr0, ptr1, ptr2);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3PtrDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBuffer3PtrDirectSOFT"); }
+ }
+
+ public static void alGetBufferPtrvDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr) {
+ if (Handles.MH_alGetBufferPtrvDirectSOFT != null) {
+ try {
+ Handles.MH_alGetBufferPtrvDirectSOFT.invokeExact(context, buffer, param, ptr);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferPtrvDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferPtrvDirectSOFT"); }
+ }
+
+ public static void alSourcePlayAtTimeDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int source, @CType("ALint64SOFT") long start_time) {
+ if (Handles.MH_alSourcePlayAtTimeDirectSOFT != null) {
+ try {
+ Handles.MH_alSourcePlayAtTimeDirectSOFT.invokeExact(context, source, start_time);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayAtTimeDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePlayAtTimeDirectSOFT"); }
+ }
+
+ public static void alSourcePlayAtTimevDirectSOFT(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources, @CType("ALint64SOFT") long start_time) {
+ if (Handles.MH_alSourcePlayAtTimevDirectSOFT != null) {
+ try {
+ Handles.MH_alSourcePlayAtTimevDirectSOFT.invokeExact(context, n, sources, start_time);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayAtTimevDirectSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePlayAtTimevDirectSOFT"); }
+ }
+
+ public static @CType("ALenum") int EAXSetDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("const struct _GUID *") java.lang.foreign.MemorySegment property_set_id, @CType("ALuint") int property_id, @CType("ALuint") int source_id, @CType("ALvoid *") java.lang.foreign.MemorySegment value, @CType("ALuint") int value_size) {
+ if (Handles.MH_EAXSetDirect != null) {
+ try {
+ return (int) Handles.MH_EAXSetDirect.invokeExact(context, property_set_id, property_id, source_id, value, value_size);
+ } catch (Throwable e) { throw new RuntimeException("error in EAXSetDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: EAXSetDirect"); }
+ }
+
+ public static @CType("ALenum") int EAXGetDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("const struct _GUID *") java.lang.foreign.MemorySegment property_set_id, @CType("ALuint") int property_id, @CType("ALuint") int source_id, @CType("ALvoid *") java.lang.foreign.MemorySegment value, @CType("ALuint") int value_size) {
+ if (Handles.MH_EAXGetDirect != null) {
+ try {
+ return (int) Handles.MH_EAXGetDirect.invokeExact(context, property_set_id, property_id, source_id, value, value_size);
+ } catch (Throwable e) { throw new RuntimeException("error in EAXGetDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: EAXGetDirect"); }
+ }
+
+ public static @CType("ALboolean") boolean EAXSetBufferModeDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment buffers, @CType("ALint") int value) {
+ if (Handles.MH_EAXSetBufferModeDirect != null) {
+ try {
+ return (boolean) Handles.MH_EAXSetBufferModeDirect.invokeExact(context, n, buffers, value);
+ } catch (Throwable e) { throw new RuntimeException("error in EAXSetBufferModeDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: EAXSetBufferModeDirect"); }
+ }
+
+ public static @CType("ALenum") int EAXGetBufferModeDirect(@CType("ALCcontext *") java.lang.foreign.MemorySegment context, @CType("ALuint") int buffer, @CType("ALint *") java.lang.foreign.MemorySegment pReserved) {
+ if (Handles.MH_EAXGetBufferModeDirect != null) {
+ try {
+ return (int) Handles.MH_EAXGetBufferModeDirect.invokeExact(context, buffer, pReserved);
+ } catch (Throwable e) { throw new RuntimeException("error in EAXGetBufferModeDirect", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: EAXGetBufferModeDirect"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTDirectContext() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDouble.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDouble.java
new file mode 100644
index 00000000..0b04018e
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTDouble.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTDouble {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_DOUBLE_EXT = 0x10012;
+ public static final int AL_FORMAT_STEREO_DOUBLE_EXT = 0x10013;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTDouble() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFOLDBACK.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFOLDBACK.java
new file mode 100644
index 00000000..18e5ee4e
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFOLDBACK.java
@@ -0,0 +1,67 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALEXTFOLDBACK {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final java.lang.String AL_EXT_FOLDBACK_NAME = "AL_EXT_FOLDBACK";
+ public static final int AL_FOLDBACK_EVENT_BLOCK = 0x4112;
+ public static final int AL_FOLDBACK_EVENT_START = 0x4111;
+ public static final int AL_FOLDBACK_EVENT_STOP = 0x4113;
+ public static final int AL_FOLDBACK_MODE_MONO = 0x4101;
+ public static final int AL_FOLDBACK_MODE_STEREO = 0x4102;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alRequestFoldbackStart`.
+ public static final MethodHandle MH_alRequestFoldbackStart = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alRequestFoldbackStart", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alRequestFoldbackStop`.
+ public static final MethodHandle MH_alRequestFoldbackStop = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alRequestFoldbackStop", FunctionDescriptor.ofVoid());
+ }
+ //endregion
+
+ public static void alRequestFoldbackStart(@CType("ALenum") int mode, @CType("ALsizei") int count, @CType("ALsizei") int length, @CType("ALfloat *") java.lang.foreign.MemorySegment mem, @CType("LPALFOLDBACKCALLBACK") java.lang.foreign.MemorySegment callback) {
+ if (Handles.MH_alRequestFoldbackStart != null) {
+ try {
+ Handles.MH_alRequestFoldbackStart.invokeExact(mode, count, length, mem, callback);
+ } catch (Throwable e) { throw new RuntimeException("error in alRequestFoldbackStart", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alRequestFoldbackStart"); }
+ }
+
+ public static void alRequestFoldbackStop() {
+ if (Handles.MH_alRequestFoldbackStop != null) {
+ try {
+ Handles.MH_alRequestFoldbackStop.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alRequestFoldbackStop", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alRequestFoldbackStop"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTFOLDBACK() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFloat32.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFloat32.java
new file mode 100644
index 00000000..5d9b9f8d
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTFloat32.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTFloat32 {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_FLOAT32 = 0x10010;
+ public static final int AL_FORMAT_STEREO_FLOAT32 = 0x10011;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTFloat32() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTIMA4.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTIMA4.java
new file mode 100644
index 00000000..75d7b041
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTIMA4.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTIMA4 {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_IMA4 = 0x1300;
+ public static final int AL_FORMAT_STEREO_IMA4 = 0x1301;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTIMA4() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMCFORMATS.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMCFORMATS.java
new file mode 100644
index 00000000..9ec5da52
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMCFORMATS.java
@@ -0,0 +1,44 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTMCFORMATS {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_QUAD8 = 0x1204;
+ public static final int AL_FORMAT_QUAD16 = 0x1205;
+ public static final int AL_FORMAT_QUAD32 = 0x1206;
+ public static final int AL_FORMAT_REAR8 = 0x1207;
+ public static final int AL_FORMAT_REAR16 = 0x1208;
+ public static final int AL_FORMAT_REAR32 = 0x1209;
+ public static final int AL_FORMAT_51CHN8 = 0x120A;
+ public static final int AL_FORMAT_51CHN16 = 0x120B;
+ public static final int AL_FORMAT_51CHN32 = 0x120C;
+ public static final int AL_FORMAT_61CHN8 = 0x120D;
+ public static final int AL_FORMAT_61CHN16 = 0x120E;
+ public static final int AL_FORMAT_61CHN32 = 0x120F;
+ public static final int AL_FORMAT_71CHN8 = 0x1210;
+ public static final int AL_FORMAT_71CHN16 = 0x1211;
+ public static final int AL_FORMAT_71CHN32 = 0x1212;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTMCFORMATS() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAW.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAW.java
new file mode 100644
index 00000000..8a560d1f
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAW.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTMULAW {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_MULAW_EXT = 0x10014;
+ public static final int AL_FORMAT_STEREO_MULAW_EXT = 0x10015;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTMULAW() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWBFORMAT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWBFORMAT.java
new file mode 100644
index 00000000..5550dbe1
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWBFORMAT.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTMULAWBFORMAT {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_BFORMAT2D_MULAW = 0x10031;
+ public static final int AL_FORMAT_BFORMAT3D_MULAW = 0x10032;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTMULAWBFORMAT() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWMCFORMATS.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWMCFORMATS.java
new file mode 100644
index 00000000..61e3d64b
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTMULAWMCFORMATS.java
@@ -0,0 +1,36 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTMULAWMCFORMATS {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_MULAW = 0x10014;
+ public static final int AL_FORMAT_STEREO_MULAW = 0x10015;
+ public static final int AL_FORMAT_QUAD_MULAW = 0x10021;
+ public static final int AL_FORMAT_REAR_MULAW = 0x10022;
+ public static final int AL_FORMAT_51CHN_MULAW = 0x10023;
+ public static final int AL_FORMAT_61CHN_MULAW = 0x10024;
+ public static final int AL_FORMAT_71CHN_MULAW = 0x10025;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTMULAWMCFORMATS() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSOURCERADIUS.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSOURCERADIUS.java
new file mode 100644
index 00000000..c229cfc6
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSOURCERADIUS.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTSOURCERADIUS {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_SOURCE_RADIUS = 0x1031;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTSOURCERADIUS() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTATICBUFFER.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTATICBUFFER.java
new file mode 100644
index 00000000..cc50effb
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTATICBUFFER.java
@@ -0,0 +1,51 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALEXTSTATICBUFFER {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alBufferDataStatic`.
+ public static final MethodHandle MH_alBufferDataStatic = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferDataStatic", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ }
+ //endregion
+
+ public static void alBufferDataStatic(@CType("const ALuint") int buffer, @CType("ALenum") int format, @CType("ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int size, @CType("ALsizei") int freq) {
+ if (Handles.MH_alBufferDataStatic != null) {
+ try {
+ Handles.MH_alBufferDataStatic.invokeExact(buffer, format, data, size, freq);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferDataStatic", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferDataStatic"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTSTATICBUFFER() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTEREOANGLES.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTEREOANGLES.java
new file mode 100644
index 00000000..11d5e197
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSTEREOANGLES.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTSTEREOANGLES {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_STEREO_ANGLES = 0x1030;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTSTEREOANGLES() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSourceDistanceModel.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSourceDistanceModel.java
new file mode 100644
index 00000000..463bfee8
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTSourceDistanceModel.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTSourceDistanceModel {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_SOURCE_DISTANCE_MODEL = 0x200;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTSourceDistanceModel() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTVorbis.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTVorbis.java
new file mode 100644
index 00000000..91e04378
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEXTVorbis.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALEXTVorbis {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_VORBIS_EXT = 0x10003;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALEXTVorbis() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java
new file mode 100644
index 00000000..1bbed5df
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java
@@ -0,0 +1,54 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.upcall.*;
+import overrungl.util.*;
+
+@FunctionalInterface
+public interface ALEventProcSOFT extends Upcall {
+ /// The function descriptor.
+ FunctionDescriptor DESCRIPTOR = FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, Unmarshal.STR_LAYOUT, ValueLayout.ADDRESS);
+ /// The method handle of the target method.
+ MethodHandle HANDLE = Upcall.findTarget(ALEventProcSOFT.class, "invoke", DESCRIPTOR);
+
+ ///The target method of the upcall.
+ void invoke(@CType("ALenum") int eventType, @CType("ALuint") int object, @CType("ALuint") int param, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message, @CType("void*") java.lang.foreign.MemorySegment userParam);
+
+ @Override
+ default MemorySegment stub(Arena arena) { return Linker.nativeLinker().upcallStub(HANDLE.bindTo(this), DESCRIPTOR, arena); }
+
+ ///A static invoker of the target method.
+ ///@param stub the upcall stub
+ static void invoke(MemorySegment stub, @CType("ALenum") int eventType, @CType("ALuint") int object, @CType("ALuint") int param, @CType("ALsizei") int length, @CType("const ALchar*") java.lang.foreign.MemorySegment message, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ try { HANDLE.invokeExact(stub, eventType, object, param, length, message, userParam); }
+ catch (Throwable e) { throw new RuntimeException("error in ALEventProcSOFT::invoke (static invoker)", e); }
+ }
+
+ /// A wrapper for the target method.
+ /// @param stub the upcall stub
+ /// @return an instance that wraps the static invoker
+ static ALEventProcSOFT wrap(MemorySegment stub) {
+ return (eventType, object, param, length, message, userParam) -> { try (var __overrungl_stack = MemoryStack.pushLocal()) {
+ invoke(stub, eventType, object, param, length, Marshal.marshal(__overrungl_stack, message), userParam);
+ } };
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALFoldbackCallback.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALFoldbackCallback.java
new file mode 100644
index 00000000..8f16c514
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALFoldbackCallback.java
@@ -0,0 +1,53 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.upcall.*;
+import overrungl.util.*;
+
+@FunctionalInterface
+public interface ALFoldbackCallback extends Upcall {
+ /// The function descriptor.
+ FunctionDescriptor DESCRIPTOR = FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT);
+ /// The method handle of the target method.
+ MethodHandle HANDLE = Upcall.findTarget(ALFoldbackCallback.class, "invoke", DESCRIPTOR);
+
+ ///The target method of the upcall.
+ void invoke(@CType("ALenum") int mode, @CType("ALsizei") int count);
+
+ @Override
+ default MemorySegment stub(Arena arena) { return Linker.nativeLinker().upcallStub(HANDLE.bindTo(this), DESCRIPTOR, arena); }
+
+ ///A static invoker of the target method.
+ ///@param stub the upcall stub
+ static void invoke(MemorySegment stub, @CType("ALenum") int mode, @CType("ALsizei") int count) {
+ try { HANDLE.invokeExact(stub, mode, count); }
+ catch (Throwable e) { throw new RuntimeException("error in ALFoldbackCallback::invoke (static invoker)", e); }
+ }
+
+ /// A wrapper for the target method.
+ /// @param stub the upcall stub
+ /// @return an instance that wraps the static invoker
+ static ALFoldbackCallback wrap(MemorySegment stub) {
+ return (mode, count) ->
+ invoke(stub, mode, count);
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIIMAADPCMFormat.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIIMAADPCMFormat.java
new file mode 100644
index 00000000..18ebbb4f
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIIMAADPCMFormat.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALLOKIIMAADPCMFormat {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_IMA_ADPCM_MONO16_EXT = 0x10000;
+ public static final int AL_FORMAT_IMA_ADPCM_STEREO16_EXT = 0x10001;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALLOKIIMAADPCMFormat() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIQuadriphonic.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIQuadriphonic.java
new file mode 100644
index 00000000..e6f32e56
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIQuadriphonic.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALLOKIQuadriphonic {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_QUAD8_LOKI = 0x10004;
+ public static final int AL_FORMAT_QUAD16_LOKI = 0x10005;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALLOKIQuadriphonic() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIWAVEFormat.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIWAVEFormat.java
new file mode 100644
index 00000000..a216e7f2
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALLOKIWAVEFormat.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALLOKIWAVEFormat {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_WAVE_EXT = 0x10002;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALLOKIWAVEFormat() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatEx.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatEx.java
new file mode 100644
index 00000000..e8819516
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatEx.java
@@ -0,0 +1,35 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTBformatEx {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_AMBISONIC_LAYOUT_SOFT = 0x1997;
+ public static final int AL_AMBISONIC_SCALING_SOFT = 0x1998;
+ public static final int AL_FUMA_SOFT = 0x0000;
+ public static final int AL_ACN_SOFT = 0x0001;
+ public static final int AL_SN3D_SOFT = 0x0001;
+ public static final int AL_N3D_SOFT = 0x0002;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTBformatEx() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatHoa.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatHoa.java
new file mode 100644
index 00000000..29a10870
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBformatHoa.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTBformatHoa {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_UNPACK_AMBISONIC_ORDER_SOFT = 0x199D;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTBformatHoa() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBlockAlignment.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBlockAlignment.java
new file mode 100644
index 00000000..047be0e4
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBlockAlignment.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTBlockAlignment {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_UNPACK_BLOCK_ALIGNMENT_SOFT = 0x200C;
+ public static final int AL_PACK_BLOCK_ALIGNMENT_SOFT = 0x200D;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTBlockAlignment() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSamples.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSamples.java
new file mode 100644
index 00000000..e65443c7
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSamples.java
@@ -0,0 +1,123 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTBufferSamples {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_MONO_SOFT = 0x1500;
+ public static final int AL_STEREO_SOFT = 0x1501;
+ public static final int AL_REAR_SOFT = 0x1502;
+ public static final int AL_QUAD_SOFT = 0x1503;
+ public static final int AL_5POINT1_SOFT = 0x1504;
+ public static final int AL_6POINT1_SOFT = 0x1505;
+ public static final int AL_7POINT1_SOFT = 0x1506;
+ public static final int AL_BYTE_SOFT = 0x1400;
+ public static final int AL_UNSIGNED_BYTE_SOFT = 0x1401;
+ public static final int AL_SHORT_SOFT = 0x1402;
+ public static final int AL_UNSIGNED_SHORT_SOFT = 0x1403;
+ public static final int AL_INT_SOFT = 0x1404;
+ public static final int AL_UNSIGNED_INT_SOFT = 0x1405;
+ public static final int AL_FLOAT_SOFT = 0x1406;
+ public static final int AL_DOUBLE_SOFT = 0x1407;
+ public static final int AL_BYTE3_SOFT = 0x1408;
+ public static final int AL_UNSIGNED_BYTE3_SOFT = 0x1409;
+ public static final int AL_MONO8_SOFT = 0x1100;
+ public static final int AL_MONO16_SOFT = 0x1101;
+ public static final int AL_MONO32F_SOFT = 0x10010;
+ public static final int AL_STEREO8_SOFT = 0x1102;
+ public static final int AL_STEREO16_SOFT = 0x1103;
+ public static final int AL_STEREO32F_SOFT = 0x10011;
+ public static final int AL_QUAD8_SOFT = 0x1204;
+ public static final int AL_QUAD16_SOFT = 0x1205;
+ public static final int AL_QUAD32F_SOFT = 0x1206;
+ public static final int AL_REAR8_SOFT = 0x1207;
+ public static final int AL_REAR16_SOFT = 0x1208;
+ public static final int AL_REAR32F_SOFT = 0x1209;
+ public static final int AL_5POINT1_8_SOFT = 0x120A;
+ public static final int AL_5POINT1_16_SOFT = 0x120B;
+ public static final int AL_5POINT1_32F_SOFT = 0x120C;
+ public static final int AL_6POINT1_8_SOFT = 0x120D;
+ public static final int AL_6POINT1_16_SOFT = 0x120E;
+ public static final int AL_6POINT1_32F_SOFT = 0x120F;
+ public static final int AL_7POINT1_8_SOFT = 0x1210;
+ public static final int AL_7POINT1_16_SOFT = 0x1211;
+ public static final int AL_7POINT1_32F_SOFT = 0x1212;
+ public static final int AL_INTERNAL_FORMAT_SOFT = 0x2008;
+ public static final int AL_BYTE_LENGTH_SOFT = 0x2009;
+ public static final int AL_SAMPLE_LENGTH_SOFT = 0x200A;
+ public static final int AL_SEC_LENGTH_SOFT = 0x200B;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alBufferSamplesSOFT`.
+ public static final MethodHandle MH_alBufferSamplesSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferSamplesSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alBufferSubSamplesSOFT`.
+ public static final MethodHandle MH_alBufferSubSamplesSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferSubSamplesSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferSamplesSOFT`.
+ public static final MethodHandle MH_alGetBufferSamplesSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferSamplesSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alIsBufferFormatSupportedSOFT`.
+ public static final MethodHandle MH_alIsBufferFormatSupportedSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alIsBufferFormatSupportedSOFT", FunctionDescriptor.of(ValueLayout.JAVA_BOOLEAN, ValueLayout.JAVA_INT));
+ }
+ //endregion
+
+ public static void alBufferSamplesSOFT(@CType("ALuint") int buffer, @CType("ALuint") int samplerate, @CType("ALenum") int internalformat, @CType("ALsizei") int samples, @CType("ALenum") int channels, @CType("ALenum") int type, @CType("const ALvoid *") java.lang.foreign.MemorySegment data) {
+ if (Handles.MH_alBufferSamplesSOFT != null) {
+ try {
+ Handles.MH_alBufferSamplesSOFT.invokeExact(buffer, samplerate, internalformat, samples, channels, type, data);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferSamplesSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferSamplesSOFT"); }
+ }
+
+ public static void alBufferSubSamplesSOFT(@CType("ALuint") int buffer, @CType("ALsizei") int offset, @CType("ALsizei") int samples, @CType("ALenum") int channels, @CType("ALenum") int type, @CType("const ALvoid *") java.lang.foreign.MemorySegment data) {
+ if (Handles.MH_alBufferSubSamplesSOFT != null) {
+ try {
+ Handles.MH_alBufferSubSamplesSOFT.invokeExact(buffer, offset, samples, channels, type, data);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferSubSamplesSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferSubSamplesSOFT"); }
+ }
+
+ public static void alGetBufferSamplesSOFT(@CType("ALuint") int buffer, @CType("ALsizei") int offset, @CType("ALsizei") int samples, @CType("ALenum") int channels, @CType("ALenum") int type, @CType("ALvoid *") java.lang.foreign.MemorySegment data) {
+ if (Handles.MH_alGetBufferSamplesSOFT != null) {
+ try {
+ Handles.MH_alGetBufferSamplesSOFT.invokeExact(buffer, offset, samples, channels, type, data);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferSamplesSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferSamplesSOFT"); }
+ }
+
+ public static @CType("ALboolean") boolean alIsBufferFormatSupportedSOFT(@CType("ALenum") int format) {
+ if (Handles.MH_alIsBufferFormatSupportedSOFT != null) {
+ try {
+ return (boolean) Handles.MH_alIsBufferFormatSupportedSOFT.invokeExact(format);
+ } catch (Throwable e) { throw new RuntimeException("error in alIsBufferFormatSupportedSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alIsBufferFormatSupportedSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTBufferSamples() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSubData.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSubData.java
new file mode 100644
index 00000000..d3cd683d
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTBufferSubData.java
@@ -0,0 +1,53 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTBufferSubData {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_BYTE_RW_OFFSETS_SOFT = 0x1031;
+ public static final int AL_SAMPLE_RW_OFFSETS_SOFT = 0x1032;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alBufferSubDataSOFT`.
+ public static final MethodHandle MH_alBufferSubDataSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferSubDataSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ }
+ //endregion
+
+ public static void alBufferSubDataSOFT(@CType("ALuint") int buffer, @CType("ALenum") int format, @CType("const ALvoid *") java.lang.foreign.MemorySegment data, @CType("ALsizei") int offset, @CType("ALsizei") int length) {
+ if (Handles.MH_alBufferSubDataSOFT != null) {
+ try {
+ Handles.MH_alBufferSubDataSOFT.invokeExact(buffer, format, data, offset, length);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferSubDataSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferSubDataSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTBufferSubData() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTCallbackBuffer.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTCallbackBuffer.java
new file mode 100644
index 00000000..00baf07e
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTCallbackBuffer.java
@@ -0,0 +1,83 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTCallbackBuffer {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_BUFFER_CALLBACK_FUNCTION_SOFT = 0x19A0;
+ public static final int AL_BUFFER_CALLBACK_USER_PARAM_SOFT = 0x19A1;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alBufferCallbackSOFT`.
+ public static final MethodHandle MH_alBufferCallbackSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alBufferCallbackSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferPtrSOFT`.
+ public static final MethodHandle MH_alGetBufferPtrSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferPtrSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBuffer3PtrSOFT`.
+ public static final MethodHandle MH_alGetBuffer3PtrSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBuffer3PtrSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetBufferPtrvSOFT`.
+ public static final MethodHandle MH_alGetBufferPtrvSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetBufferPtrvSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alBufferCallbackSOFT(@CType("ALuint") int buffer, @CType("ALenum") int format, @CType("ALsizei") int freq, @CType("ALBUFFERCALLBACKTYPESOFT") java.lang.foreign.MemorySegment callback, @CType("ALvoid *") java.lang.foreign.MemorySegment userptr) {
+ if (Handles.MH_alBufferCallbackSOFT != null) {
+ try {
+ Handles.MH_alBufferCallbackSOFT.invokeExact(buffer, format, freq, callback, userptr);
+ } catch (Throwable e) { throw new RuntimeException("error in alBufferCallbackSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alBufferCallbackSOFT"); }
+ }
+
+ public static void alGetBufferPtrSOFT(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr) {
+ if (Handles.MH_alGetBufferPtrSOFT != null) {
+ try {
+ Handles.MH_alGetBufferPtrSOFT.invokeExact(buffer, param, ptr);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferPtrSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferPtrSOFT"); }
+ }
+
+ public static void alGetBuffer3PtrSOFT(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr0, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr1, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr2) {
+ if (Handles.MH_alGetBuffer3PtrSOFT != null) {
+ try {
+ Handles.MH_alGetBuffer3PtrSOFT.invokeExact(buffer, param, ptr0, ptr1, ptr2);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBuffer3PtrSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBuffer3PtrSOFT"); }
+ }
+
+ public static void alGetBufferPtrvSOFT(@CType("ALuint") int buffer, @CType("ALenum") int param, @CType("ALvoid **") java.lang.foreign.MemorySegment ptr) {
+ if (Handles.MH_alGetBufferPtrvSOFT != null) {
+ try {
+ Handles.MH_alGetBufferPtrvSOFT.invokeExact(buffer, param, ptr);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetBufferPtrvSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetBufferPtrvSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTCallbackBuffer() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDeferredUpdates.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDeferredUpdates.java
new file mode 100644
index 00000000..48baa428
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDeferredUpdates.java
@@ -0,0 +1,62 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTDeferredUpdates {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_DEFERRED_UPDATES_SOFT = 0xC002;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alDeferUpdatesSOFT`.
+ public static final MethodHandle MH_alDeferUpdatesSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alDeferUpdatesSOFT", FunctionDescriptor.ofVoid());
+ /// The method handle of `alProcessUpdatesSOFT`.
+ public static final MethodHandle MH_alProcessUpdatesSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alProcessUpdatesSOFT", FunctionDescriptor.ofVoid());
+ }
+ //endregion
+
+ public static void alDeferUpdatesSOFT() {
+ if (Handles.MH_alDeferUpdatesSOFT != null) {
+ try {
+ Handles.MH_alDeferUpdatesSOFT.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alDeferUpdatesSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alDeferUpdatesSOFT"); }
+ }
+
+ public static void alProcessUpdatesSOFT() {
+ if (Handles.MH_alProcessUpdatesSOFT != null) {
+ try {
+ Handles.MH_alProcessUpdatesSOFT.invokeExact();
+ } catch (Throwable e) { throw new RuntimeException("error in alProcessUpdatesSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alProcessUpdatesSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTDeferredUpdates() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannels.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannels.java
new file mode 100644
index 00000000..960aadf5
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannels.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTDirectChannels {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_DIRECT_CHANNELS_SOFT = 0x1033;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTDirectChannels() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannelsRemix.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannelsRemix.java
new file mode 100644
index 00000000..9f0d41a9
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTDirectChannelsRemix.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTDirectChannelsRemix {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_DROP_UNMATCHED_SOFT = 0x0001;
+ public static final int AL_REMIX_UNMATCHED_SOFT = 0x0002;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTDirectChannelsRemix() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEffectTarget.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEffectTarget.java
new file mode 100644
index 00000000..2b88b95d
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEffectTarget.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTEffectTarget {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_EFFECTSLOT_TARGET_SOFT = 0x199C;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTEffectTarget() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEvents.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEvents.java
new file mode 100644
index 00000000..d90500c6
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTEvents.java
@@ -0,0 +1,86 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTEvents {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_EVENT_CALLBACK_FUNCTION_SOFT = 0x19A2;
+ public static final int AL_EVENT_CALLBACK_USER_PARAM_SOFT = 0x19A3;
+ public static final int AL_EVENT_TYPE_BUFFER_COMPLETED_SOFT = 0x19A4;
+ public static final int AL_EVENT_TYPE_SOURCE_STATE_CHANGED_SOFT = 0x19A5;
+ public static final int AL_EVENT_TYPE_DISCONNECTED_SOFT = 0x19A6;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alEventControlSOFT`.
+ public static final MethodHandle MH_alEventControlSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEventControlSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_BOOLEAN));
+ /// The method handle of `alEventCallbackSOFT`.
+ public static final MethodHandle MH_alEventCallbackSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alEventCallbackSOFT", FunctionDescriptor.ofVoid(ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetPointerSOFT`.
+ public static final MethodHandle MH_alGetPointerSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointerSOFT", FunctionDescriptor.of(ValueLayout.ADDRESS, ValueLayout.JAVA_INT));
+ /// The method handle of `alGetPointervSOFT`.
+ public static final MethodHandle MH_alGetPointervSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetPointervSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alEventControlSOFT(@CType("ALsizei") int count, @CType("const ALenum *") java.lang.foreign.MemorySegment types, @CType("ALboolean") boolean enable) {
+ if (Handles.MH_alEventControlSOFT != null) {
+ try {
+ Handles.MH_alEventControlSOFT.invokeExact(count, types, enable);
+ } catch (Throwable e) { throw new RuntimeException("error in alEventControlSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEventControlSOFT"); }
+ }
+
+ public static void alEventCallbackSOFT(@CType("ALEVENTPROCSOFT") java.lang.foreign.MemorySegment callback, @CType("void*") java.lang.foreign.MemorySegment userParam) {
+ if (Handles.MH_alEventCallbackSOFT != null) {
+ try {
+ Handles.MH_alEventCallbackSOFT.invokeExact(callback, userParam);
+ } catch (Throwable e) { throw new RuntimeException("error in alEventCallbackSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alEventCallbackSOFT"); }
+ }
+
+ public static @CType("void*") java.lang.foreign.MemorySegment alGetPointerSOFT(@CType("ALenum") int pname) {
+ if (Handles.MH_alGetPointerSOFT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetPointerSOFT.invokeExact(pname);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointerSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointerSOFT"); }
+ }
+
+ public static void alGetPointervSOFT(@CType("ALenum") int pname, @CType("void**") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetPointervSOFT != null) {
+ try {
+ Handles.MH_alGetPointervSOFT.invokeExact(pname, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetPointervSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetPointervSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTEvents() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTGainClampEx.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTGainClampEx.java
new file mode 100644
index 00000000..f456f320
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTGainClampEx.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTGainClampEx {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_GAIN_LIMIT_SOFT = 0x200E;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTGainClampEx() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTLoopPoints.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTLoopPoints.java
new file mode 100644
index 00000000..a55c69e2
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTLoopPoints.java
@@ -0,0 +1,30 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTLoopPoints {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_LOOP_POINTS_SOFT = 0x2015;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTLoopPoints() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTMSADPCM.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTMSADPCM.java
new file mode 100644
index 00000000..42a85523
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTMSADPCM.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTMSADPCM {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_MONO_MSADPCM_SOFT = 0x1302;
+ public static final int AL_FORMAT_STEREO_MSADPCM_SOFT = 0x1303;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTMSADPCM() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceLatency.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceLatency.java
new file mode 100644
index 00000000..0f33c74f
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceLatency.java
@@ -0,0 +1,163 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTSourceLatency {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_SAMPLE_OFFSET_LATENCY_SOFT = 0x1200;
+ public static final int AL_SEC_OFFSET_LATENCY_SOFT = 0x1201;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alSourcedSOFT`.
+ public static final MethodHandle MH_alSourcedSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcedSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_DOUBLE));
+ /// The method handle of `alSource3dSOFT`.
+ public static final MethodHandle MH_alSource3dSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSource3dSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_DOUBLE, ValueLayout.JAVA_DOUBLE, ValueLayout.JAVA_DOUBLE));
+ /// The method handle of `alSourcedvSOFT`.
+ public static final MethodHandle MH_alSourcedvSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcedvSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcedSOFT`.
+ public static final MethodHandle MH_alGetSourcedSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcedSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3dSOFT`.
+ public static final MethodHandle MH_alGetSource3dSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSource3dSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcedvSOFT`.
+ public static final MethodHandle MH_alGetSourcedvSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcedvSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alSourcei64SOFT`.
+ public static final MethodHandle MH_alSourcei64SOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcei64SOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_LONG));
+ /// The method handle of `alSource3i64SOFT`.
+ public static final MethodHandle MH_alSource3i64SOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSource3i64SOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.JAVA_LONG, ValueLayout.JAVA_LONG, ValueLayout.JAVA_LONG));
+ /// The method handle of `alSourcei64vSOFT`.
+ public static final MethodHandle MH_alSourcei64vSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcei64vSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcei64SOFT`.
+ public static final MethodHandle MH_alGetSourcei64SOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcei64SOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSource3i64SOFT`.
+ public static final MethodHandle MH_alGetSource3i64SOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSource3i64SOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.ADDRESS, ValueLayout.ADDRESS));
+ /// The method handle of `alGetSourcei64vSOFT`.
+ public static final MethodHandle MH_alGetSourcei64vSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetSourcei64vSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_INT, ValueLayout.ADDRESS));
+ }
+ //endregion
+
+ public static void alSourcedSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble") double value) {
+ if (Handles.MH_alSourcedSOFT != null) {
+ try {
+ Handles.MH_alSourcedSOFT.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcedSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcedSOFT"); }
+ }
+
+ public static void alSource3dSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble") double value1, @CType("ALdouble") double value2, @CType("ALdouble") double value3) {
+ if (Handles.MH_alSource3dSOFT != null) {
+ try {
+ Handles.MH_alSource3dSOFT.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3dSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSource3dSOFT"); }
+ }
+
+ public static void alSourcedvSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALdouble *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alSourcedvSOFT != null) {
+ try {
+ Handles.MH_alSourcedvSOFT.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcedvSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcedvSOFT"); }
+ }
+
+ public static void alGetSourcedSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetSourcedSOFT != null) {
+ try {
+ Handles.MH_alGetSourcedSOFT.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcedSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcedSOFT"); }
+ }
+
+ public static void alGetSource3dSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment value1, @CType("ALdouble *") java.lang.foreign.MemorySegment value2, @CType("ALdouble *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetSource3dSOFT != null) {
+ try {
+ Handles.MH_alGetSource3dSOFT.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3dSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSource3dSOFT"); }
+ }
+
+ public static void alGetSourcedvSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALdouble *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetSourcedvSOFT != null) {
+ try {
+ Handles.MH_alGetSourcedvSOFT.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcedvSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcedvSOFT"); }
+ }
+
+ public static void alSourcei64SOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT") long value) {
+ if (Handles.MH_alSourcei64SOFT != null) {
+ try {
+ Handles.MH_alSourcei64SOFT.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcei64SOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcei64SOFT"); }
+ }
+
+ public static void alSource3i64SOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT") long value1, @CType("ALint64SOFT") long value2, @CType("ALint64SOFT") long value3) {
+ if (Handles.MH_alSource3i64SOFT != null) {
+ try {
+ Handles.MH_alSource3i64SOFT.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alSource3i64SOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSource3i64SOFT"); }
+ }
+
+ public static void alSourcei64vSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("const ALint64SOFT *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alSourcei64vSOFT != null) {
+ try {
+ Handles.MH_alSourcei64vSOFT.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcei64vSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcei64vSOFT"); }
+ }
+
+ public static void alGetSourcei64SOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value) {
+ if (Handles.MH_alGetSourcei64SOFT != null) {
+ try {
+ Handles.MH_alGetSourcei64SOFT.invokeExact(source, param, value);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcei64SOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcei64SOFT"); }
+ }
+
+ public static void alGetSource3i64SOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value1, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value2, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment value3) {
+ if (Handles.MH_alGetSource3i64SOFT != null) {
+ try {
+ Handles.MH_alGetSource3i64SOFT.invokeExact(source, param, value1, value2, value3);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSource3i64SOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSource3i64SOFT"); }
+ }
+
+ public static void alGetSourcei64vSOFT(@CType("ALuint") int source, @CType("ALenum") int param, @CType("ALint64SOFT *") java.lang.foreign.MemorySegment values) {
+ if (Handles.MH_alGetSourcei64vSOFT != null) {
+ try {
+ Handles.MH_alGetSourcei64vSOFT.invokeExact(source, param, values);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetSourcei64vSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetSourcei64vSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTSourceLatency() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceResampler.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceResampler.java
new file mode 100644
index 00000000..32264f6b
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceResampler.java
@@ -0,0 +1,55 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTSourceResampler {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_NUM_RESAMPLERS_SOFT = 0x1210;
+ public static final int AL_DEFAULT_RESAMPLER_SOFT = 0x1211;
+ public static final int AL_SOURCE_RESAMPLER_SOFT = 0x1212;
+ public static final int AL_RESAMPLER_NAME_SOFT = 0x1213;
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alGetStringiSOFT`.
+ public static final MethodHandle MH_alGetStringiSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alGetStringiSOFT", FunctionDescriptor.of(Unmarshal.STR_LAYOUT, ValueLayout.JAVA_INT, ValueLayout.JAVA_INT));
+ }
+ //endregion
+
+ public static @CType("const ALchar*") java.lang.foreign.MemorySegment alGetStringiSOFT(@CType("ALenum") int pname, @CType("ALsizei") int index) {
+ if (Handles.MH_alGetStringiSOFT != null) {
+ try {
+ return (java.lang.foreign.MemorySegment) Handles.MH_alGetStringiSOFT.invokeExact(pname, index);
+ } catch (Throwable e) { throw new RuntimeException("error in alGetStringiSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alGetStringiSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTSourceResampler() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceSpatialize.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceSpatialize.java
new file mode 100644
index 00000000..f05d5656
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceSpatialize.java
@@ -0,0 +1,31 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTSourceSpatialize {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_SOURCE_SPATIALIZE_SOFT = 0x1214;
+ public static final int AL_AUTO_SOFT = 0x0002;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTSourceSpatialize() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceStartDelay.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceStartDelay.java
new file mode 100644
index 00000000..87878630
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTSourceStartDelay.java
@@ -0,0 +1,61 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+import java.lang.foreign.*;
+import java.lang.invoke.*;
+import overrungl.annotation.*;
+import overrungl.internal.*;
+import overrungl.util.*;
+public final class ALSOFTSourceStartDelay {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ //endregion
+ //region Method handles
+ /// Method handles.
+ public static final class Handles {
+ private Handles() { }
+ /// The method handle of `alSourcePlayAtTimeSOFT`.
+ public static final MethodHandle MH_alSourcePlayAtTimeSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePlayAtTimeSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.JAVA_LONG));
+ /// The method handle of `alSourcePlayAtTimevSOFT`.
+ public static final MethodHandle MH_alSourcePlayAtTimevSOFT = RuntimeHelper.downcallOrNull(ALInternal.lookup(), "alSourcePlayAtTimevSOFT", FunctionDescriptor.ofVoid(ValueLayout.JAVA_INT, ValueLayout.ADDRESS, ValueLayout.JAVA_LONG));
+ }
+ //endregion
+
+ public static void alSourcePlayAtTimeSOFT(@CType("ALuint") int source, @CType("ALint64SOFT") long start_time) {
+ if (Handles.MH_alSourcePlayAtTimeSOFT != null) {
+ try {
+ Handles.MH_alSourcePlayAtTimeSOFT.invokeExact(source, start_time);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayAtTimeSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePlayAtTimeSOFT"); }
+ }
+
+ public static void alSourcePlayAtTimevSOFT(@CType("ALsizei") int n, @CType("const ALuint *") java.lang.foreign.MemorySegment sources, @CType("ALint64SOFT") long start_time) {
+ if (Handles.MH_alSourcePlayAtTimevSOFT != null) {
+ try {
+ Handles.MH_alSourcePlayAtTimevSOFT.invokeExact(n, sources, start_time);
+ } catch (Throwable e) { throw new RuntimeException("error in alSourcePlayAtTimevSOFT", e); }
+ } else { throw new SymbolNotFoundError("Symbol not found: alSourcePlayAtTimevSOFT"); }
+ }
+
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTSourceStartDelay() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJ.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJ.java
new file mode 100644
index 00000000..70972d91
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJ.java
@@ -0,0 +1,42 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTUHJ {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_UHJ2CHN8_SOFT = 0x19A2;
+ public static final int AL_FORMAT_UHJ2CHN16_SOFT = 0x19A3;
+ public static final int AL_FORMAT_UHJ2CHN_FLOAT32_SOFT = 0x19A4;
+ public static final int AL_FORMAT_UHJ3CHN8_SOFT = 0x19A5;
+ public static final int AL_FORMAT_UHJ3CHN16_SOFT = 0x19A6;
+ public static final int AL_FORMAT_UHJ3CHN_FLOAT32_SOFT = 0x19A7;
+ public static final int AL_FORMAT_UHJ4CHN8_SOFT = 0x19A8;
+ public static final int AL_FORMAT_UHJ4CHN16_SOFT = 0x19A9;
+ public static final int AL_FORMAT_UHJ4CHN_FLOAT32_SOFT = 0x19AA;
+ public static final int AL_STEREO_MODE_SOFT = 0x19B0;
+ public static final int AL_NORMAL_SOFT = 0x0000;
+ public static final int AL_SUPER_STEREO_SOFT = 0x0001;
+ public static final int AL_SUPER_STEREO_WIDTH_SOFT = 0x19B1;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTUHJ() {
+ }
+}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJEx.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJEx.java
new file mode 100644
index 00000000..3566b7e5
--- /dev/null
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALSOFTUHJEx.java
@@ -0,0 +1,37 @@
+/*
+ * MIT License
+ *
+ * Copyright (c) 2022-2025 Overrun Organization
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all
+ * copies or substantial portions of the Software.
+ */
+
+// This file is auto-generated. DO NOT EDIT!
+package overrungl.openal;
+public final class ALSOFTUHJEx {
+ //region ---[BEGIN GENERATOR BEGIN]---
+ //@formatter:off
+ //region Fields
+ public static final int AL_FORMAT_UHJ2CHN_MULAW_SOFT = 0x19B3;
+ public static final int AL_FORMAT_UHJ2CHN_ALAW_SOFT = 0x19B4;
+ public static final int AL_FORMAT_UHJ2CHN_IMA4_SOFT = 0x19B5;
+ public static final int AL_FORMAT_UHJ2CHN_MSADPCM_SOFT = 0x19B6;
+ public static final int AL_FORMAT_UHJ3CHN_MULAW_SOFT = 0x19B7;
+ public static final int AL_FORMAT_UHJ3CHN_ALAW_SOFT = 0x19B8;
+ public static final int AL_FORMAT_UHJ4CHN_MULAW_SOFT = 0x19B9;
+ public static final int AL_FORMAT_UHJ4CHN_ALAW_SOFT = 0x19BA;
+ //endregion
+ //@formatter:on
+ //endregion ---[END GENERATOR END]---
+
+ private ALSOFTUHJEx() {
+ }
+}
From 08babcdd393fade01322408de463512fc6065679 Mon Sep 17 00:00:00 2001
From: squid233 <60126026+squid233@users.noreply.github.com>
Date: Tue, 7 Jan 2025 17:07:00 +0800
Subject: [PATCH 11/11] feat(api): [openal] fix upcall
---
.../src/main/kotlin/overrungl/gen/Upcall.kt | 30 ++++++++++++-------
.../openal/ALCEventProcTypeSOFT.java | 5 ++--
.../java/overrungl/openal/ALDebugProcEXT.java | 5 ++--
.../overrungl/openal/ALEventProcSOFT.java | 5 ++--
4 files changed, 26 insertions(+), 19 deletions(-)
diff --git a/generators/src/main/kotlin/overrungl/gen/Upcall.kt b/generators/src/main/kotlin/overrungl/gen/Upcall.kt
index d74a0e9b..f4f4a9c9 100644
--- a/generators/src/main/kotlin/overrungl/gen/Upcall.kt
+++ b/generators/src/main/kotlin/overrungl/gen/Upcall.kt
@@ -72,7 +72,8 @@ class Upcall(
fun write() {
val targetMethodNotNull = targetMethod!!
- val allocatorRequirement = targetMethodNotNull.parameters
+ val allocatorRequirement = if (interfaceMethod == null) AllocatorRequirement.NO
+ else targetMethodNotNull.parameters
.map { it.type.allocatorRequirement }
.reduceOrNull(AllocatorRequirement::stricter)
?: AllocatorRequirement.NO
@@ -292,16 +293,25 @@ class Upcall(
if (allocatorRequirement == AllocatorRequirement.STACK && !returnVoid) {
sb.append("return ")
}
- targetMethodNotNull.returnType.processor.unmarshal(ProcessorContext(allocatorName = allocatorName, sb) {
- it.append("invoke(stub")
- targetMethodNotNull.parameters.forEachIndexed { index, p ->
- it.append(", ")
- p.type.processor.marshal(ProcessorContext(allocatorName = allocatorName, it) { b ->
- b.append(p.name)
- })
+ if (interfaceMethod != null) {
+ targetMethodNotNull.returnType.processor.unmarshal(ProcessorContext(allocatorName = allocatorName, sb) {
+ it.append("invoke(stub")
+ targetMethodNotNull.parameters.forEach { p ->
+ it.append(", ")
+ p.type.processor.marshal(ProcessorContext(allocatorName = allocatorName, it) { b ->
+ b.append(p.name)
+ })
+ }
+ it.append(")")
+ })
+ } else {
+ sb.append("invoke(stub")
+ targetMethodNotNull.parameters.forEach { p ->
+ sb.append(", ")
+ sb.append(p.name)
}
- it.append(")")
- })
+ sb.append(")")
+ }
sb.appendLine(";")
if (allocatorRequirement == AllocatorRequirement.STACK) {
sb.appendLine(" } };")
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java
index f0d49d58..7ca29432 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALCEventProcTypeSOFT.java
@@ -47,8 +47,7 @@ static void invoke(MemorySegment stub, @CType("ALCenum") int eventType, @CType("
/// @param stub the upcall stub
/// @return an instance that wraps the static invoker
static ALCEventProcTypeSOFT wrap(MemorySegment stub) {
- return (eventType, deviceType, device, length, message, userParam) -> { try (var __overrungl_stack = MemoryStack.pushLocal()) {
- invoke(stub, eventType, deviceType, device, length, Marshal.marshal(__overrungl_stack, message), userParam);
- } };
+ return (eventType, deviceType, device, length, message, userParam) ->
+ invoke(stub, eventType, deviceType, device, length, message, userParam);
}
}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java
index b1ba18bf..31c02dbc 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALDebugProcEXT.java
@@ -47,8 +47,7 @@ static void invoke(MemorySegment stub, @CType("ALenum") int source, @CType("ALen
/// @param stub the upcall stub
/// @return an instance that wraps the static invoker
static ALDebugProcEXT wrap(MemorySegment stub) {
- return (source, type, id, severity, length, message, userParam) -> { try (var __overrungl_stack = MemoryStack.pushLocal()) {
- invoke(stub, source, type, id, severity, length, Marshal.marshal(__overrungl_stack, message), userParam);
- } };
+ return (source, type, id, severity, length, message, userParam) ->
+ invoke(stub, source, type, id, severity, length, message, userParam);
}
}
diff --git a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java
index 1bbed5df..685f9728 100644
--- a/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java
+++ b/modules/overrungl.openal/src/main/java/overrungl/openal/ALEventProcSOFT.java
@@ -47,8 +47,7 @@ static void invoke(MemorySegment stub, @CType("ALenum") int eventType, @CType("A
/// @param stub the upcall stub
/// @return an instance that wraps the static invoker
static ALEventProcSOFT wrap(MemorySegment stub) {
- return (eventType, object, param, length, message, userParam) -> { try (var __overrungl_stack = MemoryStack.pushLocal()) {
- invoke(stub, eventType, object, param, length, Marshal.marshal(__overrungl_stack, message), userParam);
- } };
+ return (eventType, object, param, length, message, userParam) ->
+ invoke(stub, eventType, object, param, length, message, userParam);
}
}