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

ray.c File Reference

Functions for a DXF ray entity (RAY). More...

#include "ray.h"
Include dependency graph for ray.c:

Go to the source code of this file.

Functions

DxfRaydxf_ray_new ()
 Allocate memory for a DxfRay.
DxfRaydxf_ray_init (DxfRay *ray)
 Allocate memory and initialize data fields in an RAY entity.
DxfRaydxf_ray_read (DxfFile *fp, DxfRay *ray)
 Read data from a DXF file into an LINE entity.
int dxf_ray_write (DxfFile *fp, DxfRay *ray)
 Write DXF output to fp for a line entity.
int dxf_ray_free (DxfRay *ray)
 Free the allocated memory for a DXF RAY and all it's data fields.
void dxf_ray_free_chain (DxfRay *rays)
 Free the allocated memory for a chain of DXF RAY entities and all their data fields.
int dxf_ray_get_id_code (DxfRay *ray)
 Get the id_code from a DXF RAY entity.
DxfRaydxf_ray_set_id_code (DxfRay *ray, int id_code)
 Set the id_code for a DXF RAY entity.
char * dxf_ray_get_linetype (DxfRay *ray)
 Get the linetype from a DXF RAY entity.
DxfRaydxf_ray_set_linetype (DxfRay *ray, char *linetype)
 Set the linetype for a DXF RAY entity.
char * dxf_ray_get_layer (DxfRay *ray)
 Get the layer from a DXF RAY entity.
DxfRaydxf_ray_set_layer (DxfRay *ray, char *layer)
 Set the layer for a DXF RAY entity.
double dxf_ray_get_elevation (DxfRay *ray)
 Get the elevation from a DXF RAY entity.
DxfRaydxf_ray_set_elevation (DxfRay *ray, double elevation)
 Set the elevation for a DXF RAY entity.
double dxf_ray_get_thickness (DxfRay *ray)
 Get the thickness from a DXF RAY entity.
DxfRaydxf_ray_set_thickness (DxfRay *ray, double thickness)
 Set the thickness for a DXF RAY entity.
double dxf_ray_get_linetype_scale (DxfRay *ray)
 Get the linetype_scale from a DXF RAY entity.
DxfRaydxf_ray_set_linetype_scale (DxfRay *ray, double linetype_scale)
 Set the linetype_scale for a DXF RAY entity.
int16_t dxf_ray_get_visibility (DxfRay *ray)
 Get the visibility from a DXF RAY entity.
DxfRaydxf_ray_set_visibility (DxfRay *ray, int16_t visibility)
 Set the visibility for a DXF RAY entity.
int dxf_ray_get_color (DxfRay *ray)
 Get the color from a DXF RAY entity.
DxfRaydxf_ray_set_color (DxfRay *ray, int color)
 Set the color for a DXF RAY entity.
int dxf_ray_get_paperspace (DxfRay *ray)
 Get the paperspace flag value from a DXF RAY entity.
DxfRaydxf_ray_set_paperspace (DxfRay *ray, int paperspace)
 Set the paperspace flag for a DXF RAY entity.
int dxf_ray_get_graphics_data_size (DxfRay *ray)
 Get the graphics_data_size value from a DXF RAY entity.
DxfRaydxf_ray_set_graphics_data_size (DxfRay *ray, int graphics_data_size)
 Set the graphics_data_size value for a DXF RAY entity.
int16_t dxf_ray_get_shadow_mode (DxfRay *ray)
 Get the shadow_mode from a DXF RAY entity.
DxfRaydxf_ray_set_shadow_mode (DxfRay *ray, int16_t shadow_mode)
 Set the shadow_mode for a DXF RAY entity.
DxfBinaryGraphicsDatadxf_ray_get_binary_graphics_data (DxfRay *ray)
 Get the pointer to the binary_graphics_data from a DXF RAY entity.
DxfRaydxf_ray_set_binary_graphics_data (DxfRay *ray, DxfBinaryGraphicsData *data)
 Set the pointer to the binary_graphics_data for a DXF RAY entity.
char * dxf_ray_get_dictionary_owner_soft (DxfRay *ray)
 Get the pointer to the dictionary_owner_soft from a DXF RAY entity.
