MRPT
1.9.9
logoddscell_traits.h
Go to the documentation of this file.
1
/* +------------------------------------------------------------------------+
2
| Mobile Robot Programming Toolkit (MRPT) |
3
| https://www.mrpt.org/ |
4
| |
5
| Copyright (c) 2005-2019, Individual contributors, see AUTHORS file |
6
| See: https://www.mrpt.org/Authors - All rights reserved. |
7
| Released under BSD License. See: https://www.mrpt.org/License |
8
+------------------------------------------------------------------------+ */
9
10
#pragma once
11
12
#include <cstdint>
13
14
namespace
mrpt::maps::detail
15
{
16
template
<
typename
TCELL>
17
struct
logoddscell_traits
;
18
// Specializations:
19
template
<>
20
struct
logoddscell_traits
<
int8_t
>
21
{
22
static
constexpr
int8_t
CELLTYPE_MIN = -127;
23
static
constexpr
int8_t
CELLTYPE_MAX = 127;
24
static
constexpr
int8_t
P2LTABLE_SIZE = CELLTYPE_MAX;
25
static
constexpr std::size_t LOGODDS_LUT_ENTRIES = 1 << 8;
26
};
27
template
<>
28
struct
logoddscell_traits
<
int16_t
>
29
{
30
static
constexpr
int16_t
CELLTYPE_MIN = -32767;
31
static
constexpr
int16_t
CELLTYPE_MAX = 32767;
32
static
constexpr
int16_t
P2LTABLE_SIZE = CELLTYPE_MAX;
33
static
constexpr std::size_t LOGODDS_LUT_ENTRIES = 1 << 16;
34
};
35
}
// namespace mrpt::maps::detail
mrpt::maps::detail::logoddscell_traits
Definition:
logoddscell_traits.h:17
int8_t
signed char int8_t
Definition:
rptypes.h:43
int16_t
__int16 int16_t
Definition:
rptypes.h:46
mrpt::maps::detail
Definition:
CPointsMap.h:34
Page generated by
Doxygen 1.8.14
for MRPT 1.9.9 Git: 8fe78517f Sun Jul 14 19:43:28 2019 +0200 at lun oct 28 02:10:00 CET 2019