// -------- ALC_ENUMERATION_EXT -------- /// <summary> /// Checks to see that the ALC_ENUMERATION_EXT extension is present. This will always be available in 1.1 devices or later. /// </summary> /// <param name="device">The device to check the extension is present for.</param> /// <returns>If the ALC_ENUMERATION_EXT extension was present.</returns> public static bool IsEnumerationExtensionPresent(ALDevice device) { return(IsExtensionPresent(device, "ALC_ENUMERATION_EXT")); }
public static extern string GetString(ALDevice device, GetEnumerationString param);
/// <summary>This function returns integers related to the context.</summary> /// <param name="device">A pointer to the device to be queried.</param> /// <param name="param">An attribute to be retrieved: ALC_MAJOR_VERSION, ALC_MINOR_VERSION, ALC_ATTRIBUTES_SIZE, ALC_ALL_ATTRIBUTES.</param> /// <returns>The value returned.</returns> public static int GetInteger(ALDevice device, AlcGetInteger param) { GetInteger(device, param, 1, out int data); return(data); }
// -------- ALC_EXT_CAPTURE -------- /// <summary> /// Checks to see that the ALC_EXT_CAPTURE extension is present. This will always be available in 1.1 devices or later. /// </summary> /// <param name="device">The device to check the extension is present for.</param> /// <returns>If the ALC_EXT_CAPTURE extension was present.</returns> public static bool IsCaptureExtensionPresent(ALDevice device) { return(IsExtensionPresent(device, "ALC_EXT_CAPTURE")); }
public static extern AlcError GetError([In] ALDevice device);
// ALC_API void ALC_APIENTRY alcGetIntegerv( ALCdevice *device, ALCenum param, ALCsizei size, ALCint *buffer ); /// <summary>This function returns integers related to the context.</summary> /// <param name="device">A pointer to the device to be queried.</param> /// <param name="param">An attribute to be retrieved: ALC_MAJOR_VERSION, ALC_MINOR_VERSION, ALC_ATTRIBUTES_SIZE, ALC_ALL_ATTRIBUTES.</param> /// <param name="data">A pointer to the buffer to be returned.</param> public static void GetInteger(ALDevice device, AlcGetInteger param, out int data) { GetInteger(device, param, 1, out data); }
// ALC_API const ALCchar * ALC_APIENTRY alcGetString( ALCdevice *device, ALCenum param ); /// <summary>This function returns a List of strings related to the context.</summary> /// <remarks> /// ALC_DEVICE_SPECIFIER will return the name of the specified output device if a pointer is supplied, or will return a list of all available devices if a NULL device pointer is supplied. A list is a pointer to a series of strings separated by NULL characters, with the list terminated by two NULL characters. See Enumeration Extension for more details. /// ALC_CAPTURE_DEVICE_SPECIFIER will return the name of the specified capture device if a pointer is supplied, or will return a list of all available devices if a NULL device pointer is supplied. /// ALC_EXTENSIONS returns a list of available context extensions, with each extension separated by a space and the list terminated by a NULL character. /// </remarks> /// <param name="device">A pointer to the device to be queried.</param> /// <param name="param">An attribute to be retrieved: ALC_DEVICE_SPECIFIER, ALC_CAPTURE_DEVICE_SPECIFIER, ALC_ALL_DEVICES_SPECIFIER.</param> /// <returns>A List of strings containing the names of the Devices.</returns> public static unsafe List <string> GetString(ALDevice device, AlcGetStringList param) { byte *result = GetStringPtr(device, (AlcGetString)param); return(ALStringListToList(result)); }
// ALC_API ALCcontext * ALC_APIENTRY alcCreateContext( ALCdevice *device, const ALCint* attrlist ); /// <summary>This function creates a context using a specified device.</summary> /// <param name="device">A pointer to a device.</param> /// <param name="attributeList">A zero terminated span of a set of attributes: ALC_FREQUENCY, ALC_MONO_SOURCES, ALC_REFRESH, ALC_STEREO_SOURCES, ALC_SYNC.</param> /// <returns>Returns a pointer to the new context (NULL on failure).</returns> /// <remarks>The attribute list can be NULL, or a zero terminated list of integer pairs composed of valid ALC attribute tokens and requested values.</remarks> public static ALContext CreateContext(ALDevice device, Span <int> attributeList) { return(CreateContext(device, ref attributeList[0])); }
public static unsafe extern byte *GetStringPtr([In] ALDevice device, AlcGetString param);
public static extern string GetString([In] ALDevice device, AlcGetString param);
public static extern int GetEnumValue([In] ALDevice device, [In] string enumname);
public static extern IntPtr GetProcAddress([In] ALDevice device, [In] string funcname);
public static extern bool IsExtensionPresent([In] ALDevice device, [In] string extname);
public static unsafe extern byte *GetStringListPtr(ALDevice device, GetEnumerationStringList param);
public static unsafe extern void GetInteger(ALDevice device, AlcGetInteger param, int size, int *data);
public static extern ALContext CreateContext([In] ALDevice device, [In] int[] attributeList);
public static extern void GetInteger(ALDevice device, AlcGetInteger param, int size, out int data);
/// <summary>This function creates a context using a specified device.</summary> /// <param name="device">A pointer to a device.</param> /// <param name="attributes">The ALContext attributes to request.</param> /// <returns>Returns a pointer to the new context (NULL on failure).</returns> /// <remarks>The attribute list can be NULL, or a zero terminated list of integer pairs composed of valid ALC attribute tokens and requested values.</remarks> public static ALContext CreateContext(ALDevice device, ALContextAttributes attributes) { return(CreateContext(device, attributes.CreateAttributeArray())); }
public static extern bool CloseDevice([In] ALDevice device);