PLplot
5.11.0
Main Page
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
disptab.h
Go to the documentation of this file.
1
// Defines the data structure which holds the driver functions.
2
//
3
4
#ifndef __DISPATCH_H__
5
#define __DISPATCH_H__
6
7
#include "
plConfig.h
"
8
9
struct
PLStream_struct;
10
11
enum
12
{
13
plDevType_FileOriented
= 0,
14
plDevType_Interactive
= 1,
15
plDevType_Null
= -1
16
};
17
18
//--------------------------------------------------------------------------
19
// Define structure containing pointers to device dependent functions.
20
//
21
// pl_MenuStr Pointer to string that is printed in device menu.
22
//
23
// pl_DevName A short device "name" for device selection by name.
24
//
25
// pl_type 0 for file-oriented device, 1 for interactive
26
// (the null driver uses -1 here)
27
//
28
// pl_seq The sequence number for ordering the presentation list of the
29
// available drivers. This is an ordering only, not an absolute
30
// position in the list.
31
//
32
// pl_init Initialize device. This routine may also prompt the user
33
// for certain device parameters or open a graphics file
34
// (see note). Called only once to set things up. Certain
35
// options such as familying and resolution (dots/mm) should
36
// be set up before calling this routine (note: some drivers
37
// ignore these).
38
//
39
// pl_line Draws a line between two points.
40
//
41
// pl_polyline Draws a polyline (no broken segments).
42
//
43
// pl_eop Finishes out current page (see note).
44
//
45
// pl_bop Set up for plotting on a new page. May also open a new
46
// a new graphics file (see note).
47
//
48
// pl_tidy Tidy up. May close graphics file (see note).
49
//
50
// pl_state Handle change in PLStream state
51
// (color, pen width, fill attribute, etc).
52
//
53
// pl_esc Escape function for driver-specific commands.
54
//
55
//
56
// Notes:
57
//
58
// Most devices allow multi-page plots to be stored in a single graphics
59
// file, in which case the graphics file should be opened in the pl_init()
60
// routine, closed in pl_tidy(), and page advances done by calling pl_eop
61
// and pl_bop() in sequence. If multi-page plots need to be stored in
62
// different files then pl_bop() should open the file and pl_eop() should
63
// close it. Do NOT open files in both pl_init() and pl_bop() or close
64
// files in both pl_eop() and pl_tidy().
65
//--------------------------------------------------------------------------
66
67
typedef
void
( *
plD_init_fp
)(
struct
PLStream_struct * );
68
typedef
void
( *
plD_line_fp
)(
struct
PLStream_struct *, short, short, short, short );
69
typedef
void
( *
plD_polyline_fp
)(
struct
PLStream_struct *,
short
*,
short
*,
PLINT
);
70
typedef
void
( *
plD_eop_fp
)(
struct
PLStream_struct * );
71
typedef
void
( *
plD_bop_fp
)(
struct
PLStream_struct * );
72
typedef
void
( *
plD_tidy_fp
)(
struct
PLStream_struct * );
73
typedef
void
( *
plD_state_fp
)(
struct
PLStream_struct *,
PLINT
);
74
typedef
void
( *
plD_esc_fp
)(
struct
PLStream_struct *,
PLINT
,
void
* );
75
76
typedef
struct
77
{
78
char
*
pl_MenuStr
;
79
char
*
pl_DevName
;
80
int
pl_type
;
81
int
pl_seq
;
82
plD_init_fp
pl_init
;
83
plD_line_fp
pl_line
;
84
plD_polyline_fp
pl_polyline
;
85
plD_eop_fp
pl_eop
;
86
plD_bop_fp
pl_bop
;
87
plD_tidy_fp
pl_tidy
;
88
plD_state_fp
pl_state
;
89
plD_esc_fp
pl_esc
;
90
}
PLDispatchTable
;
91
92
#endif // __DISPATCH_H__
plplot_source
include
disptab.h
Generated on Sun Apr 12 2015 03:08:35 for PLplot by
1.8.1.2