From 9b4e8d18f947173f3c937495e8f624e21103b3ae Mon Sep 17 00:00:00 2001 From: the_fiddler Date: Wed, 7 Oct 2009 11:20:44 +0000 Subject: [PATCH] * AL/AL.cs: * Alc/AlcEnums.cs: Fixed documentation warnings. --- Source/OpenTK/Audio/OpenAL/AL/AL.cs | 24 ++++++++++++++++++---- Source/OpenTK/Audio/OpenAL/Alc/AlcEnums.cs | 2 +- 2 files changed, 21 insertions(+), 5 deletions(-) diff --git a/Source/OpenTK/Audio/OpenAL/AL/AL.cs b/Source/OpenTK/Audio/OpenAL/AL/AL.cs index 4d96f390..95f6cb32 100644 --- a/Source/OpenTK/Audio/OpenAL/AL/AL.cs +++ b/Source/OpenTK/Audio/OpenAL/AL/AL.cs @@ -396,14 +396,30 @@ namespace OpenTK.Audio.OpenAL /// The number of sources to be generated. /// Pointer to an array of uint values which will store the names of the new sources. [CLSCompliant(false)] - [DllImport(AL.Lib, EntryPoint = "alGenSources", ExactSpelling = true, CallingConvention = AL.Style), SuppressUnmanagedCodeSecurity()] - public static extern void GenSources(int n, out uint sources); + public static void GenSources(int n, out uint sources) + { + unsafe + { + fixed (uint* sources_ptr = &sources) + { + GenSourcesPrivate(n, sources_ptr); + } + } + } /// This function generates one or more sources. References to sources are int values, which are used wherever a source reference is needed (in calls such as AL.DeleteSources and AL.Source with parameter ALSourcei). /// The number of sources to be generated. /// Pointer to an array of int values which will store the names of the new sources. - [DllImport(AL.Lib, EntryPoint = "alGenSources", ExactSpelling = true, CallingConvention = AL.Style), SuppressUnmanagedCodeSecurity()] - public static extern void GenSources(int n, out int sources); + public static void GenSources(int n, out int sources) + { + unsafe + { + fixed (int* sources_ptr = &sources) + { + GenSourcesPrivate(n, (uint*)sources_ptr); + } + } + } /// This function generates one or more sources. References to sources are int values, which are used wherever a source reference is needed (in calls such as AL.DeleteSources and AL.Source with parameter ALSourcei). /// Pointer to an array of int values which will store the names of the new sources. diff --git a/Source/OpenTK/Audio/OpenAL/Alc/AlcEnums.cs b/Source/OpenTK/Audio/OpenAL/Alc/AlcEnums.cs index e905b6cc..6f68fc62 100644 --- a/Source/OpenTK/Audio/OpenAL/Alc/AlcEnums.cs +++ b/Source/OpenTK/Audio/OpenAL/Alc/AlcEnums.cs @@ -104,7 +104,7 @@ namespace OpenTK.Audio.OpenAL } /// - /// Defines available parameters for . + /// Defines available parameters for . /// public enum AlcGetInteger : int {