Replace tLimit() with qBound() and remove templates.h (#5040)

* Replace tLimit() with qBound()

* Remove templates.h
This commit is contained in:
Hussam al-Homsi
2019-06-15 23:33:29 +03:00
committed by GitHub
parent f141ae68e0
commit 5431cc7942
29 changed files with 45 additions and 100 deletions

View File

@@ -36,7 +36,6 @@
#include "NotePlayHandle.h"
#include "Oscillator.h"
#include "PixmapButton.h"
#include "templates.h"
#include "ToolTip.h"
#include "Song.h"
#include "interpolation.h"

View File

@@ -41,7 +41,6 @@
#include "NotePlayHandle.h"
#include "Oscillator.h"
#include "PixmapButton.h"
#include "templates.h"
#include "ToolTip.h"
#include "BandLimitedWave.h"

View File

@@ -28,7 +28,6 @@
#include "Monstro.h"
#include "Engine.h"
#include "InstrumentTrack.h"
#include "templates.h"
#include "gui_templates.h"
#include "ToolTip.h"
#include "Song.h"

View File

@@ -27,7 +27,6 @@
#include "Nes.h"
#include "Engine.h"
#include "InstrumentTrack.h"
#include "templates.h"
#include "ToolTip.h"
#include "Song.h"
#include "lmms_math.h"

View File

@@ -37,7 +37,6 @@
#include "NotePlayHandle.h"
#include "Oscillator.h"
#include "PixmapButton.h"
#include "templates.h"
#include "ToolTip.h"
#include "embed.h"

View File

@@ -45,7 +45,6 @@ float frnd(float range)
#include "Knob.h"
#include "NotePlayHandle.h"
#include "PixmapButton.h"
#include "templates.h"
#include "ToolTip.h"
#include "Song.h"
#include "MidiEvent.h"

View File

@@ -35,7 +35,6 @@
#include "CaptionMenu.h"
#include "Oscillator.h"
#include "string_container.h"
#include "templates.h"
#include "volume.h"
#include "Song.h"

View File

@@ -24,7 +24,6 @@
#include <math.h>
#include "vibrating_string.h"
#include "templates.h"
#include "interpolation.h"
#include "Mixer.h"
#include "Engine.h"
@@ -145,9 +144,9 @@ void vibratingString::resample( float *_src, f_cnt_t _src_frames,
_dst_frames;
const float frac_pos = src_frame_float -
static_cast<f_cnt_t>( src_frame_float );
const f_cnt_t src_frame = tLimit<f_cnt_t>(
static_cast<f_cnt_t>( src_frame_float ),
1, _src_frames - 3 );
const f_cnt_t src_frame = qBound<f_cnt_t>(
1, static_cast<f_cnt_t>( src_frame_float ),
_src_frames - 3 );
m_impulse[frame] = cubicInterpolate(
_src[src_frame - 1],
_src[src_frame + 0],

View File

@@ -60,7 +60,6 @@
#include "MainWindow.h"
#include "Mixer.h"
#include "Song.h"
#include "templates.h"
#include "FileDialog.h"
#ifdef LMMS_BUILD_LINUX

View File

@@ -28,7 +28,6 @@
#include "base64.h"
#include "Engine.h"
#include "InstrumentTrack.h"
#include "templates.h"
#include "ToolTip.h"
#include "Song.h"
#include "lmms_math.h"