DxfRaydxf_ray_set_dictionary_owner_soft (DxfRay *ray, char *dictionary_owner_soft)
 Set the pointer to the dictionary_owner_soft for a DXF RAY entity.
char * dxf_ray_get_material (DxfRay *ray)
 Get the pointer to the material from a DXF RAY entity.
DxfRaydxf_ray_set_material (DxfRay *ray, char *material)
 Set the pointer to the material for a DXF RAY entity.
char * dxf_ray_get_dictionary_owner_hard (DxfRay *ray)
 Get the pointer to the dictionary_owner_hard from a DXF RAY entity.
DxfRaydxf_ray_set_dictionary_owner_hard (DxfRay *ray, char *dictionary_owner_hard)
 Set the pointer to the dictionary_owner_hard for a DXF RAY entity.
int16_t dxf_ray_get_lineweight (DxfRay *ray)
 Get the lineweight from a DXF RAY entity.
DxfRaydxf_ray_set_lineweight (DxfRay *ray, int16_t lineweight)
 Set the lineweight for a DXF RAY entity.
char * dxf_ray_get_plot_style_name (DxfRay *ray)
 Get the plot_style_name from a DXF RAY entity.
DxfRaydxf_ray_set_plot_style_name (DxfRay *ray, char *plot_style_name)
 Set the plot_style_name for a DXF RAY entity.
long dxf_ray_get_color_value (DxfRay *ray)
 Get the color_value from a DXF RAY entity.
DxfRaydxf_ray_set_color_value (DxfRay *ray, long color_value)
 Set the color_value for a DXF RAY entity.
char * dxf_ray_get_color_name (DxfRay *ray)
 Get the color_name from a DXF RAY entity.
DxfRaydxf_ray_set_color_name (DxfRay *ray, char *color_name)
 Set the color_name for a DXF RAY entity.
long dxf_ray_get_transparency (DxfRay *ray)
 Get the transparency from a DXF RAY entity.
DxfRaydxf_ray_set_transparency (DxfRay *ray, long transparency)
 Set the transparency for a DXF RAY entity.
DxfPointdxf_ray_get_p0 (DxfRay *ray)
 Get the start point p0 of a DXF RAY entity.
DxfRaydxf_ray_set_p0 (DxfRay *ray, DxfPoint *p0)
 Set the start point p0 of a DXF RAY entity.
double dxf_ray_get_x0 (DxfRay *ray)
 Get the X-value of the start point x0 of a DXF RAY entity.
DxfRaydxf_ray_set_x0 (DxfRay *ray, double x0)
 Set the X-value of the start point x0 of a DXF RAY entity.
double dxf_ray_get_y0 (DxfRay *ray)
 Get the Y-value of the start point y0 of a DXF RAY entity.
DxfRaydxf_ray_set_y0 (DxfRay *ray, double y0)
 Set the Y-value of the start point y0 of a DXF RAY entity.
double dxf_ray_get_z0 (DxfRay *ray)
 Get the Z-value of the start point z0 of a DXF RAY entity.
DxfRaydxf_ray_set_z0 (DxfRay *ray, double z0)
 Set the Z-value of the start point z0 of a DXF RAY entity.
DxfPointdxf_ray_get_p1 (DxfRay *ray)
 Get the end point p1 of a DXF RAY entity.
DxfRaydxf_ray_set_p1 (DxfRay *ray, DxfPoint *p1)
 Set the end point p1 of a DXF RAY entity.
double dxf_ray_get_x1 (DxfRay *ray)
 Get the X-value of the end point x1 of a DXF RAY entity.
DxfRaydxf_ray_set_x1 (DxfRay *ray, double x1)
 Set the X-value of the end point x1 of a DXF RAY entity.
double dxf_ray_get_y1 (DxfRay *ray)
 Get the Y-value of the end point y1 of a DXF RAY entity.
DxfRaydxf_ray_set_y1 (DxfRay *ray, double y1)
 Set the Y-value of the end point y1 of a DXF RAY entity.
double dxf_ray_get_z1 (DxfRay *ray)
 Get the Z-value of the end point z1 of a DXF RAY entity.
