35#ifndef TCOD_BRESENHAM_H_
36#define TCOD_BRESENHAM_H_
73TCODLIB_API TCOD_DEPRECATED(
"This function is not reentrant. Use TCOD_line_init_mt instead.") void
TCOD_line_init(
74 int xFrom,
int yFrom,
int xTo,
int yTo);
93TCODLIB_API TCOD_DEPRECATED(
"This function is not reentrant.")
bool TCOD_line_step(
94 int* __restrict xCur,
int* __restrict yCur);
167TCOD_DEPRECATED(
"Use TCOD_line instead.")
bool TCOD_line_step(int *xCur, int *yCur)
Advance to the next point in a line, returns true once the line has ended.
bool(* TCOD_line_listener_t)(int x, int y)
A callback to be passed to TCOD_line.
Definition bresenham.h:56
void TCOD_line_init(int xFrom, int yFrom, int xTo, int yTo)
Initialize a line using a global state.
bool TCOD_line(int xFrom, int yFrom, int xTo, int yTo, TCOD_line_listener_t listener)
Iterate over a line using a callback.
void TCOD_line_init_mt(int xFrom, int yFrom, int xTo, int yTo, TCOD_bresenham_data_t *data)
Initialize a TCOD_bresenham_data_t struct.
bool TCOD_line_mt(int xFrom, int yFrom, int xTo, int yTo, TCOD_line_listener_t listener, TCOD_bresenham_data_t *data)
Iterate over a line using a callback.
bool TCOD_line_step_mt(int *xCur, int *yCur, TCOD_bresenham_data_t *data)
Get the next point on a line, returns true once the line has ended.
Miscellaneous tools needed across platforms.
A struct used for computing a bresenham line.
Definition bresenham.h:114