gusimplewhiteboard
wb_landmark_sighting.h File Reference
#include <gu_util.h>
#include <stdint.h>
Include dependency graph for wb_landmark_sighting.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  wb_landmark_sighting
 WHITEBOARD_POSTER_STRING_CONVERSION. More...
 

Macros

#define _XOPEN_SOURCE   700
 
#define LANDMARK_SIGHTING_GENERATED
 
#define LANDMARK_SIGHTING_C_STRUCT   wb_landmark_sighting
 
#define LANDMARK_SIGHTING_NUMBER_OF_VARIABLES   3
 
#define LANDMARK_SIGHTING_DESC_BUFFER_SIZE   560
 
#define LANDMARK_SIGHTING_TO_STRING_BUFFER_SIZE   528
 

Enumerations

enum  LandmarkSightingType {
  GenericGoalPostSightingType , LeftGoalPostSightingType , RightGoalPostSightingType , GoalLandmarkSightingType ,
  LineHorizonSightingType , CornerHorizonSightingType , StraightLineSightingType , CornerLineSightingType ,
  TIntersectionLineSightingType , CrossLineSightingType , BallSightingType
}
 

Functions

const char * wb_landmark_sighting_description (const struct wb_landmark_sighting *self, char *descString, size_t bufferSize)
 Convert to a description string. More...
 
const char * wb_landmark_sighting_to_string (const struct wb_landmark_sighting *self, char *toString, size_t bufferSize)
 Convert to a string. More...
 
struct wb_landmark_sightingwb_landmark_sighting_from_string (struct wb_landmark_sighting *self, const char *str)
 Convert from a string. More...
 
size_t wb_landmark_sighting_to_network_serialised (const struct wb_landmark_sighting *self, char *dst)
 WHITEBOARD_POSTER_STRING_CONVERSION. More...
 
size_t wb_landmark_sighting_from_network_serialised (const char *src, struct wb_landmark_sighting *dst)
 Network stream deserialisation. More...
 

Macro Definition Documentation

◆ _XOPEN_SOURCE

#define _XOPEN_SOURCE   700

Definition at line 72 of file wb_landmark_sighting.h.

◆ LANDMARK_SIGHTING_C_STRUCT

#define LANDMARK_SIGHTING_C_STRUCT   wb_landmark_sighting

Definition at line 103 of file wb_landmark_sighting.h.

◆ LANDMARK_SIGHTING_DESC_BUFFER_SIZE

#define LANDMARK_SIGHTING_DESC_BUFFER_SIZE   560

Definition at line 107 of file wb_landmark_sighting.h.

◆ LANDMARK_SIGHTING_GENERATED

#define LANDMARK_SIGHTING_GENERATED

Definition at line 102 of file wb_landmark_sighting.h.

◆ LANDMARK_SIGHTING_NUMBER_OF_VARIABLES

#define LANDMARK_SIGHTING_NUMBER_OF_VARIABLES   3

Definition at line 104 of file wb_landmark_sighting.h.

◆ LANDMARK_SIGHTING_TO_STRING_BUFFER_SIZE

#define LANDMARK_SIGHTING_TO_STRING_BUFFER_SIZE   528

Definition at line 108 of file wb_landmark_sighting.h.

Enumeration Type Documentation

◆ LandmarkSightingType

Enumerator
GenericGoalPostSightingType 
LeftGoalPostSightingType 
RightGoalPostSightingType 
GoalLandmarkSightingType 
LineHorizonSightingType 
CornerHorizonSightingType 
StraightLineSightingType 
CornerLineSightingType 
TIntersectionLineSightingType 
CrossLineSightingType 
BallSightingType 

Definition at line 88 of file wb_landmark_sighting.h.

Function Documentation

◆ wb_landmark_sighting_description()

◆ wb_landmark_sighting_from_network_serialised()

size_t wb_landmark_sighting_from_network_serialised ( const char *  src,
struct wb_landmark_sighting dst 
)

Network stream deserialisation.

Network stream deserialisation.

Definition at line 524 of file wb_landmark_sighting.c.

References wb_landmark_sighting::direction, wb_landmark_sighting::distance, ntohl, ntohs, and wb_landmark_sighting::sightingType.

◆ wb_landmark_sighting_from_string()

◆ wb_landmark_sighting_to_network_serialised()

size_t wb_landmark_sighting_to_network_serialised ( const struct wb_landmark_sighting self,
char *  dst 
)

WHITEBOARD_POSTER_STRING_CONVERSION.

Network stream serialisation

WHITEBOARD_POSTER_STRING_CONVERSION.

Definition at line 471 of file wb_landmark_sighting.c.

References htonl, and htons.

◆ wb_landmark_sighting_to_string()