libDXF 0.0.1
A library with DXF related functions written in C.

polyline.h

Go to the documentation of this file.
00001 
00042 #ifndef LIBDXF_SRC_POLYLINE_H
00043 #define LIBDXF_SRC_POLYLINE_H
00044 
00045 
00046 #include "global.h"
00047 #include "binary_graphics_data.h"
00048 #include "vertex.h"
00049 #include "point.h"
00050 
00051 
00052 #ifdef __cplusplus
00053 extern "C" {
00054 #endif
00055 
00056 
00103 typedef struct
00104 dxf_polyline_struct
00105 {
00106         /* Members common for all DXF drawable entities. */
00107         int id_code;
00112         char *linetype;
00116         char *layer;
00120         double elevation;
00126         double thickness;
00130         double linetype_scale;
00134         int16_t visibility;
00142         int color;
00149         int paperspace;
00155         int graphics_data_size;
00164         int16_t shadow_mode;
00174         DxfBinaryGraphicsData *binary_graphics_data;
00180         char *dictionary_owner_soft;
00184         char *material;
00189         char *dictionary_owner_hard;
00193         int16_t lineweight;
00198         char *plot_style_name;
00202         long color_value;
00214         char *color_name;
00222         long transparency;
00230         /* Specific members for a DXF polyline. */
00231         DxfPoint *p0;
00236         double start_width;
00241         double end_width;
00246         int vertices_follow;
00253         int flag;
00267         int polygon_mesh_M_vertex_count;
00270         int polygon_mesh_N_vertex_count;
00273         int smooth_M_surface_density;
00276         int smooth_N_surface_density;
00279         int surface_type;
00287         double extr_x0;
00293         double extr_y0;
00296         double extr_z0;
00299         DxfVertex *vertices;
00304         struct DxfPolyline *next;
00307 } DxfPolyline;
00308 
00309 
00310 DxfPolyline *dxf_polyline_new ();
00311 DxfPolyline *dxf_polyline_init (DxfPolyline *polyline);
00312 DxfPolyline *dxf_polyline_read (DxfFile *fp, DxfPolyline *polyline);
00313 int dxf_polyline_write (DxfFile *fp, DxfPolyline *polyline);
00314 int dxf_polyline_free (DxfPolyline *polyline);
00315 void dxf_polyline_free_chain (DxfPolyline *polylines);
00316 int dxf_polyline_get_id_code (DxfPolyline *polyline);
00317 DxfPolyline *dxf_polyline_set_id_code (DxfPolyline *polyline, int id_code);
00318 char *dxf_polyline_get_linetype (DxfPolyline *polyline);
00319 DxfPolyline *dxf_polyline_set_linetype (DxfPolyline *polyline, char *linetype);
00320 char *dxf_polyline_get_layer (DxfPolyline *polyline);
00321 DxfPolyline *dxf_polyline_set_layer (DxfPolyline *polyline, char *layer);
00322 double dxf_polyline_get_elevation (DxfPolyline *polyline);
00323 DxfPolyline *dxf_polyline_set_elevation (DxfPolyline *polyline, double elevation);
00324 double dxf_polyline_get_thickness (DxfPolyline *polyline);
00325 DxfPolyline *dxf_polyline_set_thickness (DxfPolyline *polyline, double thickness);
00326 double dxf_polyline_get_linetype_scale (DxfPolyline *polyline);
00327 DxfPolyline *dxf_polyline_set_linetype_scale (DxfPolyline *polyline, double linetype_scale);
00328 int16_t dxf_polyline_get_visibility (DxfPolyline *polyline);
00329 DxfPolyline *dxf_polyline_set_visibility (DxfPolyline *polyline, int16_t visibility);
00330 int dxf_polyline_get_color (DxfPolyline *polyline);
00331 DxfPolyline *dxf_polyline_set_color (DxfPolyline *polyline, int color);
00332 int dxf_polyline_get_paperspace (DxfPolyline *polyline);
00333 DxfPolyline *dxf_polyline_set_paperspace (DxfPolyline *polyline, int paperspace);
00334 int dxf_polyline_get_graphics_data_size (DxfPolyline *polyline);
00335 DxfPolyline *dxf_polyline_set_graphics_data_size (DxfPolyline *polyline, int graphics_data_size);
00336 int16_t dxf_polyline_get_shadow_mode (DxfPolyline *polyline);
00337 DxfPolyline *dxf_polyline_set_shadow_mode (DxfPolyline *polyline, int16_t shadow_mode);
00338 DxfBinaryGraphicsData *dxf_polyline_get_binary_graphics_data (DxfPolyline *polyline);
00339 DxfPolyline *dxf_polyline_set_binary_graphics_data (DxfPolyline *polyline, DxfBinaryGraphicsData *data);
00340 char *dxf_polyline_get_dictionary_owner_soft (DxfPolyline *polyline);
00341 DxfPolyline *dxf_polyline_set_dictionary_owner_soft (DxfPolyline *polyline, char *dictionary_owner_soft);
00342 char *dxf_polyline_get_material (DxfPolyline *polyline);
00343 DxfPolyline *dxf_polyline_set_material (DxfPolyline *polyline, char *material);
00344 char *dxf_polyline_get_dictionary_owner_hard (DxfPolyline *polyline);
00345 DxfPolyline *dxf_polyline_set_dictionary_owner_hard (DxfPolyline *polyline, char *dictionary_owner_hard);
00346 int16_t dxf_polyline_get_lineweight (DxfPolyline *polyline);
00347 DxfPolyline *dxf_polyline_set_lineweight (DxfPolyline *polyline, int16_t lineweight);
00348 char *dxf_polyline_get_plot_style_name (DxfPolyline *polyline);
00349 DxfPolyline *dxf_polyline_set_plot_style_name (DxfPolyline *polyline, char *plot_style_name);
00350 long dxf_polyline_get_color_value (DxfPolyline *polyline);
00351 DxfPolyline *dxf_polyline_set_color_value (DxfPolyline *polyline, long color_value);
00352 char *dxf_polyline_get_color_name (DxfPolyline *polyline);
00353 DxfPolyline *dxf_polyline_set_color_name (DxfPolyline *polyline, char *color_name);
00354 long dxf_polyline_get_transparency (DxfPolyline *polyline);
00355 DxfPolyline *dxf_polyline_set_transparency (DxfPolyline *polyline, long transparency);
00356 DxfPoint *dxf_polyline_get_p0 (DxfPolyline *polyline);
00357 DxfPolyline *dxf_polyline_set_p0 (DxfPolyline *polyline, DxfPoint *p0);
00358 double dxf_polyline_get_x0 (DxfPolyline *polyline);
00359 DxfPolyline *dxf_polyline_set_x0 (DxfPolyline *polyline, double x0);
00360 double dxf_polyline_get_y0 (DxfPolyline *polyline);
00361 DxfPolyline *dxf_polyline_set_y0 (DxfPolyline *polyline, double y0);
00362 double dxf_polyline_get_z0 (DxfPolyline *polyline);
00363 DxfPolyline *dxf_polyline_set_z0 (DxfPolyline *polyline, double z0);
00364 double dxf_polyline_get_start_width (DxfPolyline *polyline);
00365 DxfPolyline *dxf_polyline_set_start_width (DxfPolyline *polyline, double start_width);
00366 double dxf_polyline_get_end_width (DxfPolyline *polyline);
00367 DxfPolyline *dxf_polyline_set_end_width (DxfPolyline *polyline, double end_width);
00368 int dxf_polyline_get_vertices_follow (DxfPolyline *polyline);
00369 DxfPolyline *dxf_polyline_set_vertices_follow (DxfPolyline *polyline, int vertices_follow);
00370 int dxf_polyline_get_flag (DxfPolyline *polyline);
00371 DxfPolyline *dxf_polyline_set_flag (DxfPolyline *polyline, int flag);
00372 int dxf_polyline_get_polygon_mesh_M_vertex_count (DxfPolyline *polyline);
00373 DxfPolyline *dxf_polyline_set_polygon_mesh_M_vertex_count (DxfPolyline *polyline, int polygon_mesh_M_vertex_count);
00374 int dxf_polyline_get_polygon_mesh_N_vertex_count (DxfPolyline *polyline);
00375 DxfPolyline *dxf_polyline_set_polygon_mesh_N_vertex_count (DxfPolyline *polyline, int polygon_mesh_N_vertex_count);
00376 int dxf_polyline_get_smooth_M_surface_density (DxfPolyline *polyline);
00377 DxfPolyline *dxf_polyline_set_smooth_M_surface_density (DxfPolyline *polyline, int smooth_M_surface_density);
00378 int dxf_polyline_get_smooth_N_surface_density (DxfPolyline *polyline);
00379 DxfPolyline *dxf_polyline_set_smooth_N_surface_density (DxfPolyline *polyline, int smooth_N_surface_density);
00380 int dxf_polyline_get_surface_type (DxfPolyline *polyline);
00381 DxfPolyline *dxf_polyline_set_surface_type (DxfPolyline *polyline, int surface_type);
00382 double dxf_polyline_get_extr_x0 (DxfPolyline *polyline);
00383 DxfPolyline *dxf_polyline_set_extr_x0 (DxfPolyline *polyline, double extr_x0);
00384 double dxf_polyline_get_extr_y0 (DxfPolyline *polyline);
00385 DxfPolyline *dxf_polyline_set_extr_y0 (DxfPolyline *polyline, double extr_y0);
00386 double dxf_polyline_get_extr_z0 (DxfPolyline *polyline);
00387 DxfPolyline *dxf_polyline_set_extr_z0 (DxfPolyline *polyline, double extr_z0);
00388 DxfVertex *dxf_polyline_get_vertices (DxfPolyline *polyline);
00389 DxfPolyline *dxf_polyline_set_vertices (DxfPolyline *polyline, DxfVertex *vertices);
00390 DxfPolyline *dxf_polyline_get_next (DxfPolyline *polyline);
00391 DxfPolyline *dxf_polyline_set_next (DxfPolyline *polyline, DxfPolyline *next);
00392 DxfPolyline *dxf_polyline_get_last (DxfPolyline *polyline);
00393 
00394 
00395 #ifdef __cplusplus
00396 }
00397 #endif
00398 
00399 
00400 #endif /* LIBDXF_SRC_POLYLINE_H */
00401 
00402 
00403 /* EOF */