Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
ElmerCSC
GitHub Repository: ElmerCSC/elmerfem
Path: blob/devel/post/src/camera/glpfile.h
3203 views
1
//
2
// "$Id: glpfile.h,v 1.1 2003/02/06 09:37:55 jpr Exp $"
3
//
4
// Header file for the GLPfile class for the OpenGL printing toolkit.
5
//
6
// The GLP library is distributed under the terms of the GNU Library
7
// General Public License which is described in the file "COPYING.LIB".
8
// If you use this library in your program, please include a line reading
9
// "OpenGL Printing Toolkit by Michael Sweet" in your version or copyright
10
// output.
11
//
12
// Revision History:
13
//
14
// $Log: glpfile.h,v $
15
// Revision 1.1 2003/02/06 09:37:55 jpr
16
// *** empty log message ***
17
//
18
// Revision 1.2 1996/07/13 12:52:02 mike
19
// Changed default print options to include drawing of background.
20
//
21
// Revision 1.1 1996/06/27 03:07:13 mike
22
// Initial revision
23
//
24
25
#ifndef _GL_GLPFILE_H_
26
#define _GL_GLPFILE_H_
27
28
//
29
// Include necessary headers.
30
//
31
32
#include "glp.h"
33
34
35
struct GLPtext
36
{
37
GLPtext *next;
38
double x,y,h;
39
double r,g,b;
40
char *string;
41
};
42
43
// GLPtext *texthead;
44
45
//
46
// The Adobe PostScript file output class for GLP. Basically, we just
47
// add file and page count members and define our own constructor,
48
// destructor, and 'EndPage()' functions.
49
//
50
51
class GLPfile : public GLPcontext //// GLPfile class
52
{
53
private:
54
int page_count; // Page count
55
std::fstream *outfile; // Output file
56
57
public:
58
GLPfile(char *print_name,
59
int print_options = GLP_FIT_TO_PAGE | GLP_DRAW_BACKGROUND,
60
int print_size = 0);
61
~GLPfile(void);
62
63
int EndPage(void);
64
void output_tree( GLPprimitive *tree );
65
void output_prim( GLPprimitive *prim );
66
void DoOutputPS( GLPtext *text );
67
};
68
69
#endif // !_GL_GLPFILE_H_
70
71
//
72
// End of "$Id: glpfile.h,v 1.1 2003/02/06 09:37:55 jpr Exp $".
73
//
74
75