Definition in file gerbv.c.
Go to the source code of this file.
Functions | |
| gerbv_project_t * | gerbv_create_project (void) |
| void | gerbv_destroy_project (gerbv_project_t *gerbvProject) |
| void | gerbv_destroy_fileinfo (gerbv_fileinfo_t *fileInfo) |
| void | gerbv_open_layer_from_filename (gerbv_project_t *gerbvProject, gchar *filename) |
| void | gerbv_open_layer_from_filename_with_color (gerbv_project_t *gerbvProject, gchar *filename, guint16 red, guint16 green, guint16 blue, guint16 alpha) |
| gerbv_image_t * | gerbv_create_rs274x_image_from_filename (gchar *filename) |
| void | gerbv_render_zoom_to_fit_display (gerbv_project_t *gerbvProject, gerbv_render_info_t *renderInfo) |
| void | gerbv_render_layer_to_cairo_target (cairo_t *cr, gerbv_fileinfo_t *fileInfo, gerbv_render_info_t *renderInfo) |
| gerbv_project_t* gerbv_create_project | ( | void | ) |
Create a new project structure and initialize some important variables.
Definition at line 131 of file gerbv.c.
References gerbv_project_t::check_before_delete, gerbv_project_t::file, gerbv_project_t::last_loaded, gerbv_project_t::max_files, and gerbv_project_t::path.
| gerbv_image_t* gerbv_create_rs274x_image_from_filename | ( | gchar * | filename | ) |
Parse a RS274X file and return the parsed image.
| filename | the filename of the file to be parsed |
Definition at line 503 of file gerbv.c.
References parse_gerb().
| void gerbv_destroy_fileinfo | ( | gerbv_fileinfo_t * | fileInfo | ) |
Free a fileinfo structure.
| fileInfo | the fileinfo to free |
Definition at line 163 of file gerbv.c.
References gerbv_fileinfo_t::fullPathname, gerbv_destroy_image(), gerbv_fileinfo_t::image, and gerbv_fileinfo_t::name.
Referenced by gerbv_destroy_project().
| void gerbv_destroy_project | ( | gerbv_project_t * | gerbvProject | ) |
Free a project and all related variables.
| gerbvProject | the project to destroy |
Definition at line 148 of file gerbv.c.
References gerbv_project_t::file, gerbv_destroy_fileinfo(), and gerbv_project_t::max_files.
| void gerbv_open_layer_from_filename | ( | gerbv_project_t * | gerbvProject, | |
| gchar * | filename | |||
| ) |
Open a file, parse the contents, and add a new layer to an existing project.
| gerbvProject | the existing project to add the new layer to |
| filename | the full pathname of the file to be parsed |
Definition at line 171 of file gerbv.c.
References gerbv_project_t::file, gerbv_project_t::last_loaded, and gerbv_fileinfo_t::layer_dirty.
Referenced by callbacks_open_layer_activate().
| void gerbv_open_layer_from_filename_with_color | ( | gerbv_project_t * | gerbvProject, | |
| gchar * | filename, | |||
| guint16 | red, | |||
| guint16 | green, | |||
| guint16 | blue, | |||
| guint16 | alpha | |||
| ) |
Open a file, parse the contents, and add a new layer to an existing project while setting the color of the layer.
| gerbvProject | the existing project to add the new layer to |
| filename | the full pathname of the file to be parsed |
| red | the value for the red color component |
| green | the value for the green color component |
| blue | the value for the blue color component |
| alpha | the value for the alpha color component |
Definition at line 189 of file gerbv.c.
References gerbv_fileinfo_t::alpha, gerbv_fileinfo_t::color, gerbv_project_t::file, gerbv_project_t::last_loaded, and gerbv_fileinfo_t::layer_dirty.
| void gerbv_render_layer_to_cairo_target | ( | cairo_t * | cr, | |
| gerbv_fileinfo_t * | fileInfo, | |||
| gerbv_render_info_t * | renderInfo | |||
| ) |
| void gerbv_render_zoom_to_fit_display | ( | gerbv_project_t * | gerbvProject, | |
| gerbv_render_info_t * | renderInfo | |||
| ) |
Calculate the zoom and translations to fit the rendered scene inside the given scene size.
| gerbvProject | the project to use for calculating |
| renderInfo | the scene render pointer (updates the values in this parameter) |
Definition at line 555 of file gerbv.c.
References gerbv_render_info_t::displayHeight, gerbv_render_info_t::displayWidth, gerbv_render_info_t::lowerLeftX, gerbv_render_info_t::lowerLeftY, gerbv_render_info_t::scaleFactorX, and gerbv_render_info_t::scaleFactorY.
Referenced by callbacks_open_layer_activate(), callbacks_open_project_activate(), gerbv_export_pdf_file_from_project_autoscaled(), gerbv_export_png_file_from_project_autoscaled(), gerbv_export_postscript_file_from_project_autoscaled(), and gerbv_export_svg_file_from_project_autoscaled().
1.5.6