1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192 |
- #pragma once
- #include "openmpt/all/BuildSettings.hpp"
- #include "FadeLaws.h"
- #include "../soundlib/Snd_defs.h"
- OPENMPT_NAMESPACE_BEGIN
- class CSoundFile;
- struct ModSample;
- struct ModChannel;
- namespace SampleEdit
- {
- enum ResetFlag
- {
- SmpResetCompo,
- SmpResetInit,
- SmpResetVibrato,
- };
- std::vector<std::reference_wrapper<SmpLength>> GetCuesAndLoops(ModSample &smp);
- SmpLength InsertSilence(ModSample &smp, const SmpLength silenceLength, const SmpLength startFrom, CSoundFile &sndFile);
- SmpLength RemoveRange(ModSample &smp, SmpLength selStart, SmpLength selEnd, CSoundFile &sndFile);
- SmpLength ResizeSample(ModSample &smp, const SmpLength newLength, CSoundFile &sndFile);
- void ResetSamples(CSoundFile &sndFile, ResetFlag resetflag, SAMPLEINDEX minSample = SAMPLEINDEX_INVALID, SAMPLEINDEX maxSample = SAMPLEINDEX_INVALID);
- double RemoveDCOffset(ModSample &smp, SmpLength start, SmpLength end, CSoundFile &sndFile);
- bool AmplifySample(ModSample &smp, SmpLength start, SmpLength end, double amplifyStart, double amplifyEnd, bool isFadeIn, Fade::Law fadeLaw, CSoundFile &sndFile);
- bool ReverseSample(ModSample &smp, SmpLength start, SmpLength end, CSoundFile &sndFile);
- bool UnsignSample(ModSample &smp, SmpLength start, SmpLength end, CSoundFile &sndFile);
- bool InvertSample(ModSample &smp, SmpLength start, SmpLength end, CSoundFile &sndFile);
- bool XFadeSample(ModSample &smp, SmpLength fadeLength, int fadeLaw, bool afterloopFade, bool useSustainLoop, CSoundFile &sndFile);
- bool SilenceSample(ModSample &smp, SmpLength start, SmpLength end, CSoundFile &sndFile);
- bool StereoSepSample(ModSample &smp, SmpLength start, SmpLength end, double separation, CSoundFile &sndFile);
- bool ConvertTo8Bit(ModSample &smp, CSoundFile &sndFile);
- bool ConvertTo16Bit(ModSample &smp, CSoundFile &sndFile);
- bool ConvertPingPongLoop(ModSample &smp, CSoundFile &sndFile, bool sustainLoop);
- }
- OPENMPT_NAMESPACE_END
|