Skip to content

Commit

Permalink
Merge branch 'master' of github.com:opentk/opentk into fix-update
Browse files Browse the repository at this point in the history
  • Loading branch information
NogginBops committed Jul 13, 2023
2 parents 7db8ac0 + aca1ee4 commit df2e467
Show file tree
Hide file tree
Showing 50 changed files with 1,881 additions and 1,860 deletions.
2 changes: 1 addition & 1 deletion src/OpenAL/OpenTK.OpenAL/ALC/ALC.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
namespace OpenTK.Audio.OpenAL
{
/// <summary>Alc = Audio Library Context.</summary>
public class ALC : ALBase
public partial class ALC : ALBase
{
internal const string Lib = AL.Lib;
internal const CallingConvention AlcCallingConv = CallingConvention.Cdecl;
Expand Down
2,422 changes: 1,214 additions & 1,208 deletions src/OpenAL/OpenTK.OpenAL/Extensions/Creative.EFX/EFX.cs

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Defines new context attributes.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Defines new integer properties on the OpenAL context.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="float"/> Listener/GetListener parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="bool"/> Source/GetSource parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="float"/> Source/GetSource parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="int"/> Source/GetSource parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="int"/> Source/GetSource parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid 32-bit Float Effect/GetEffect parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid Int32 Effect/GetEffect parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="float"/> AuxiliaryEffectSlot/GetAuxiliaryEffectSlot parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="int"/> AuxiliaryEffectSlot/GetAuxiliaryEffectSlot parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Effect type definitions to be used with EfxEffecti.EffectType.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid Math.Vector3 Effect/GetEffect parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="float"/> Filter/GetFilter parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A list of valid <see cref="int"/> Filter/GetFilter parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Filter type definitions to be used with EfxFilteri.FilterType.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Vocal morpher effect parameters. If both parameters are set to the same phoneme, that determines the filtering
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// May be passed at context construction time to indicate the number of desired auxiliary effect slot sends per
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

using OpenTK.Mathematics;

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// A set of reverb presets that can be used with the extension.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

using OpenTK.Mathematics;

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EFX
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Defines a set of predefined reverb properties.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,70 +10,73 @@
using System.Collections.Generic;
using System.Runtime.InteropServices;

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EnumerateAll
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Exposes the API in the EnumerateAll extension.
/// </summary>
public class EnumerateAll : ALBase
public partial class ALC
{
/// <summary>
/// The name of this AL extension.
/// Exposes the API in the EnumerateAll extension.
/// </summary>
public const string ExtensionName = "ALC_ENUMERATE_ALL_EXT";

static EnumerateAll()
public class EnumerateAll : ALBase
{
// We need to register the resolver for OpenAL before we can DllImport functions.
ALBase.RegisterOpenALResolver();
}
/// <summary>
/// The name of this AL extension.
/// </summary>
public const string ExtensionName = "ALC_ENUMERATE_ALL_EXT";

private EnumerateAll()
{
}
static EnumerateAll()
{
// We need to register the resolver for OpenAL before we can DllImport functions.
ALBase.RegisterOpenALResolver();
}

/// <summary>
/// Checks whether the extension is present.
/// </summary>
/// <returns>Whether the extension was present or not.</returns>
public static bool IsExtensionPresent()
{
return ALC.IsExtensionPresent(ALDevice.Null, ExtensionName);
}
private EnumerateAll()
{
}

/// <summary>
/// Checks whether the extension is present.
/// </summary>
/// <param name="device">The device to be queried.</param>
/// <returns>Whether the extension was present or not.</returns>
public static bool IsExtensionPresent(ALDevice device)
{
return ALC.IsExtensionPresent(device, ExtensionName);
}
/// <summary>
/// Checks whether the extension is present.
/// </summary>
/// <returns>Whether the extension was present or not.</returns>
public static bool IsExtensionPresent()
{
return ALC.IsExtensionPresent(ALDevice.Null, ExtensionName);
}

/// <summary>
/// Gets a named property on the context.
/// </summary>
/// <param name="device">The device for the context.</param>
/// <param name="param">The named property.</param>
/// <returns>The value.</returns>
[DllImport(ALC.Lib, EntryPoint = "alcGetString", ExactSpelling = true, CallingConvention = ALC.AlcCallingConv)]
public static extern string GetString(ALDevice device, GetEnumerateAllContextString param);
/// <summary>
/// Checks whether the extension is present.
/// </summary>
/// <param name="device">The device to be queried.</param>
/// <returns>Whether the extension was present or not.</returns>
public static bool IsExtensionPresent(ALDevice device)
{
return ALC.IsExtensionPresent(device, ExtensionName);
}

/// <summary>
/// Gets a named property on the context.
/// </summary>
/// <param name="device">The device for the context.</param>
/// <param name="param">The named property.</param>
/// <returns>The value.</returns>
[DllImport(ALC.Lib, EntryPoint = "alcGetString", ExactSpelling = true, CallingConvention = ALC.AlcCallingConv)]
public static extern unsafe byte* GetStringList(ALDevice device, GetEnumerateAllContextStringList param);
/// <summary>
/// Gets a named property on the context.
/// </summary>
/// <param name="device">The device for the context.</param>
/// <param name="param">The named property.</param>
/// <returns>The value.</returns>
[DllImport(ALC.Lib, EntryPoint = "alcGetString", ExactSpelling = true, CallingConvention = ALC.AlcCallingConv)]
public static extern string GetString(ALDevice device, GetEnumerateAllContextString param);

/// <inheritdoc cref="GetStringList(ALDevice, GetEnumerateAllContextStringList)"/>
public static unsafe IEnumerable<string> GetStringList(GetEnumerateAllContextStringList param)
{
byte* result = GetStringList(ALDevice.Null, param);
return ALC.ALStringListToList(result);
/// <summary>
/// Gets a named property on the context.
/// </summary>
/// <param name="device">The device for the context.</param>
/// <param name="param">The named property.</param>
/// <returns>The value.</returns>
[DllImport(ALC.Lib, EntryPoint = "alcGetString", ExactSpelling = true, CallingConvention = ALC.AlcCallingConv)]
public static extern unsafe byte* GetStringList(ALDevice device, GetEnumerateAllContextStringList param);

/// <inheritdoc cref="GetStringList(ALDevice, GetEnumerateAllContextStringList)"/>
public static unsafe IEnumerable<string> GetStringList(GetEnumerateAllContextStringList param)
{
byte* result = GetStringList(ALDevice.Null, param);
return ALC.ALStringListToList(result);
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EnumerateAll
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Defines available parameters for <see cref="EnumerateAll.GetString(ALDevice, GetEnumerateAllContextString)" />.
/// Defines available parameters for <see cref="ALC.EnumerateAll.GetString(ALDevice, GetEnumerateAllContextString)" />.
/// </summary>
public enum GetEnumerateAllContextString
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
// of the MIT license. See the LICENSE file for details.
//

namespace OpenTK.Audio.OpenAL.Extensions.Creative.EnumerateAll
namespace OpenTK.Audio.OpenAL
{
/// <summary>
/// Defines available parameters for <see cref="EnumerateAll.GetStringList(ALDevice, GetEnumerateAllContextStringList)" />.
/// Defines available parameters for <see cref="ALC.EnumerateAll.GetStringList(ALDevice, GetEnumerateAllContextStringList)" />.
/// </summary>
public enum GetEnumerateAllContextStringList
{
Expand Down
Loading

0 comments on commit df2e467

Please sign in to comment.