2 Header file for swfoutput.cc (and swfoutput_x11.cc).
4 Part of the swftools package.
6 Copyright (c) 2001 Matthias Kramm <kramm@quiss.org>
8 This file is distributed under the GPL, see file COPYING for details */
10 #ifndef __swfoutput_h__
11 #define __swfoutput_h__
15 #include "../lib/rfxswf.h"
18 extern int opennewwindow; //default:0
19 extern int ignoredraworder; //default:0
20 extern int drawonlyshapes; //default:0
21 extern int jpegquality; //default:100;
22 extern int storeallcharacters; // default:0
24 typedef long int twip;
27 double m11,m12,m21,m22,m13,m23;
50 int standardtablesize;
58 SWFFont(char*name, int t1id, char*filename);
60 T1_OUTLINE*getOutline(char*charname);
61 int getSWFCharID(char*name, int charnr);
63 char*getCharName(int t);
64 int getCharWidth(int t) {return width[t];}
70 double fontm11,fontm12,fontm21,fontm22;
71 unsigned short int linewidth;
77 #define DRAWMODE_STROKE 1
78 #define DRAWMODE_FILL 2
79 #define DRAWMODE_EOFILL 3
80 #define DRAWMODE_CLIP 4
81 #define DRAWMODE_EOCLIP 5
83 void swfoutput_init(struct swfoutput*, char*filename, int sizex, int sizey);
84 void swfoutput_setprotected(); //write PROTECT tag
86 void swfoutput_newpage(struct swfoutput*);
88 void swfoutput_setfont(struct swfoutput*, char*fontid, int t1font, char*filename);
89 int swfoutput_queryfont(struct swfoutput*, char*fontid);
90 void swfoutput_setdrawmode(struct swfoutput*, int drawmode);
91 void swfoutput_setfillcolor(struct swfoutput*, unsigned char r, unsigned char g, unsigned char b, unsigned char a);
92 void swfoutput_setstrokecolor(struct swfoutput*, unsigned char r, unsigned char g, unsigned char b, unsigned char a);
93 void swfoutput_setfontmatrix(struct swfoutput*,double,double,double,double);
94 void swfoutput_setlinewidth(struct swfoutput*, double linewidth);
96 void swfoutput_drawchar(struct swfoutput*,double x,double y,char*a, int charnr);
97 void swfoutput_drawpath(struct swfoutput*, T1_OUTLINE*outline, struct swfmatrix*m);
98 void swfoutput_startclip(struct swfoutput*, T1_OUTLINE*outline, struct swfmatrix*m);
99 void swfoutput_endclip(struct swfoutput*);
100 int swfoutput_drawimagejpeg(struct swfoutput*, char*filename, int sizex,int sizey,
104 double x4,double y4);
105 int swfoutput_drawimagelossless(struct swfoutput*, RGBA*pic, int sizex, int sizey,
109 double x4,double y4);
110 int swfoutput_drawimagelossless256(struct swfoutput*, U8*pic,RGBA*pal, int sizex, int sizey,
114 double x4,double y4);
115 void swfoutput_drawimageagain(struct swfoutput*, int id, int sizex, int sizey,
119 double x4,double y4);
121 void swfoutput_linktopage(struct swfoutput*, int page, swfcoord*points);
122 void swfoutput_linktourl(struct swfoutput*, char*url, swfcoord*points);
124 void swfoutput_destroy(struct swfoutput*);
126 #endif //__swfoutput_h__