#include "utils.h"#include "objects.h"#include "robot.h"#include "distances.h"#include "simulator.h"#include "objects_geometry.h"#include "lights.h"#include <cmath>#include "SDL2_gfxPrimitives.h"Functions | |
| Object * | object_factory (Simulation *simulation, uint16_t id, float x, float y, b2WorldId world_id, Configuration const &config, LightLevelMap *light_map, size_t userdatasize, std::string const &category) |
| Factory of simulation Objects. Return a constructed object from configuration. | |
| void | get_cmap_val (std::string const name, uint8_t const value, uint8_t *r, uint8_t *g, uint8_t *b) |
| Interface to colormaps. | |
| void get_cmap_val | ( | std::string const | name, |
| uint8_t const | value, | ||
| uint8_t * | r, | ||
| uint8_t * | g, | ||
| uint8_t * | b ) |
Interface to colormaps.
| name | Name of the colormap. |
| value | Value to determine the color in this colormap |
| r | Red color component |
| g | Green color component |
| b | Blue color component |
| Object * object_factory | ( | Simulation * | simulation, |
| uint16_t | id, | ||
| float | x, | ||
| float | y, | ||
| b2WorldId | world_id, | ||
| Configuration const & | config, | ||
| LightLevelMap * | light_map, | ||
| size_t | userdatasize = 0, | ||
| std::string const & | category = "objects" ) |
Factory of simulation Objects. Return a constructed object from configuration.
| simulation | Pointer to the underlying simulation. |
| world_id | The Box2D world identifier (unused in rendering). |
| config | Configuration entry describing the object properties. |
| light_map | Pointer to the global light level map. |
| userdatasize | Size of the memory block allocated for user data. |
| category | Name of the category of the object. |