Add vertex simplification to parser
* Duplicate / Redundant vertices of polygons are now removed during parsing. * Implications: Reduced output size of tex document, faster rendering.
This commit is contained in:
@@ -35,7 +35,7 @@
|
||||
|
||||
#include <gds-render/gds-utils/gds-types.h>
|
||||
|
||||
#define GDS_PRINT_DEBUG_INFOS (0) /**< @brief 1: Print infos, 0: Don't print */
|
||||
#define GDS_PRINT_DEBUG_INFOS (1) /**< @brief 1: Print infos, 0: Don't print */
|
||||
|
||||
/**
|
||||
* @brief Parse a GDS file
|
||||
@@ -48,9 +48,11 @@
|
||||
*
|
||||
* @param[in] filename Path to the GDS file
|
||||
* @param[in,out] library_array GList Pointer.
|
||||
* @param[in] parsing_options Parsing options.
|
||||
* @return 0 if successful
|
||||
*/
|
||||
int parse_gds_from_file(const char *filename, GList **library_array);
|
||||
int parse_gds_from_file(const char *filename, GList **library_array,
|
||||
const struct gds_library_parsing_opts *parsing_options);
|
||||
|
||||
/**
|
||||
* @brief Deletes all libraries including cells, references etc.
|
||||
|
@@ -129,6 +129,13 @@ struct gds_cell {
|
||||
struct gds_cell_checks checks; /**< @brief Checking results */
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief Options, hwo this liobrary was parsed.
|
||||
*/
|
||||
struct gds_library_parsing_opts {
|
||||
int simplified_polygons; /**< @brief Polygons have been simplified. Coincident end point removed. */
|
||||
};
|
||||
|
||||
/**
|
||||
* @brief GDS Toplevel library
|
||||
*/
|
||||
@@ -136,6 +143,7 @@ struct gds_library {
|
||||
char name[CELL_NAME_MAX];
|
||||
struct gds_time_field mod_time;
|
||||
struct gds_time_field access_time;
|
||||
struct gds_library_parsing_opts parsing_opts;
|
||||
double unit_in_meters; /**< Length of a database unit in meters */
|
||||
GList *cells; /**< List of #gds_cell that contains all cells in this library*/
|
||||
GList *cell_names /**< List of strings that contains all cell names */;
|
||||
|
Reference in New Issue
Block a user