DxfRaydxf_ray_set_z1 (DxfRay *ray, double z1)
 Set the Z-value of the end point z1 of a DXF RAY entity.
DxfRaydxf_ray_get_next (DxfRay *ray)
 Get the pointer to the next RAY entity from a DXF RAY entity.
DxfRaydxf_ray_set_next (DxfRay *ray, DxfRay *next)
 Set the pointer to the next RAY for a DXF RAY entity.
DxfRaydxf_ray_get_last (DxfRay *ray)
 Get the pointer to the last RAY entity from a linked list of DXF RAY entities.

Detailed Description

Functions for a DXF ray entity (RAY).

Author:
Copyright (C) 2013, 2014, 2015, 2017 by Bert Timmerman <bert.timmerman@xs4all.nl>.
Since:
The ray entity was introduced in DXF version R13.
Version:
According to DXF R10 (backward compatibility).
According to DXF R11 (backward compatibility).
According to DXF R12 (backward compatibility).
According to DXF R13.
According to DXF R14.

Copyright Notices.


This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to:
Free Software Foundation, Inc.,
59 Temple Place,
Suite 330,
Boston,
MA 02111 USA.

Drawing eXchange Format (DXF) is a defacto industry standard for the exchange of drawing files between various Computer Aided Drafting programs.
DXF is an industry standard designed by Autodesk(TM).
For more details see http://www.autodesk.com .


Definition in file ray.c.


Function Documentation

DxfRay* dxf_ray_new ( )

Allocate memory for a DxfRay.

Fill the memory contents with zeros.

Returns:
NULL when no memory was allocated, a pointer to the allocated memory when succesful.

Definition at line 55 of file ray.c.

References _, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

Referenced by dxf_ray_init(), and dxf_ray_read().

DxfRay* dxf_ray_init ( DxfRay ray)
DxfRay* dxf_ray_read ( DxfFile fp,
DxfRay ray 
)

Read data from a DXF file into an LINE entity.

The last line read from file contained the string "LINE".
Now follows some data for the LINE, to be terminated with a " 0" string announcing the following entity, or the end of the ENTITY section marker ENDSEC.
While parsing the DXF file store data in ray.

Returns:
EXIT_SUCCESS when done, or EXIT_FAILURE when an error occurred.
Parameters:
fpDXF file pointer to an input file (or device).
raya pointer to the DXF RAY entity.

Definition at line 168 of file ray.c.

References _, dxf_file_struct::acad_version_number, AutoCAD_11, AutoCAD_13, dxf_ray_struct::color, dxf_ray_struct::dictionary_owner_hard, dxf_ray_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, DXF_DEBUG_END, DXF_DEFAULT_LAYER, DXF_DEFAULT_LINETYPE, dxf_ray_init(), dxf_ray_new(), dxf_ray_struct::elevation, dxf_file_struct::filename, dxf_file_struct::fp, dxf_ray_struct::id_code, dxf_ray_struct::layer, dxf_file_struct::line_number, dxf_ray_struct::linetype, dxf_ray_struct::linetype_scale, dxf_ray_struct::p0, dxf_ray_struct::p1, dxf_ray_struct::paperspace, dxf_ray_struct::thickness, dxf_ray_struct::visibility, dxf_point_struct::x0, dxf_point_struct::y0, and dxf_point_struct::z0.

Here is the call graph for this function:

int dxf_ray_write ( DxfFile fp,
DxfRay ray 
)

Write DXF output to fp for a line entity.

Returns:
EXIT_SUCCESS when done, or EXIT_FAILURE when an error occured.

Todo:
for version R14.
Implementing the start of application-defined group "{application_name", with Group code 102.
For example: "{ACAD_REACTORS" indicates the start of the AutoCAD persistent reactors group.

application-defined codes: Group codes and values within the 102 groups are application defined (optional).

End of group, "}" (optional), with Group code 102.

Parameters:
fpDXF file pointer to an output file (or device).
raya pointer to the DXF RAY entity.

Definition at line 387 of file ray.c.

