xref: /petsc/include/petscdraw.h (revision f0479e8c2158d05ab5c06def5bd82110ef658075)
143e6b640SBarry Smith /*
243e6b640SBarry Smith   Public include file for all of the PETSc graphics routines
343e6b640SBarry Smith */
41eb62cbbSBarry Smith #if !defined(__DRAW_PACKAGE)
51eb62cbbSBarry Smith #define __DRAW_PACKAGE
643e6b640SBarry Smith 
7*f0479e8cSBarry Smith #define DRAW_COOKIE 0x101010
8*f0479e8cSBarry Smith 
943e6b640SBarry Smith typedef struct _DrawCtx* DrawCtx;
1043e6b640SBarry Smith 
1120563c6bSBarry Smith #define DRAW_WHITE  0
1220563c6bSBarry Smith #define DRAW_BLACK  1
1320563c6bSBarry Smith #define DRAW_RED    2
1420563c6bSBarry Smith #define DRAW_YELLOW 3
1520563c6bSBarry Smith #define DRAW_GREEN  4
1620563c6bSBarry Smith #define DRAW_CYAN   5
1720563c6bSBarry Smith #define DRAW_BLUE   6
1820563c6bSBarry Smith 
198ed539a5SBarry Smith int DrawOpenX(char*,char *,int,int,int,int,DrawCtx*);
2043e6b640SBarry Smith int DrawDestroy(DrawCtx);
2143e6b640SBarry Smith 
228ed539a5SBarry Smith int DrawLine(DrawCtx,double,double,double,double,int,int);
2320563c6bSBarry Smith int DrawLineSetWidth(DrawCtx,double);
2443e6b640SBarry Smith 
258ed539a5SBarry Smith int DrawPoint(DrawCtx,double,double,int);
2620563c6bSBarry Smith int DrawPointSetSize(DrawCtx,double);
278ed539a5SBarry Smith 
288ed539a5SBarry Smith int DrawText(DrawCtx,double,double,int,char*);
2920563c6bSBarry Smith int DrawTextVertical(DrawCtx,double,double,int,char*);
3020563c6bSBarry Smith int DrawTextSetSize(DrawCtx,double,double);
3120563c6bSBarry Smith int DrawTextGetSize(DrawCtx,double*,double*);
328ed539a5SBarry Smith 
338ed539a5SBarry Smith int DrawSetViewPort(DrawCtx,double,double,double,double);
348ed539a5SBarry Smith int DrawSetCoordinates(DrawCtx,double,double,double,double);
358ed539a5SBarry Smith int DrawSetDoubleBuffer(DrawCtx);
368ed539a5SBarry Smith int DrawFlush(DrawCtx);
3720563c6bSBarry Smith int DrawClear(DrawCtx);
3820563c6bSBarry Smith 
3920563c6bSBarry Smith /* routines related to drawing Axis and line graphs */
4020563c6bSBarry Smith 
4120563c6bSBarry Smith typedef struct _DrawAxisCtx* DrawAxisCtx;
4220563c6bSBarry Smith typedef struct _DrawLGCtx*   DrawLGCtx;
4320563c6bSBarry Smith 
4420563c6bSBarry Smith int DrawAxisCreate(DrawCtx,DrawAxisCtx *);
4520563c6bSBarry Smith int DrawAxisDestroy(DrawAxisCtx);
4620563c6bSBarry Smith int DrawAxis(DrawAxisCtx);
4720563c6bSBarry Smith int DrawAxisSetLimits(DrawAxisCtx,double,double,double,double);
4820563c6bSBarry Smith int DrawAxisSetColors(DrawAxisCtx,int,int,int);
4920563c6bSBarry Smith int DrawAxisSetLabels(DrawAxisCtx,char*,char*,char*);
5020563c6bSBarry Smith 
511eb62cbbSBarry Smith #define LG_COOKIE 0x17181920
5220563c6bSBarry Smith int DrawLGCreate(DrawCtx,int,DrawLGCtx *);
5320563c6bSBarry Smith int DrawLGDestroy(DrawLGCtx);
5420563c6bSBarry Smith int DrawLGAddPoint(DrawLGCtx,double*,double*);
551eb62cbbSBarry Smith int DrawLGAddPoints(DrawLGCtx,int,double**,double**);
5620563c6bSBarry Smith int DrawLG(DrawLGCtx);
57*f0479e8cSBarry Smith int DrawLGReset(DrawLGCtx);
5820563c6bSBarry Smith int DrawLGGetAxisCtx(DrawLGCtx,DrawAxisCtx *);
591eb62cbbSBarry Smith int DrawLGGetDrawCtx(DrawLGCtx,DrawCtx *);
6043e6b640SBarry Smith 
6143e6b640SBarry Smith #endif
62