Skip to content

Commit

Permalink
docs: Update doxygen comment
Browse files Browse the repository at this point in the history
  • Loading branch information
AkiyukiOkayasu committed Dec 20, 2021
1 parent 08b92a4 commit 2df6913
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -693,7 +693,7 @@ STRICT_PROTO_MATCHING = NO
# list. This list is created by putting \todo commands in the documentation.
# The default value is: YES.

GENERATE_TODOLIST = YES
GENERATE_TODOLIST = NO

# The GENERATE_TESTLIST tag can be used to enable (YES) or disable (NO) the test
# list. This list is created by putting \test commands in the documentation.
Expand Down
2 changes: 0 additions & 2 deletions include/ame_Conversion.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,6 @@ inline void deinterleaveSamples (const float* source, float** dest, const uint_f
*/
inline float semitoneToRatio (const float semitone)
{
// TODO constexpr化 std::powの置き換えが必要だが、semitoneは負数も含むので難しい
// TODO powを高速, 軽量なものに置き換えたい
return std::pow (2.0f, semitone / 12.0f);
}

Expand Down
12 changes: 5 additions & 7 deletions include/ame_Oscillator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@ constexpr std::array<FloatType, NumSamples> makeWaveTable (Function func)

/** Sine wave wavetable generator.
@tparam N array size
@return constexpr std::array<float, N> sine wave table
@todo 初期位相いじれるようにする?
@return constexpr std::array<float, N> sine wave table
*/
template <typename FloatType, size_t N>
constexpr std::array<FloatType, N> makeSineTable()
Expand All @@ -56,8 +55,7 @@ constexpr std::array<FloatType, N> makeSineTable()

/** Wavetable oscillator
@tparam FloatType float or double
@tparam numSamples
@todo 動作確認、単体テスト、doxygenコメントの英語化
@tparam numSamples
*/
template <typename FloatType, size_t N>
class WavetableOscillator
Expand Down Expand Up @@ -100,7 +98,7 @@ class WavetableOscillator
tableIndex.changeLength (wavetable.size());
}

/** Generate single sample
/** Generate single sample.
@return generated latest sample
*/
FloatType nextSample() noexcept
Expand Down Expand Up @@ -150,15 +148,15 @@ class SineOscillator
samplingPeriod = FloatType (1.0) / sampleRate;
}

/** Set the sine wave frequency
/** Set the sine wave frequency.
@param freq frequency in Hz
*/
void setFrequency (const FloatType freq) noexcept
{
phaseIncrement = freq * twoPi<FloatType> * samplingPeriod;
}

/** Generate single sample
/** Generate single sample.
@return generated latest sample
*/
float nextSample() noexcept
Expand Down
2 changes: 1 addition & 1 deletion include/ame_Pcm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ class WavPlayer
const uint32_t numChannels;
const uint32_t numSamples;
const uint16_t bitRate;
std::atomic<uint32_t> readPosition { 0 }; ///< [0, numSamples] @todo ame::Wrapに変更する?
std::atomic<uint32_t> readPosition { 0 };
std::atomic<bool> loop { false };
std::atomic<bool> playing { false };
const Chunk<BytePointerType> dataChunk;
Expand Down
3 changes: 1 addition & 2 deletions include/ame_Random.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,12 @@ inline float random()

/** white noise.
@return float [-1, 1]
@todo ベンチマーク取る.
@see ame::random()
*/
inline float noise()
{
return (next() >> 7) * FLOAT_UNIT - 1.0f; //[-1, 1]
/* もうひとつの方法. ベンチマークを取って比べたい
/* もうひとつの方法. 負荷はほぼ同じ.
return (static_cast<int32_t>(next()) >> 8) * 0x1.0p-23f;//[-1, 1]
*/
}
Expand Down
2 changes: 1 addition & 1 deletion include/ame_String.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ namespace ame
template <typename Char1Type, typename Char2Type>
constexpr bool stringComp (Char1Type str1, Char2Type str2, const uint32_t size)
{
///@todo C++20対応したらChar1TypeとChar2Typeにconceptを導入する
///@todo Char1TypeとChar2Typeにconceptを導入する
for (uint32_t i = 0; i < size; ++i)
{
if (str1[i] != str2[i])
Expand Down

0 comments on commit 2df6913

Please sign in to comment.