OpenPose
1.7.0
The first real-time multi-person system to jointly detect human body, hand, facial, and foot keypoints
pointerContainer.hpp
Go to the documentation of this file.
1
#ifndef OPENPOSE_UTILITIES_POINTER_CONTAINER_HPP
2
#define OPENPOSE_UTILITIES_POINTER_CONTAINER_HPP
3
4
namespace
op
5
{
6
template
<
typename
TPo
int
erContainer>
7
inline
bool
checkNoNullNorEmpty
(
const
TPointerContainer& tPointerContainer)
8
{
9
return
(tPointerContainer !=
nullptr
&& tPointerContainer->size() > 0);
10
}
11
12
template
<
typename
TDatumsSP>
13
class
PointerContainerGreater
14
{
15
public
:
16
bool
operator()
(
const
TDatumsSP& a,
const
TDatumsSP& b)
17
{
18
if
(!b || b->empty())
19
return
true
;
20
else
if
(!a || a->empty())
21
return
false
;
22
else
23
return
*(*a)[0] > *(*b)[0];
24
}
25
};
26
27
template
<
typename
TDatumsSP>
28
class
PointerContainerLess
29
{
30
public
:
31
bool
operator()
(
const
TDatumsSP& a,
const
TDatumsSP& b)
32
{
33
if
(!b || b->empty())
34
return
false
;
35
else
if
(!a || a->empty())
36
return
true
;
37
else
38
return
*(*a)[0] < *(*b)[0];
39
}
40
};
41
}
42
43
#endif
// OPENPOSE_UTILITIES_POINTER_CONTAINER_HPP
op::PointerContainerGreater
Definition:
pointerContainer.hpp:14
op::PointerContainerGreater::operator()
bool operator()(const TDatumsSP &a, const TDatumsSP &b)
Definition:
pointerContainer.hpp:16
op::PointerContainerLess
Definition:
pointerContainer.hpp:29
op::PointerContainerLess::operator()
bool operator()(const TDatumsSP &a, const TDatumsSP &b)
Definition:
pointerContainer.hpp:31
op
Definition:
cameraParameterReader.hpp:7
op::checkNoNullNorEmpty
bool checkNoNullNorEmpty(const TPointerContainer &tPointerContainer)
Definition:
pointerContainer.hpp:7
include
openpose
utilities
pointerContainer.hpp
Generated by
1.9.1