70 lines
637 B
C++
Executable File
70 lines
637 B
C++
Executable File
//
|
|
// Math.hpp
|
|
// amoeba
|
|
//
|
|
// Created by Timothy Prepscius on 12/30/16.
|
|
// Copyright © 2016 Timothy Prepscius. All rights reserved.
|
|
//
|
|
|
|
#pragma once
|
|
|
|
#include <tjp/core/types/Types.h>
|
|
|
|
namespace tjp {
|
|
namespace core {
|
|
namespace math {
|
|
|
|
template<typename T>
|
|
T epsilon()
|
|
{
|
|
return T(0.00001);
|
|
}
|
|
|
|
template<>
|
|
inline
|
|
s128 epsilon()
|
|
{
|
|
return 1;
|
|
}
|
|
|
|
template<>
|
|
inline
|
|
s64 epsilon()
|
|
{
|
|
return 1;
|
|
}
|
|
|
|
template<>
|
|
inline
|
|
s32 epsilon()
|
|
{
|
|
return 1;
|
|
}
|
|
|
|
template<>
|
|
inline
|
|
u128 epsilon()
|
|
{
|
|
return 1;
|
|
}
|
|
|
|
template<>
|
|
inline
|
|
u64 epsilon()
|
|
{
|
|
return 1;
|
|
}
|
|
|
|
template<>
|
|
inline
|
|
u32 epsilon()
|
|
{
|
|
return 1;
|
|
}
|
|
|
|
|
|
} // namespace
|
|
} // namespace
|
|
} // namespace
|
|
|