References _, dxf_file_struct::acad_version_number, AutoCAD_11, AutoCAD_13, AutoCAD_14, dxf_ray_struct::color, dxf_ray_struct::dictionary_owner_hard, dxf_ray_struct::dictionary_owner_soft, DXF_COLOR_BYLAYER, DXF_DEBUG_BEGIN, DXF_DEBUG_END, DXF_DEFAULT_LAYER, DXF_DEFAULT_LINETYPE, dxf_entity_skip(), DXF_FLATLAND, DXF_PAPERSPACE, dxf_ray_struct::elevation, dxf_file_struct::fp, dxf_ray_struct::id_code, dxf_ray_struct::layer, dxf_ray_struct::linetype, dxf_ray_struct::linetype_scale, dxf_ray_struct::p0, dxf_ray_struct::p1, dxf_ray_struct::paperspace, dxf_ray_struct::thickness, dxf_ray_struct::visibility, dxf_point_struct::x0, dxf_point_struct::y0, and dxf_point_struct::z0.

Here is the call graph for this function:

int dxf_ray_free ( DxfRay ray)

Free the allocated memory for a DXF RAY and all it's data fields.

Returns:
EXIT_SUCCESS when done, or EXIT_FAILURE when an error occurred.
Parameters:
raya pointer to the memory occupied by the DXF RAY entity.

Definition at line 549 of file ray.c.

References _, dxf_ray_struct::dictionary_owner_hard, dxf_ray_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_point_free(), dxf_ray_struct::layer, dxf_ray_struct::linetype, dxf_ray_struct::next, dxf_ray_struct::p0, and dxf_ray_struct::p1.

Referenced by dxf_ray_free_chain().

Here is the call graph for this function:

void dxf_ray_free_chain ( DxfRay rays)

Free the allocated memory for a chain of DXF RAY entities and all their data fields.

Parameters:
raysa pointer to the chain of DXF RAY entities.

Definition at line 594 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_free(), and dxf_ray_struct::next.

Here is the call graph for this function:

int dxf_ray_get_id_code ( DxfRay ray)

Get the id_code from a DXF RAY entity.

Returns:
id_code.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 627 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::id_code.

DxfRay* dxf_ray_set_id_code ( DxfRay ray,
int  id_code 
)

Set the id_code for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
id_codethe id_code to be set for the entity.
This is to be an unique (sequential) number in the DXF file.

Definition at line 661 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::id_code.

char* dxf_ray_get_linetype ( DxfRay ray)

Get the linetype from a DXF RAY entity.

Returns:
linetype when sucessful, NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 702 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::linetype.

DxfRay* dxf_ray_set_linetype ( DxfRay ray,
char *  linetype 
)

Set the linetype for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
linetypea pointer to a string containing the linetype to be set for the entity.

Definition at line 737 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::linetype.

char* dxf_ray_get_layer ( DxfRay ray)

Get the layer from a DXF RAY entity.

Returns:
layer when sucessful, NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 778 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::layer.

DxfRay* dxf_ray_set_layer ( DxfRay ray,
char *  layer 
)

Set the layer for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
layera pointer to a string containing the layer to be set for the entity.

Definition at line 813 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::layer.

double dxf_ray_get_elevation ( DxfRay ray)

Get the elevation from a DXF RAY entity.

Returns:
elevation.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 854 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::elevation.

DxfRay* dxf_ray_set_elevation ( DxfRay ray,
double  elevation 
)

Set the elevation for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
elevationthe elevation to be set for the entity.

Definition at line 882 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::elevation.

double dxf_ray_get_thickness ( DxfRay ray)

Get the thickness from a DXF RAY entity.

Returns:
thickness.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 915 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::thickness.

DxfRay* dxf_ray_set_thickness ( DxfRay ray,
double  thickness 
)

Set the thickness for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
thicknessthe thickness to be set for the entity.

Definition at line 950 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::thickness.

double dxf_ray_get_linetype_scale ( DxfRay ray)

Get the linetype_scale from a DXF RAY entity.

Returns:
linetype_scale.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 990 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::linetype_scale.

DxfRay* dxf_ray_set_linetype_scale ( DxfRay ray,
double  linetype_scale 
)

Set the linetype_scale for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
linetype_scalethe linetype_scale to be set for the entity.

