#include <vul_psfile.h>
Definition at line 19 of file vul_psfile.h.
Public Types | |
| enum | paper_type { US_NORMAL, A4, B5, A3, US_LEGAL, ELEVEN_BY_SEVENTEEN, FOUR_BY_FIVE, THIRTY_FIVE_mm } |
| enum | paper_orientation { PORTRAIT, LANDSCAPE } |
| enum | paper_layout { CENTER, MAX } |
Public Member Functions | |
| vul_psfile (char const *filename, bool debug_output=false) | |
| Default constructor. | |
| ~vul_psfile () | |
| Destructor. | |
| operator bool () | |
| void | set_paper_type (vul_psfile::paper_type type) |
| void | set_paper_layout (vul_psfile::paper_layout layout) |
| void | set_paper_orientation (vul_psfile::paper_orientation o) |
| void | set_reduction_factor (int rf) |
| void | set_scale_x (float sx) |
| set the horizontal scaling (in percent); no scaling is 100. | |
| void | set_scale_y (float sy) |
| set the vertical scaling (in percent); no scaling is 100. | |
| void | set_fg_color (float r, float g, float b) |
| void | set_bg_color (float r, float g, float b) |
| void | set_line_width (float f_width) |
| float | line_width () const |
| void | print_greyscale_image (unsigned char *data, int sizex, int sizey) |
| Write 8 bit grey scale image. | |
| void | print_color_image (unsigned char *data, int sizex, int sizey) |
| Write 24 bit colour image. | |
| void | line (float x1, float y1, float x2, float y2) |
| Add a line between the given points to the Postscript file. | |
| void | point (float x, float y, float point_size=0) |
| Add a point at the given coordinates to the Postscript file. | |
| void | ellipse (float x, float y, float a_axis, float b_axis, int angle=0) |
| Add an ellipse to the Postscript file. | |
| void | circle (float x, float y, float radius) |
| Add a circle with the given centre point and radius to the Postscript file. | |
Protected Member Functions | |
| void | set_min_max_xy (float x, float y) |
| Set Bounding Box Min and Max x, y. | |
| void | set_min_max_xy (int x, int y) |
| Set Bounding Box Min and Max x, y. | |
| bool | set_parameters (int sizex, int sizey) |
| Set ox, oy , iw, ih, iwf, ihf parameters for PostScript file use. | |
| void | postscript_header () |
| PostScript file header. Automatically called by the constructor. | |
| void | graphic_header () |
| Set graphic coordinate (translate and rotate to local coordinate). | |
| void | sobj_rgb_params (char const *str, bool filled) |
| Utility program used in point(), line(), ellipse() and circle(). | |
| void | print_graphics_prolog () |
| the defined procedure for PostScript script use. | |
Private Member Functions | |
| void | compute_bounding_box () |
| Recalculate bounding box and scale x and y (if necessary). | |
| void | reset_bounding_box () |
| Rewrite output bounding box parameters. | |
| void | reset_postscript_header () |
| Reset PostScript header file. | |
| void | image_translate_and_scale () |
| Set Image translate and scale. | |
| void | object_translate_and_scale () |
| Set object translate and scale. | |
| void | done () |
Private Attributes | |
| vcl_ofstream | output_filestream |
| float | fg_r |
| float | fg_g |
| float | fg_b |
| float | bg_r |
| float | bg_g |
| float | bg_b |
| float | line_width_ |
| float | scale_x |
| float | scale_y |
| int | ox |
| int | oy |
| int | iw |
| int | ih |
| double | iwf |
| double | ihf |
| double | psizex |
| double | psizey |
| double | pos_inx |
| double | pos_iny |
| int | width |
| int | height |
| vcl_string | filename |
| paper_type | printer_paper_type |
| paper_orientation | printer_paper_orientation |
| paper_layout | printer_paper_layout |
| int | reduction_factor |
| bool | doneps |
| int | min_x |
| int | min_y |
| int | max_x |
| int | max_y |
| int | box_width |
| int | box_height |
| vcl_streampos | translate_pos |
| vcl_streampos | sobj_t_pos |
| vcl_streampos | header_pos |
| bool | graphics_prolog_exists |
| bool | exist_image |
| bool | exist_objs |
|
|
Definition at line 34 of file vul_psfile.h. |
|
|
Definition at line 31 of file vul_psfile.h. |
|
|
Definition at line 22 of file vul_psfile.h. |
|
||||||||||||
|
Default constructor.
Definition at line 51 of file vul_psfile.cxx. |
|
|
Destructor.
Definition at line 85 of file vul_psfile.cxx. |
|
||||||||||||||||
|
Add a circle with the given centre point and radius to the Postscript file.
Definition at line 640 of file vul_psfile.cxx. |
|
|
Recalculate bounding box and scale x and y (if necessary).
Definition at line 122 of file vul_psfile.cxx. |
|
|
Definition at line 1000 of file vul_psfile.cxx. |
|
||||||||||||||||||||||||
|
Add an ellipse to the Postscript file.
Definition at line 614 of file vul_psfile.cxx. |
|
|
Set graphic coordinate (translate and rotate to local coordinate).
Definition at line 464 of file vul_psfile.cxx. |
|
|
Set Image translate and scale.
Definition at line 479 of file vul_psfile.cxx. |
|
||||||||||||||||||||
|
Add a line between the given points to the Postscript file.
Definition at line 584 of file vul_psfile.cxx. |
|
|
Definition at line 53 of file vul_psfile.h. |
|
|
Set object translate and scale.
Definition at line 499 of file vul_psfile.cxx. |
|
|
Definition at line 40 of file vul_psfile.h. |
|
||||||||||||||||
|
Add a point at the given coordinates to the Postscript file.
Definition at line 600 of file vul_psfile.cxx. |
|
|
PostScript file header. Automatically called by the constructor.
Definition at line 533 of file vul_psfile.cxx. |
|
||||||||||||||||
|
Write 24 bit colour image.
Definition at line 311 of file vul_psfile.cxx. |
|
|
the defined procedure for PostScript script use.
Definition at line 657 of file vul_psfile.cxx. |
|
||||||||||||||||
|
Write 8 bit grey scale image.
Definition at line 222 of file vul_psfile.cxx. |
|
|
Rewrite output bounding box parameters.
Definition at line 96 of file vul_psfile.cxx. |
|
|
Reset PostScript header file.
Definition at line 552 of file vul_psfile.cxx. |
|
||||||||||||||||
|
Definition at line 51 of file vul_psfile.h. |
|
||||||||||||||||
|
Definition at line 50 of file vul_psfile.h. |
|
|
Definition at line 52 of file vul_psfile.h. |
|
||||||||||||
|
Set Bounding Box Min and Max x, y.
Definition at line 212 of file vul_psfile.cxx. |
|
||||||||||||
|
Set Bounding Box Min and Max x, y.
Definition at line 200 of file vul_psfile.cxx. |
|
|
Definition at line 43 of file vul_psfile.h. |
|
|
Definition at line 44 of file vul_psfile.h. |
|
|
Definition at line 42 of file vul_psfile.h. |
|
||||||||||||
|
Set ox, oy , iw, ih, iwf, ihf parameters for PostScript file use.
Definition at line 517 of file vul_psfile.cxx. |
|
|
Definition at line 45 of file vul_psfile.h. |
|
|
set the horizontal scaling (in percent); no scaling is 100.
Definition at line 47 of file vul_psfile.h. |
|
|
set the vertical scaling (in percent); no scaling is 100.
Definition at line 49 of file vul_psfile.h. |
|
||||||||||||
|
Utility program used in point(), line(), ellipse() and circle().
Definition at line 571 of file vul_psfile.cxx. |
|
|
Definition at line 95 of file vul_psfile.h. |
|
|
Definition at line 95 of file vul_psfile.h. |
|
|
Definition at line 95 of file vul_psfile.h. |
|
|
Definition at line 111 of file vul_psfile.h. |
|
|
Definition at line 111 of file vul_psfile.h. |
|
|
Definition at line 108 of file vul_psfile.h. |
|
|
Definition at line 120 of file vul_psfile.h. |
|
|
Definition at line 121 of file vul_psfile.h. |
|
|
Definition at line 94 of file vul_psfile.h. |
|
|
Definition at line 94 of file vul_psfile.h. |
|
|
Definition at line 94 of file vul_psfile.h. |
|
|
Definition at line 103 of file vul_psfile.h. |
|
|
Definition at line 119 of file vul_psfile.h. |
|
|
Definition at line 117 of file vul_psfile.h. |
|
|
Definition at line 102 of file vul_psfile.h. |
|
|
Definition at line 98 of file vul_psfile.h. |
|
|
Definition at line 99 of file vul_psfile.h. |
|
|
Definition at line 98 of file vul_psfile.h. |
|
|
Definition at line 99 of file vul_psfile.h. |
|
|
Definition at line 96 of file vul_psfile.h. |
|
|
Definition at line 110 of file vul_psfile.h. |
|
|
Definition at line 110 of file vul_psfile.h. |
|
|
Definition at line 109 of file vul_psfile.h. |
|
|
Definition at line 109 of file vul_psfile.h. |
|
|
Definition at line 92 of file vul_psfile.h. |
|
|
Definition at line 98 of file vul_psfile.h. |
|
|
Definition at line 98 of file vul_psfile.h. |
|
|
Definition at line 101 of file vul_psfile.h. |
|
|
Definition at line 101 of file vul_psfile.h. |
|
|
Definition at line 106 of file vul_psfile.h. |
|
|
Definition at line 105 of file vul_psfile.h. |
|
|
Definition at line 104 of file vul_psfile.h. |
|
|
Definition at line 100 of file vul_psfile.h. |
|
|
Definition at line 100 of file vul_psfile.h. |
|
|
Definition at line 107 of file vul_psfile.h. |
|
|
Definition at line 97 of file vul_psfile.h. |
|
|
Definition at line 97 of file vul_psfile.h. |
|
|
Definition at line 116 of file vul_psfile.h. |
|
|
Definition at line 115 of file vul_psfile.h. |
|
|
Definition at line 102 of file vul_psfile.h. |
1.4.4