00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef SO_TO_PDF_ACTION_H
00026 #define SO_TO_PDF_ACTION_H
00027
00028 #include <HardCopy/SoToU3DAction.h>
00029
00030 #include <Inventor/SbColor.h>
00031 #include <Inventor/actions/SoSubAction.h>
00032 #include <HardCopy/SoHardCopy.h>
00033
00034 class SoToPDFActionPrivate;
00035
00130 class SoToPDFAction : public SoToU3DAction
00131 {
00132 SO_ACTION_HEADER(SoToPDFAction);
00133
00134 public:
00135
00136
00137
00138
00139 SoToPDFAction();
00140
00141
00142
00143
00144 virtual ~SoToPDFAction();
00145
00151 SoNONUNICODE virtual bool openFile(const char* filename);
00152
00156 virtual bool openFile( const SbString& filename );
00157
00161 virtual bool closeFile();
00162
00172 SoNONUNICODE void setPassword(const char* writePass, const char* readPass = NULL);
00173
00181 void setPassword( const SbString& writePass, const SbString& readPass = "" );
00182
00189 SoNONUNICODE void setTitle(const char* title);
00190
00195 void setTitle(const SbString& title);
00196
00203 SoNONUNICODE void setText(const char* text);
00204
00209 void setText(const SbString& text);
00210
00215 void setLandscape( const SbBool enable );
00216
00217 private:
00221 static void initClass();
00222 static void exitClass();
00223
00224 static bool writeFile(
00225 const SbString& pdfOutput,
00226 const SbString& writePass,
00227 const SbString& readPass,
00228 const SbString& title,
00229 const SbString& text,
00230 const SbString& u3dInput,
00231 const SbString& u3dView,
00232 bool hasPerspective,
00233 float fov,
00234 float focalDistance,
00235 bool hasLights,
00236 const SbColor& background,
00237 bool landscape = false);
00238
00239 private:
00240
00241 SoToPDFActionPrivate* m_private;
00242 };
00243
00244 #endif // SO_TO_PDF_ACTION_H
00245
00246
00247