Definition at line 1025 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::linetype_scale.

int16_t dxf_ray_get_visibility ( DxfRay ray)

Get the visibility from a DXF RAY entity.

Returns:
visibility.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1065 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::visibility.

DxfRay* dxf_ray_set_visibility ( DxfRay ray,
int16_t  visibility 
)

Set the visibility for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
visibilitythe visibility to be set for the entity.

Definition at line 1107 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::visibility.

int dxf_ray_get_color ( DxfRay ray)

Get the color from a DXF RAY entity.

Returns:
color.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1154 of file ray.c.

References _, dxf_ray_struct::color, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

DxfRay* dxf_ray_set_color ( DxfRay ray,
int  color 
)

Set the color for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
colorthe color to be set for the entity.

Definition at line 1188 of file ray.c.

References _, dxf_ray_struct::color, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

int dxf_ray_get_paperspace ( DxfRay ray)

Get the paperspace flag value from a DXF RAY entity.

Returns:
paperspace flag value.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1227 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::paperspace.

DxfRay* dxf_ray_set_paperspace ( DxfRay ray,
int  paperspace 
)

Set the paperspace flag for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
paperspacethe paperspace flag value to be set for the entity.

Definition at line 1267 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::paperspace.

int dxf_ray_get_graphics_data_size ( DxfRay ray)

Get the graphics_data_size value from a DXF RAY entity.

Returns:
graphics_data_size value when successful, or EXIT_FAILURE when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1316 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::graphics_data_size.

DxfRay* dxf_ray_set_graphics_data_size ( DxfRay ray,
int  graphics_data_size 
)

Set the graphics_data_size value for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
graphics_data_sizethe graphics_data_size value to be set for the entity.

Definition at line 1359 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::graphics_data_size.

int16_t dxf_ray_get_shadow_mode ( DxfRay ray)

Get the shadow_mode from a DXF RAY entity.

Returns:
shadow_mode when successful, or EXIT_FAILURE when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1407 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::shadow_mode.

DxfRay* dxf_ray_set_shadow_mode ( DxfRay ray,
int16_t  shadow_mode 
)

Set the shadow_mode for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
shadow_modethe shadow_mode to be set for the entity.

Definition at line 1452 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::shadow_mode.

DxfBinaryGraphicsData* dxf_ray_get_binary_graphics_data ( DxfRay ray)

Get the pointer to the binary_graphics_data from a DXF RAY entity.

Returns:
pointer to the binary_graphics_data.
Warning:
No checks are performed on the returned pointer.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1502 of file ray.c.

References _, dxf_ray_struct::binary_graphics_data, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

DxfRay* dxf_ray_set_binary_graphics_data ( DxfRay ray,
DxfBinaryGraphicsData data 
)

Set the pointer to the binary_graphics_data for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
dataa string containing the pointer to the binary_graphics_data for the entity.

Definition at line 1538 of file ray.c.

References _, dxf_ray_struct::binary_graphics_data, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

char* dxf_ray_get_dictionary_owner_soft ( DxfRay ray)

Get the pointer to the dictionary_owner_soft from a DXF RAY entity.

Returns:
pointer to the dictionary_owner_soft.
Warning:
No checks are performed on the returned pointer (string).
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1582 of file ray.c.

References _, dxf_ray_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

DxfRay* dxf_ray_set_dictionary_owner_soft ( DxfRay ray,
char *  dictionary_owner_soft 
)

Set the pointer to the dictionary_owner_soft for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
dictionary_owner_softa string containing the pointer to the dictionary_owner_soft for the entity.

Definition at line 1618 of file ray.c.

References _, dxf_ray_struct::dictionary_owner_soft, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

char* dxf_ray_get_material ( DxfRay ray)

Get the pointer to the material from a DXF RAY entity.

Returns:
a pointer to material when successful, or NULL when an error occurred.
Warning:
No checks are performed on the returned pointer.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1662 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::material.

DxfRay* dxf_ray_set_material ( DxfRay ray,
char *  material 
)

Set the pointer to the material for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
materiala string containing the pointer to the material for the entity.

Definition at line 1700 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::material.

