libstage
logentry.cc
Go to the documentation of this file.
1
#include "
stage.hh
"
2
using namespace
Stg
;
3
4
// static data members
5
std::vector<LogEntry>
LogEntry::log
;
6
7
LogEntry::LogEntry
(
usec_t
timestamp,
Model
*mod)
8
: timestamp(timestamp), mod(mod), pose(mod->GetPose())
9
{
10
// all log entries are added to the static vector history
11
log
.push_back(*
this
);
12
}
13
14
void
LogEntry::Print
()
15
{
16
for
(
size_t
i = 0; i <
log
.size(); i++) {
17
LogEntry
*e = &
log
[i];
18
19
printf(
"%.3f\t%u\t%s\n"
, (
double
)e->
timestamp
/ 1e6, e->
mod
->
GetId
(),
20
e->
mod
->
PoseString
().c_str());
21
}
22
}
Stg::Model
Model class
Definition:
stage.hh:1651
Stg::LogEntry
Definition:
stage.hh:734
Stg::LogEntry::Print
static void Print()
Definition:
logentry.cc:14
Stg::LogEntry::timestamp
usec_t timestamp
Definition:
stage.hh:735
Stg
The Stage library uses its own namespace.
Definition:
canvas.hh:8
Stg::Model::GetId
uint32_t GetId() const
Definition:
stage.hh:2235
stage.hh
Stg::Model::PoseString
std::string PoseString()
Definition:
stage.hh:2089
Stg::usec_t
uint64_t usec_t
Definition:
stage.hh:203
Stg::LogEntry::LogEntry
LogEntry(usec_t timestamp, Model *mod)
Definition:
logentry.cc:7
Stg::LogEntry::log
static std::vector< LogEntry > log
Definition:
stage.hh:743
Stg::LogEntry::mod
Model * mod
Definition:
stage.hh:736
stage
Author(s): Richard Vaughan
, Brian Gerkey
, Reed Hedges
, Andrew Howard
, Toby Collett
, Pooya Karimian
, Jeremy Asher
, Alex Couture-Beil
, Geoff Biggs
, Rich Mattes
, Abbas Sadat
autogenerated on Mon Feb 28 2022 23:48:55