00001
00002
00003
00004
00005
00007 #ifndef XML_DVDAUTHOR_H
00008 #define XML_DVDAUTHOR_H
00009
00010 #include <qstring.h>
00011 #include <qdom.h>
00012
00013 #define DVD_DOCTYPE ""
00014
00015 #define DVDAUTHOR_DEST "dest"
00016 #define DVDAUTHOR_JUMPPAD "jumppad"
00017 #define MENUS_LANG "lang"
00018 #define VIDEO_FORMAT "format"
00019 #define VIDEO_ASPECT "aspect"
00020 #define VIDEO_RESOLUTION "resolution"
00021 #define VIDEO_CAPTION "caption"
00022 #define VIDEO_WIDESCREEN "widescreen"
00023 #define AUDIO_FORMAT "format"
00024 #define AUDIO_CHANNELS "channels"
00025 #define AUDIO_QUANT "quant"
00026 #define AUDIO_DOLBY "dolby"
00027 #define AUDIO_LANG "lang"
00028 #define SUBPICTURE_LANG "lang"
00029 #define PGC_ENTRY "entry"
00030 #define PGC_PALETTE "palette"
00031 #define PGC_PAUSE "pause"
00032 #define BUTTON_NAME "name"
00033 #define VOB_FILE "file"
00034 #define VOB_CHAPTERS "chapters"
00035 #define VOB_PAUSE "pause"
00036 #define CELL_START "start"
00037 #define CELL_END "end"
00038 #define CELL_CHAPTER "chapter"
00039 #define CELL_PROGRAM "program"
00040 #define CELL_PAUSE "pause"
00041
00042 #define SPU_START "start"
00043 #define SPU_END "end"
00044 #define SPU_IMAGE "image"
00045 #define SPU_HIGHLIGHT "highlight"
00046 #define SPU_SELECT "select"
00047 #define SPU_TRANSPARENT "transparent"
00048 #define SPU_FORCE "force"
00049 #define SPU_AUTOOUTLINE "autooutline"
00050 #define SPU_OUTLINEWIDTH "outlinewidth"
00051 #define SPU_AUTOORDER "autoorder"
00052 #define SPU_XOFFSET "xoffset"
00053 #define SPU_YOFFSET "yoffset"
00054 #define BUTTON_LABEL "label"
00055 #define BUTTON_X0 "x0"
00056 #define BUTTON_Y0 "y0"
00057 #define BUTTON_X1 "x1"
00058 #define BUTTON_Y1 "y1"
00059 #define BUTTON_UP "up"
00060 #define BUTTON_DOWN "down"
00061 #define BUTTON_LEFT "left"
00062 #define BUTTON_RIGHT "right"
00063 #define ACTION_LABEL "label"
00064
00065
00066
00067 class CXmlDVDAuthor
00068 {
00069
00070 public:
00071 class video_struct {
00072 public:
00073 video_struct ()
00074 {node_name=QString("video");};
00075 bool readXml (QDomElement *);
00076 bool writeXml(QDomDocument *, QDomElement *);
00077 QString node_name;
00078 QString format;
00079 QString aspect;
00080 QString resolution;
00081 QString caption;
00082 QString widescreen;
00083 };
00084 class audio_struct {
00085 public:
00086 audio_struct ()
00087 {node_name=QString("audio"); channels=0;};
00088 bool readXml (QDomElement *);
00089 bool writeXml(QDomDocument *, QDomElement *);
00090 QString node_name;
00091 QString format;
00092 uint channels;
00093 QString quant;
00094 QString dolby;
00095 QString lang;
00096 };
00097 class subpicture_struct {
00098 public:
00099 subpicture_struct ()
00100 {node_name=QString("subpicture");};
00101 bool readXml (QDomElement *);
00102 bool writeXml(QDomDocument *, QDomElement *);
00103 QString node_name;
00104 QString lang;
00105 };
00106 class pre_struct {
00107 public:
00108 pre_struct ()
00109 {node_name=QString("pre");};
00110 bool readXml(QDomElement *);
00111 bool writeXml(QDomDocument *, QDomElement *);
00112 QString node_name;
00113 QString value;
00114 };
00115 class cell_struct {
00116 public:
00117 cell_struct ()
00118 {node_name=QString("cell");};
00119 bool readXml(QDomElement *);
00120 bool writeXml(QDomDocument *, QDomElement *);
00121 QString node_name;
00122 QString start;
00123 QString end;
00124 QString chapter;
00125 QString program;
00126 QString pause;
00127 };
00128 class vob_struct {
00129 public:
00130 vob_struct ()
00131 {node_name=QString("vob");};
00132 bool readXml(QDomElement *);
00133 bool writeXml(QDomDocument *, QDomElement *);
00134 QString node_name;
00135 QString file;
00136 QString chapters;
00137 QString pause;
00138 cell_struct cell;
00139 };
00140 class button_struct {
00141 public:
00142 button_struct ()
00143 {node_name=QString("button");};
00144 bool readXml(QDomElement *);
00145 bool writeXml(QDomDocument *, QDomElement *);
00146 QString node_name;
00147 QString value;
00148 QString name;
00149 };
00150 class post_struct {
00151 public:
00152 post_struct ()
00153 {node_name=QString("post");};
00154 bool readXml(QDomElement *);
00155 bool writeXml(QDomDocument *, QDomElement *);
00156 QString node_name;
00157 QString value;
00158 };
00159
00160 class pgc_struct {
00161 public:
00162 pgc_struct ();
00163 ~pgc_struct ();
00164 bool readXml(QDomElement *);
00165 bool writeXml(QDomDocument *, QDomElement *);
00166 button_struct *addButton();
00167 vob_struct *addVob();
00168
00169 QString entry;
00170 QString palette;
00171 QString pause;
00172
00173 QString node_name;
00174 pre_struct pre;
00175 vob_struct **ppArrayVob;
00176 button_struct **ppArrayButton;
00177 post_struct post;
00178 };
00179 class menus_struct {
00180 public:
00181 menus_struct ();
00182 ~menus_struct ();
00183 bool readXml (QDomElement *);
00184 bool writeXml(QDomDocument *, QDomElement *);
00185 pgc_struct *addPgc ();
00186
00187 QString node_name;
00188 QString lang;
00189 video_struct video;
00190 audio_struct audio[8];
00191 subpicture_struct subpicture;
00192 pgc_struct **ppArrayPgc;
00193 };
00194 class titles_struct {
00195 public:
00196 titles_struct ();
00197 ~titles_struct ();
00198 bool readXml(QDomElement *);
00199 bool writeXml(QDomDocument *, QDomElement *);
00200 pgc_struct *addPgc ();
00201
00202 QString node_name;
00203 QString titles;
00204 video_struct video;
00205 audio_struct audio[8];
00206 pgc_struct **ppArrayPgc;
00207 };
00208 class vmgm_struct {
00209 public:
00210 vmgm_struct ();
00211 bool readXml (QDomElement *);
00212 bool writeXml(QDomDocument *, QDomElement *);
00213
00214 QString node_name;
00215 menus_struct menus;
00216 };
00217 class titleset_struct {
00218 public:
00219 titleset_struct ();
00220 bool readXml (QDomElement *);
00221 bool writeXml(QDomDocument *, QDomElement *);
00222
00223 QString node_name;
00224 menus_struct menus;
00225 titles_struct titles;
00226 };
00227 class dvdauthor_struct {
00228 public:
00229 dvdauthor_struct ();
00230 ~dvdauthor_struct ();
00231
00232 bool readXml (QDomElement *);
00233 bool writeXml(QDomDocument *);
00234 titleset_struct *addTitleset ();
00235
00236 QString node_name;
00237 QString dest;
00238 QString jumppad;
00239 vmgm_struct vmgm;
00240 titleset_struct **ppArrayTitleset;
00241 };
00242 public:
00243 CXmlDVDAuthor ();
00244 ~CXmlDVDAuthor ();
00245
00246 bool readXml ();
00247 bool writeXml ();
00248 bool writeXml (QString &fileName);
00249
00250 private:
00251
00252
00253
00254 public:
00255 dvdauthor_struct m_dvdauthor;
00256
00257 };
00258
00260
00261
00262
00264
00265
00266
00267
00268
00269
00270
00271
00272
00273
00274
00275
00276
00277
00278
00279
00280
00281
00282
00283
00284
00285
00286
00287
00288
00289
00290
00291
00292
00293
00294
00295
00296
00297
00298
00299
00300
00301
00302
00303
00304
00305
00306
00307
00308
00310 class CXmlSpumux
00311 {
00312
00313 public:
00314 class button_struct {
00315 public:
00316 button_struct ();
00317 bool readXml (QDomElement *);
00318 bool writeXml(QDomDocument *, QDomElement *);
00319 QString node_name;
00320 QString label;
00321 int x0;
00322 int y0;
00323 int x1;
00324 int y1;
00325 QString up;
00326 QString down;
00327 QString left;
00328 QString right;
00329 };
00330 class action_struct {
00331 public:
00332 action_struct ()
00333 {node_name = QString ("action");}
00334 bool readXml (QDomElement *);
00335 bool writeXml(QDomDocument *, QDomElement *);
00336 QString node_name;
00337 QString label;
00338 };
00339 class textsub_struct {
00340 public:
00341 textsub_struct ()
00342 {node_name = QString ("textsub");}
00343 bool readXml (QDomElement *);
00344 bool writeXml(QDomDocument *, QDomElement *);
00345 QString node_name;
00346 QString filename;
00347 QString characterset;
00348 int fontsize;
00349 int horizontal_alignment;
00350 int vertical_alignment;
00351 int left_margin;
00352 int right_margin;
00353 int bottom_margin;
00354 int top_margin;
00355 QString font;
00356 float subtitle_fps;
00357 float movie_fps;
00358 int movie_width;
00359 int movie_height;
00360 QString transparent;
00361 };
00362
00363 class spu_struct {
00364 public:
00365 spu_struct ();
00366 ~spu_struct ();
00367 bool readXml (QDomElement *);
00368 bool writeXml(QDomDocument *, QDomElement *);
00369 button_struct *addButton ();
00370 action_struct *addAction ();
00371 QString node_name;
00372 QString start;
00373 QString end;
00374 QString image;
00375 QString highlight;
00376 QString select;
00377 QString transparent;
00378 QString force;
00379 QString autooutline;
00380 int outlinewidth;
00381 QString autoorder;
00382 int xoffset;
00383 int yoffset;
00384 button_struct **ppArrayButton;
00385 action_struct **ppArrayAction;
00386 };
00387 class stream_struct {
00388 public:
00389 stream_struct ();
00390 ~stream_struct ();
00391 bool readXml (QDomElement *);
00392 bool writeXml(QDomDocument *, QDomElement *);
00393 QString node_name;
00394 spu_struct *addSpu();
00395 spu_struct **ppArraySpu;
00396 };
00397 class subpictures_struct {
00398 public:
00399 subpictures_struct ()
00400 {node_name = QString ("subpictures");}
00401 bool readXml (QDomElement *);
00402 bool writeXml(QDomDocument *);
00403 QString node_name;
00404 stream_struct stream;
00405 };
00406 public:
00407 CXmlSpumux ();
00408 ~CXmlSpumux ();
00409
00410 bool readXml ();
00411 bool writeXml ();
00412 bool writeXml (QString &fileName);
00413
00414
00415 public:
00416 subpictures_struct m_subpictures;
00417 };
00418
00419
00421
00422
00423
00425
00426
00427
00428
00429
00430
00431
00432
00433
00434
00435
00436
00437
00438
00439
00441
00442 #endif // XML_DVDAUTHOR_H