char* dxf_ray_get_dictionary_owner_hard ( DxfRay ray)

Get the pointer to the dictionary_owner_hard from a DXF RAY entity.

Returns:
pointer to the dictionary_owner_hard.
Warning:
No checks are performed on the returned pointer (string).
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1744 of file ray.c.

References _, dxf_ray_struct::dictionary_owner_hard, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

DxfRay* dxf_ray_set_dictionary_owner_hard ( DxfRay ray,
char *  dictionary_owner_hard 
)

Set the pointer to the dictionary_owner_hard for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
dictionary_owner_harda string containing the pointer to the dictionary_owner_hard for the entity.

Definition at line 1780 of file ray.c.

References _, dxf_ray_struct::dictionary_owner_hard, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

int16_t dxf_ray_get_lineweight ( DxfRay ray)

Get the lineweight from a DXF RAY entity.

Returns:
lineweight when successful, or EXIT_FAILURE when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1822 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::lineweight.

DxfRay* dxf_ray_set_lineweight ( DxfRay ray,
int16_t  lineweight 
)

Set the lineweight for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
lineweightthe lineweight to be set for the entity.

Definition at line 1853 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::lineweight.

char* dxf_ray_get_plot_style_name ( DxfRay ray)

Get the plot_style_name from a DXF RAY entity.

Returns:
a pointer to plot_style_name when sucessful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1887 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::plot_style_name.

DxfRay* dxf_ray_set_plot_style_name ( DxfRay ray,
char *  plot_style_name 
)

Set the plot_style_name for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
plot_style_namea string containing the plot_style_name for the entity.

Definition at line 1925 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::plot_style_name.

long dxf_ray_get_color_value ( DxfRay ray)

Get the color_value from a DXF RAY entity.

Returns:
color_value when successful, or EXIT_FAILURE when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 1967 of file ray.c.

References _, dxf_ray_struct::color_value, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

DxfRay* dxf_ray_set_color_value ( DxfRay ray,
long  color_value 
)

Set the color_value for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
color_valuethe color_value to be set for the entity.

Definition at line 1998 of file ray.c.

References _, dxf_ray_struct::color_value, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

char* dxf_ray_get_color_name ( DxfRay ray)

Get the color_name from a DXF RAY entity.

Returns:
color_name when sucessful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2032 of file ray.c.

References _, dxf_ray_struct::color_name, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

DxfRay* dxf_ray_set_color_name ( DxfRay ray,
char *  color_name 
)

Set the color_name for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
color_namea string containing the color_name for the entity.

Definition at line 2070 of file ray.c.

References _, dxf_ray_struct::color_name, DXF_DEBUG_BEGIN, and DXF_DEBUG_END.

long dxf_ray_get_transparency ( DxfRay ray)

Get the transparency from a DXF RAY entity.

Returns:
transparency when successful, or EXIT_FAILURE when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2112 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::transparency.

DxfRay* dxf_ray_set_transparency ( DxfRay ray,
long  transparency 
)

Set the transparency for a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
transparencythe transparency to be set for the entity.

Definition at line 2143 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::transparency.

DxfPoint* dxf_ray_get_p0 ( DxfRay ray)

Get the start point p0 of a DXF RAY entity.

Returns:
the start point p0.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2176 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::p0.

DxfRay* dxf_ray_set_p0 ( DxfRay ray,
DxfPoint p0 
)

Set the start point p0 of a DXF RAY entity.

Returns:
a pointer to a DXF RAY entity.
Parameters:
raya pointer to a DXF RAY entity.
p0a pointer to a DXF POINT entity.

Definition at line 2213 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::p0.

double dxf_ray_get_x0 ( DxfRay ray)

Get the X-value of the start point x0 of a DXF RAY entity.

Returns:
the X-value of the start point x0.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2254 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p0, and dxf_point_struct::x0.

DxfRay* dxf_ray_set_x0 ( DxfRay ray,
double  x0 
)

Set the X-value of the start point x0 of a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
x0the X-value of the start point x0 of a DXF RAY entity.

Definition at line 2294 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p0, and dxf_point_struct::x0.

double dxf_ray_get_y0 ( DxfRay ray)

