mirror of
git://projects.qi-hardware.com/cae-tools.git
synced 2024-12-23 04:13:20 +02:00
29 lines
539 B
C
29 lines
539 B
C
#ifndef PATH_H
|
|
#define PATH_H
|
|
|
|
#include <stdio.h>
|
|
|
|
|
|
struct vertex {
|
|
double x, y;
|
|
double r; /* minimum bend radius; 0 = use previous value */
|
|
double d; /* max. distance of corner from ideal arc; 0 = prev */
|
|
const char *tag;
|
|
struct vertex *next;
|
|
};
|
|
|
|
struct path {
|
|
struct vertex *vertices;
|
|
struct vertex **last;
|
|
};
|
|
|
|
|
|
void free_path(struct path *path);
|
|
|
|
struct path *round_path(const struct path *path, double r, double d);
|
|
|
|
struct path *load_path(FILE *file);
|
|
void save_path(FILE *file, const struct path *path);
|
|
|
|
#endif /* !PATH_H */
|