Floessie suggested some C++11 related improvements which I add with this commit

This commit is contained in:
heckflosse
2016-05-11 00:04:11 +02:00
parent 5c14573be7
commit aa2beb4c72
2 changed files with 92 additions and 141 deletions

View File

@@ -59,17 +59,8 @@
#ifndef LUT_H_
#define LUT_H_
// bit representations of flags
#define LUT_CLIP_BELOW 1
#define LUT_CLIP_ABOVE 2
#define LUTf LUT<float>
#define LUTi LUT<int32_t>
#define LUTu LUT<uint32_t>
#define LUTd LUT<double>
#define LUTuc LUT<uint8_t>
#include <cstring>
#include <cstdint>
#ifndef NDEBUG
#include <glibmm.h>
#include <fstream>
@@ -78,6 +69,21 @@
#include <assert.h>
#include "rt_math.h"
// Bit representations of flags
enum {
LUT_CLIP_BELOW = 1 << 0,
LUT_CLIP_ABOVE = 1 << 1
};
template<typename T>
class LUT;
using LUTf = LUT<float>;
using LUTi = LUT<int32_t>;
using LUTu = LUT<uint32_t>;
using LUTd = LUT<double>;
using LUTuc = LUT<uint8_t>;
template<typename T>
class LUT
{