mirror of
https://github.com/Ryujinx/Opentk.git
synced 2024-12-26 17:55:39 +00:00
Fixed EfxExtension.DeleteEffects bindings.
This commit is contained in:
parent
624497098e
commit
3aadd5d36a
|
@ -200,11 +200,11 @@ namespace OpenTK.Audio
|
||||||
/// <param name="n">Number of Effects to be deleted.</param>
|
/// <param name="n">Number of Effects to be deleted.</param>
|
||||||
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
||||||
[CLSCompliant(false)]
|
[CLSCompliant(false)]
|
||||||
public void DeleteEffects(int n, ref uint[] effects)
|
public void DeleteEffects(int n, ref uint effects)
|
||||||
{
|
{
|
||||||
unsafe
|
unsafe
|
||||||
{
|
{
|
||||||
fixed (uint* ptr = effects)
|
fixed (uint* ptr = &effects)
|
||||||
{
|
{
|
||||||
Imported_alDeleteEffects(n, ptr);
|
Imported_alDeleteEffects(n, ptr);
|
||||||
}
|
}
|
||||||
|
@ -214,60 +214,43 @@ namespace OpenTK.Audio
|
||||||
/// <summary>The DeleteEffects function is used to delete and free resources for Effect objects previously created with GenEffects.</summary>
|
/// <summary>The DeleteEffects function is used to delete and free resources for Effect objects previously created with GenEffects.</summary>
|
||||||
/// <param name="n">Number of Effects to be deleted.</param>
|
/// <param name="n">Number of Effects to be deleted.</param>
|
||||||
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
||||||
|
public void DeleteEffects(int n, ref int effects)
|
||||||
public void DeleteEffects(int n, ref int[] effects)
|
|
||||||
{
|
|
||||||
uint[] temp = new uint[n];
|
|
||||||
for (int i = 0; i < n; i++)
|
|
||||||
{
|
|
||||||
temp[i] = (uint)effects[i];
|
|
||||||
}
|
|
||||||
DeleteEffects(n, ref temp);
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>The DeleteEffects function is used to delete and free resources for Effect objects previously created with GenEffects.</summary>
|
|
||||||
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
|
||||||
|
|
||||||
public void DeleteEffects(int[] effects)
|
|
||||||
{
|
|
||||||
uint[] temp = new uint[effects.Length];
|
|
||||||
for (int i = 0; i < temp.Length; i++)
|
|
||||||
{
|
|
||||||
temp[i] = (uint)effects[i];
|
|
||||||
}
|
|
||||||
DeleteEffects(temp.Length, ref temp);
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>This function deletes one Effect only.</summary>
|
|
||||||
/// <param name="effect">Pointer to an effect name/handle identifying the Effect Object to be deleted.</param>
|
|
||||||
[CLSCompliant(false)]
|
|
||||||
public void DeleteEffects(ref uint effect)
|
|
||||||
{
|
{
|
||||||
unsafe
|
unsafe
|
||||||
{
|
{
|
||||||
fixed (uint* ptr = &effect)
|
fixed (int* ptr = &effects)
|
||||||
{
|
{
|
||||||
Imported_alDeleteEffects(1, ptr);
|
Imported_alDeleteEffects(n, (uint*)ptr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>This function deletes one Effect only.</summary>
|
/// <summary>The DeleteEffects function is used to delete and free resources for Effect objects previously created with GenEffects.</summary>
|
||||||
/// <param name="effect">Pointer to an effect name/handle identifying the Effect Object to be deleted.</param>
|
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
||||||
|
public void DeleteEffects(int[] effects)
|
||||||
public void DeleteEffects(ref int effect)
|
|
||||||
{
|
{
|
||||||
uint temp = (uint)effect;
|
if (effects == null) throw new ArgumentNullException("effects");
|
||||||
DeleteEffects(ref temp);
|
DeleteEffects(effects.Length, ref effects[0]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>The DeleteEffects function is used to delete and free resources for Effect objects previously created with GenEffects.</summary>
|
||||||
|
/// <param name="effects">Pointer to n Effect object identifiers.</param>
|
||||||
|
[CLSCompliant(false)]
|
||||||
|
public void DeleteEffects(uint[] effects)
|
||||||
|
{
|
||||||
|
if (effects == null) throw new ArgumentNullException("effects");
|
||||||
|
DeleteEffects(effects.Length, ref effects[0]);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>This function deletes one Effect only.</summary>
|
/// <summary>This function deletes one Effect only.</summary>
|
||||||
/// <param name="effect">Pointer to an effect name/handle identifying the Effect Object to be deleted.</param>
|
/// <param name="effect">Pointer to an effect name/handle identifying the Effect Object to be deleted.</param>
|
||||||
|
public void DeleteEffect(int effect)
|
||||||
public void DeleteEffects(int effect)
|
|
||||||
{
|
{
|
||||||
uint temp = (uint)effect;
|
unsafe
|
||||||
DeleteEffects(ref temp);
|
{
|
||||||
|
Imported_alDeleteEffects(1, (uint*)&effect);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion alDeleteEffects
|
#endregion alDeleteEffects
|
||||||
|
|
Loading…
Reference in a new issue