using Ryujinx.Audio.Renderer.Server.Effect;
using Ryujinx.Common.Memory;
using System.Runtime.InteropServices;
namespace Ryujinx.Audio.Renderer.Parameter.Effect
{
///
/// for .
///
[StructLayout(LayoutKind.Sequential, Pack = 1)]
public struct Reverb3dParameter
{
///
/// The input channel indices that will be used by the .
///
public Array6 Input;
///
/// The output channel indices that will be used by the .
///
public Array6 Output;
///
/// The maximum number of channels supported.
///
public ushort ChannelCountMax;
///
/// The total channel count used.
///
public ushort ChannelCount;
///
/// Reserved/unused.
///
private readonly uint _reserved;
///
/// The target sample rate.
///
/// This is in kHz.
public uint SampleRate;
///
/// Gain of the room high-frequency effect.
///
public float RoomHf;
///
/// Reference high frequency.
///
public float HfReference;
///
/// Reverberation decay time at low frequencies.
///
public float DecayTime;
///
/// Ratio of the decay time at high frequencies to the decay time at low frequencies.
///
public float HfDecayRatio;
///
/// Gain of the room effect.
///
public float RoomGain;
///
/// Gain of the early reflections relative to .
///
public float ReflectionsGain;
///
/// Gain of the late reverberation relative to .
///
public float ReverbGain;
///
/// Echo density in the late reverberation decay.
///
public float Diffusion;
///
/// Modal density in the late reverberation decay.
///
public float ReflectionDelay;
///
/// Time limit between the early reflections and the late reverberation relative to the time of the first reflection.
///
public float ReverbDelayTime;
///
/// Modal density in the late reverberation decay.
///
public float Density;
///
/// The dry gain.
///
public float DryGain;
///
/// The current usage status of the effect on the client side.
///
public UsageState ParameterStatus;
///
/// Check if the is valid.
///
/// Returns true if the is valid.
public readonly bool IsChannelCountValid()
{
return EffectInParameterVersion1.IsChannelCountValid(ChannelCount);
}
///
/// Check if the is valid.
///
/// Returns true if the is valid.
public readonly bool IsChannelCountMaxValid()
{
return EffectInParameterVersion1.IsChannelCountValid(ChannelCountMax);
}
}
}