Marionette: Create include dir and move body map headers in
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
#ifndef _BODY_MAP_H
|
||||
#define _BODY_MAP_H
|
||||
|
||||
#include <set>
|
||||
#include <cstdint>
|
||||
|
||||
#include <body/limb.h>
|
||||
|
||||
class BodyMap {
|
||||
public:
|
||||
BodyMap() = default;
|
||||
~BodyMap() = default;
|
||||
|
||||
std::set<uint32_t, BodyLimb> limbs;
|
||||
};
|
||||
|
||||
#endif // _BODY_MAP_H
|
||||
@@ -0,0 +1,64 @@
|
||||
#ifndef BODY_MESSAGE_H
|
||||
#define BODY_MESSAGE_H
|
||||
|
||||
#include <vector>
|
||||
#include <cstdint>
|
||||
|
||||
#include <body/limb.h>
|
||||
#include <body/bodyPart.h>
|
||||
|
||||
class BodyMessage
|
||||
{
|
||||
public:
|
||||
BodyMessage() = default;
|
||||
~BodyMessage() = default;
|
||||
};
|
||||
|
||||
class BodySpotImpactEntry
|
||||
{
|
||||
public:
|
||||
enum class ReportType
|
||||
{
|
||||
PRESSURE,
|
||||
PAIN,
|
||||
PLEASURE,
|
||||
HEAT,
|
||||
COLD
|
||||
};
|
||||
|
||||
BodySpotImpactEntry(uint32_t _spot, ReportType _type, uint32_t _value)
|
||||
: spot(_spot), type(_type), value(_value)
|
||||
{}
|
||||
~BodySpotImpactEntry() = default;
|
||||
|
||||
public:
|
||||
uint32_t spot;
|
||||
ReportType type;
|
||||
uint32_t value;
|
||||
};
|
||||
|
||||
class BodySpotImpactInd
|
||||
: public BodyMessage
|
||||
{
|
||||
public:
|
||||
BodySpotImpactInd(BodyPart &_part) : part(_part) {}
|
||||
~BodySpotImpactInd() = default;
|
||||
|
||||
public:
|
||||
BodyPart ∂
|
||||
std::vector<BodySpotImpactEntry> entries;
|
||||
};
|
||||
|
||||
class BodyPartMsg
|
||||
: public BodyMessage
|
||||
{
|
||||
public:
|
||||
BodyPartMsg(const BodyPart& _part)
|
||||
:part(_part)
|
||||
{}
|
||||
|
||||
public:
|
||||
const BodyPart& part;
|
||||
};
|
||||
|
||||
#endif // BODY_MESSAGE_H
|
||||
@@ -0,0 +1,42 @@
|
||||
#ifndef BODYPART_H
|
||||
#define BODYPART_H
|
||||
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
#include <set>
|
||||
|
||||
#include <sensors/interoceptor.h>
|
||||
|
||||
class BodySpot
|
||||
{
|
||||
public:
|
||||
BodySpot(uint32_t _id, std::string _description)
|
||||
: id(_id), description(_description)
|
||||
{}
|
||||
|
||||
~BodySpot() = default;
|
||||
|
||||
public:
|
||||
uint32_t id;
|
||||
std::string description;
|
||||
std::set<uint32_t, Interoceptor> interoceptors;
|
||||
};
|
||||
|
||||
class BodyPart
|
||||
{
|
||||
public:
|
||||
BodyPart(uint32_t _partId, std::string _partName,
|
||||
std::string _partDesc, std::string _partLoc)
|
||||
: id(_partId), name(_partName),
|
||||
description(_partDesc), location(_partLoc)
|
||||
{}
|
||||
|
||||
~BodyPart() = default;
|
||||
|
||||
public:
|
||||
const uint32_t id;
|
||||
std::string name, description, location;
|
||||
std::set<uint32_t, BodySpot> spots;
|
||||
};
|
||||
|
||||
#endif // BODYPART_H
|
||||
@@ -0,0 +1,28 @@
|
||||
#ifndef BODY_LIMB_H
|
||||
#define BODY_LIMB_H
|
||||
|
||||
#include <string>
|
||||
#include <set>
|
||||
#include <cstdint>
|
||||
|
||||
#include <body/bodyPart.h>
|
||||
|
||||
class BodyLimb
|
||||
{
|
||||
public:
|
||||
BodyLimb(uint32_t _id) : id(_id) {}
|
||||
BodyLimb(uint32_t _id,
|
||||
const std::string& _name, const std::string& _desc,
|
||||
const std::string& _loc)
|
||||
: id(_id), name(_name), description(_desc), location(_loc)
|
||||
{}
|
||||
|
||||
~BodyLimb() = default;
|
||||
|
||||
public:
|
||||
uint32_t id;
|
||||
std::string name, description, location;
|
||||
std::set<uint32_t, BodyPart> parts;
|
||||
};
|
||||
|
||||
#endif // BODY_LIMB_H
|
||||
Reference in New Issue
Block a user