mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-01 16:39:30 +02:00
Possibly hide unused ApplyClipping parameter in Macros.
It is unused. This hides it if the ratio has been set. Hiding it always in Macros means changing more code. It still will show if it has only been picked and not set.
This commit is contained in:
parent
545102b168
commit
238fa7f81f
@ -126,16 +126,16 @@ size_t EffectAmplify::ProcessBlock(float **inBlock, float **outBlock, size_t blo
|
||||
}
|
||||
bool EffectAmplify::DefineParams( ShuttleParams & S ){
|
||||
S.SHUTTLE_PARAM( mRatio, Ratio );
|
||||
S.SHUTTLE_PARAM( mCanClip, Clipping );
|
||||
if (!IsBatchProcessing())
|
||||
S.SHUTTLE_PARAM( mCanClip, Clipping );
|
||||
return true;
|
||||
}
|
||||
|
||||
bool EffectAmplify::GetAutomationParameters(CommandParameters & parms)
|
||||
{
|
||||
if (IsBatchProcessing())
|
||||
mCanClip = true;
|
||||
parms.WriteFloat(KEY_Ratio, mRatio);
|
||||
parms.WriteFloat(KEY_Clipping, mCanClip);
|
||||
if (!IsBatchProcessing())
|
||||
parms.WriteFloat(KEY_Clipping, mCanClip);
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -143,12 +143,15 @@ bool EffectAmplify::GetAutomationParameters(CommandParameters & parms)
|
||||
bool EffectAmplify::SetAutomationParameters(CommandParameters & parms)
|
||||
{
|
||||
ReadAndVerifyFloat(Ratio);
|
||||
ReadAndVerifyBool(Clipping);
|
||||
|
||||
mRatio = Ratio;
|
||||
mCanClip = Clipping;
|
||||
if (IsBatchProcessing())
|
||||
|
||||
if (!IsBatchProcessing()){
|
||||
ReadAndVerifyBool(Clipping);
|
||||
mCanClip = Clipping;
|
||||
} else {
|
||||
mCanClip = true;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user