Get the Y-value of the start point y0 of a DXF RAY entity.

Returns:
the Y-value of the start point y0.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2336 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p0, and dxf_point_struct::y0.

DxfRay* dxf_ray_set_y0 ( DxfRay ray,
double  y0 
)

Set the Y-value of the start point y0 of a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
y0the Y-value of the start point y0 of a DXF RAY entity.

Definition at line 2376 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p0, and dxf_point_struct::y0.

double dxf_ray_get_z0 ( DxfRay ray)

Get the Z-value of the start point z0 of a DXF RAY entity.

Returns:
the Z-value of the start point z0.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2418 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p0, and dxf_point_struct::z0.

DxfRay* dxf_ray_set_z0 ( DxfRay ray,
double  z0 
)

Set the Z-value of the start point z0 of a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
z0the Z-value of the start point z0 of a DXF RAY entity.

Definition at line 2458 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p0, and dxf_point_struct::z0.

DxfPoint* dxf_ray_get_p1 ( DxfRay ray)

Get the end point p1 of a DXF RAY entity.

Returns:
the end point p0.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2499 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::p1.

DxfRay* dxf_ray_set_p1 ( DxfRay ray,
DxfPoint p1 
)

Set the end point p1 of a DXF RAY entity.

Returns:
a pointer to a DXF RAY entity.
Parameters:
raya pointer to a DXF RAY entity.
p1a pointer to a DXF POINT entity.

Definition at line 2536 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::p1.

double dxf_ray_get_x1 ( DxfRay ray)

Get the X-value of the end point x1 of a DXF RAY entity.

Returns:
the X-value of the end point x1.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2577 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p1, and dxf_point_struct::x0.

DxfRay* dxf_ray_set_x1 ( DxfRay ray,
double  x1 
)

Set the X-value of the end point x1 of a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
x1the X-value of the end point x1 of a DXF RAY entity.

Definition at line 2617 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p1, and dxf_point_struct::x0.

double dxf_ray_get_y1 ( DxfRay ray)

Get the Y-value of the end point y1 of a DXF RAY entity.

Returns:
the Y-value of the end point y1.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2659 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p1, and dxf_point_struct::y0.

DxfRay* dxf_ray_set_y1 ( DxfRay ray,
double  y1 
)

Set the Y-value of the end point y1 of a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
y1the Y-value of the end point y1 of a DXF RAY entity.

Definition at line 2699 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p1, and dxf_point_struct::y0.

double dxf_ray_get_z1 ( DxfRay ray)

Get the Z-value of the end point z1 of a DXF RAY entity.

Returns:
the Z-value of the end point z1.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2741 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p1, and dxf_point_struct::z0.

DxfRay* dxf_ray_set_z1 ( DxfRay ray,
double  z1 
)

Set the Z-value of the end point z1 of a DXF RAY entity.

Returns:
a pointer to ray when successful, or NULL when an error occurred.
Parameters:
raya pointer to a DXF RAY entity.
z1the Z-value of the end point z1 of a DXF RAY entity.

Definition at line 2781 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, dxf_ray_struct::p1, and dxf_point_struct::z0.

DxfRay* dxf_ray_get_next ( DxfRay ray)

Get the pointer to the next RAY entity from a DXF RAY entity.

Returns:
pointer to the next RAY entity.
Warning:
No checks are performed on the returned pointer.
Parameters:
raya pointer to a DXF ARC entity.

Definition at line 2825 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::next.

DxfRay* dxf_ray_set_next ( DxfRay ray,
DxfRay next 
)

Set the pointer to the next RAY for a DXF RAY entity.

Parameters:
raya pointer to a DXF RAY entity.
nexta pointer to the next RAY for the entity.

Definition at line 2861 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::next.

DxfRay* dxf_ray_get_last ( DxfRay ray)

Get the pointer to the last RAY entity from a linked list of DXF RAY entities.

Returns:
pointer to the last RAY entity.
Warning:
No checks are performed on the returned pointer.
Parameters:
raya pointer to a DXF RAY entity.

Definition at line 2904 of file ray.c.

References _, DXF_DEBUG_BEGIN, DXF_DEBUG_END, and dxf_ray_struct::next.