|
gusimplewhiteboard
|
#include "wb_pixel_to_robot_relative_coord.h"#include <stdio.h>#include <string.h>#include <stdlib.h>#include <ctype.h>#include <limits.h>Go to the source code of this file.
Macros | |
| #define | htonll(x) bswap_64(x) |
| #define | ntohll(x) bswap_64(x) |
| #define | htonl(x) bswap_32(x) |
| #define | ntohl(x) bswap_32(x) |
| #define | htons(x) bswap_16(x) |
| #define | ntohs(x) bswap_16(x) |
Functions | |
| void | pixel_to_rr_coord (int32_t sx, int32_t sy, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, double *distance, double *angle) |
| void | pixel_to_rr_coord_legs (int32_t sx, int32_t sy, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, struct wb_sensors_legjointsensors *leg_sensors, double *distance, double *angle) |
| void | pixel_to_rr_coord_legs_no_conv (int32_t sx, int32_t sy, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, struct wb_sensors_legjointsensors *leg_sensors, double *distance, double *angle) |
| void | pixel_to_rr_coord_no_conv (int32_t sx, int32_t sy, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, double *distance, double *angle) |
| void | pixel_to_rr_coord_kneeling (int32_t sx, int32_t sy, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, double *distance, double *angle, bool kneeling) |
| void | pixel_to_rr_coord_kneeling_conv (int32_t sx, int32_t sy, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, double *distance, double *angle, bool kneeling, bool conv) |
| void | rr_to_pixel_coord (double angle, double distance, enum VisionCamera camera, struct wb_vision_control_status *vs, struct wb_sensors_torsojointsensors *joints, int32_t *sx, int32_t *sy, bool kneeling) |
| double | get_camera_height (enum VisionCamera camera, struct wb_sensors_torsojointsensors *joints, bool kneeling) |
| const char * | wb_pixel_to_robot_relative_coord_description (const struct wb_pixel_to_robot_relative_coord *self, char *descString, size_t bufferSize) |
| Convert to a description string. More... | |
| const char * | wb_pixel_to_robot_relative_coord_to_string (const struct wb_pixel_to_robot_relative_coord *self, char *toString, size_t bufferSize) |
| Convert to a string. More... | |
| struct wb_pixel_to_robot_relative_coord * | wb_pixel_to_robot_relative_coord_from_string (struct wb_pixel_to_robot_relative_coord *self, const char *str) |
| Convert from a string. More... | |
| size_t | wb_pixel_to_robot_relative_coord_to_network_serialised (const struct wb_pixel_to_robot_relative_coord *self, char *dst) |
| Convert to a compressed, serialised, network byte order byte stream. More... | |
| size_t | wb_pixel_to_robot_relative_coord_from_network_serialised (const char *src, struct wb_pixel_to_robot_relative_coord *dst) |
| Convert from a compressed, serialised, network byte order byte stream. More... | |
| #define htonl | ( | x | ) | bswap_32(x) |
Definition at line 97 of file wb_pixel_to_robot_relative_coord.c.
| #define htonll | ( | x | ) | bswap_64(x) |
Definition at line 93 of file wb_pixel_to_robot_relative_coord.c.
| #define htons | ( | x | ) | bswap_16(x) |
Definition at line 101 of file wb_pixel_to_robot_relative_coord.c.
| #define ntohl | ( | x | ) | bswap_32(x) |
Definition at line 98 of file wb_pixel_to_robot_relative_coord.c.
| #define ntohll | ( | x | ) | bswap_64(x) |
Definition at line 94 of file wb_pixel_to_robot_relative_coord.c.
| #define ntohs | ( | x | ) | bswap_16(x) |
Definition at line 102 of file wb_pixel_to_robot_relative_coord.c.
| double get_camera_height | ( | enum VisionCamera | camera, |
| struct wb_sensors_torsojointsensors * | joints, | ||
| bool | kneeling | ||
| ) |
Definition at line 207 of file wb_pixel_to_robot_relative_coord.c.
References BOTTOM_CAMERA_OFFSET_X, BOTTOM_CAMERA_OFFSET_Z, HEAD_BASE_HEIGHT, HEAD_BASE_HEIGHT_KNEELING, wb_sensors_torsojointsensors::HeadPitch, TOP_CAMERA_OFFSET_X, and TOP_CAMERA_OFFSET_Z.
Referenced by pixel_to_rr_coord_kneeling_conv(), and rr_to_pixel_coord().
| void pixel_to_rr_coord | ( | int32_t | sx, |
| int32_t | sy, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| double * | distance, | ||
| double * | angle | ||
| ) |
Definition at line 127 of file wb_pixel_to_robot_relative_coord.c.
References pixel_to_rr_coord_kneeling().
| void pixel_to_rr_coord_kneeling | ( | int32_t | sx, |
| int32_t | sy, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| double * | distance, | ||
| double * | angle, | ||
| bool | kneeling | ||
| ) |
Definition at line 143 of file wb_pixel_to_robot_relative_coord.c.
References pixel_to_rr_coord_kneeling_conv().
Referenced by pixel_to_rr_coord(), and pixel_to_rr_coord_legs().
| void pixel_to_rr_coord_kneeling_conv | ( | int32_t | sx, |
| int32_t | sy, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| double * | distance, | ||
| double * | angle, | ||
| bool | kneeling, | ||
| bool | conv | ||
| ) |
Definition at line 147 of file wb_pixel_to_robot_relative_coord.c.
References BOTTOM_CAMERA_ANGLE, CAMERA_HFOV, CAMERA_VFOV, CONV_TO_IMG, get_camera_height(), wb_sensors_torsojointsensors::HeadPitch, wb_sensors_torsojointsensors::HeadYaw, and TOP_CAMERA_ANGLE.
Referenced by pixel_to_rr_coord_kneeling(), pixel_to_rr_coord_legs_no_conv(), and pixel_to_rr_coord_no_conv().
| void pixel_to_rr_coord_legs | ( | int32_t | sx, |
| int32_t | sy, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| struct wb_sensors_legjointsensors * | leg_sensors, | ||
| double * | distance, | ||
| double * | angle | ||
| ) |
Definition at line 131 of file wb_pixel_to_robot_relative_coord.c.
References wb_sensors_legjointsensors::LKneePitch, pixel_to_rr_coord_kneeling(), and wb_sensors_legjointsensors::RKneePitch.
| void pixel_to_rr_coord_legs_no_conv | ( | int32_t | sx, |
| int32_t | sy, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| struct wb_sensors_legjointsensors * | leg_sensors, | ||
| double * | distance, | ||
| double * | angle | ||
| ) |
Definition at line 135 of file wb_pixel_to_robot_relative_coord.c.
References wb_sensors_legjointsensors::LKneePitch, pixel_to_rr_coord_kneeling_conv(), and wb_sensors_legjointsensors::RKneePitch.
| void pixel_to_rr_coord_no_conv | ( | int32_t | sx, |
| int32_t | sy, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| double * | distance, | ||
| double * | angle | ||
| ) |
Definition at line 139 of file wb_pixel_to_robot_relative_coord.c.
References pixel_to_rr_coord_kneeling_conv().
| void rr_to_pixel_coord | ( | double | angle, |
| double | distance, | ||
| enum VisionCamera | camera, | ||
| struct wb_vision_control_status * | vs, | ||
| struct wb_sensors_torsojointsensors * | joints, | ||
| int32_t * | sx, | ||
| int32_t * | sy, | ||
| bool | kneeling | ||
| ) |
Definition at line 184 of file wb_pixel_to_robot_relative_coord.c.
References BOTTOM_CAMERA_ANGLE, CAMERA_HFOV, CAMERA_VFOV, get_camera_height(), wb_sensors_torsojointsensors::HeadPitch, wb_sensors_torsojointsensors::HeadYaw, and TOP_CAMERA_ANGLE.
| const char * wb_pixel_to_robot_relative_coord_description | ( | const struct wb_pixel_to_robot_relative_coord * | self, |
| char * | descString, | ||
| size_t | bufferSize | ||
| ) |
Convert to a description string.
Definition at line 225 of file wb_pixel_to_robot_relative_coord.c.
Referenced by guWhiteboard::PixelToRobotRelativeCoord::description().
| size_t wb_pixel_to_robot_relative_coord_from_network_serialised | ( | const char * | src, |
| struct wb_pixel_to_robot_relative_coord * | dst | ||
| ) |
Convert from a compressed, serialised, network byte order byte stream.
Network stream deserialisation.
Definition at line 378 of file wb_pixel_to_robot_relative_coord.c.
References wb_pixel_to_robot_relative_coord::i, and ntohl.
| struct wb_pixel_to_robot_relative_coord * wb_pixel_to_robot_relative_coord_from_string | ( | struct wb_pixel_to_robot_relative_coord * | self, |
| const char * | str | ||
| ) |
Convert from a string.
Definition at line 257 of file wb_pixel_to_robot_relative_coord.c.
References wb_pixel_to_robot_relative_coord::i, and PIXEL_TO_ROBOT_RELATIVE_COORD_DESC_BUFFER_SIZE.
| size_t wb_pixel_to_robot_relative_coord_to_network_serialised | ( | const struct wb_pixel_to_robot_relative_coord * | self, |
| char * | dst | ||
| ) |
Convert to a compressed, serialised, network byte order byte stream.
WHITEBOARD_POSTER_STRING_CONVERSION.
Definition at line 353 of file wb_pixel_to_robot_relative_coord.c.
References htonl.
| const char * wb_pixel_to_robot_relative_coord_to_string | ( | const struct wb_pixel_to_robot_relative_coord * | self, |
| char * | toString, | ||
| size_t | bufferSize | ||
| ) |
Convert to a string.
Definition at line 241 of file wb_pixel_to_robot_relative_coord.c.
Referenced by guWhiteboard::PixelToRobotRelativeCoord::to_string().