summaryrefslogtreecommitdiffstats
path: root/libk9copy/k9dvdtitle.h
blob: 4e74ddc692a0c47c33da81bbcc71589158026f41 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
/**************************************************************************
*   Copyright (C) 2005 by Jean-Michel Petit                               *
*   jm_petit@laposte.net                                                  *
*                                                                         *
*   This program is free software; you can redistribute it and/or modify  *
*   it under the terms of the GNU General Public License as published by  *
*   the Free Software Foundation; either version 2 of the License, or     *
*   (at your option) any later version.                                   *
*                                                                         *
*   This program is distributed in the hope that it will be useful,       *
*   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
*   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
*   GNU General Public License for more details.                          *
*                                                                         *
*   You should have received a copy of the GNU General Public License     *
*   along with this program; if not, write to the                         *
*   Free Software Foundation, Inc.,                                       *
*   51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.             *
***************************************************************************/
#ifndef K9DVDTITLE_H
#define K9DVDTITLE_H

#include "k9common.h"
#include "k9dvd.h"
#include "k9dvdchapter.h"
#include <tqdatetime.h>
#include <tqstringlist.h>
#include <tqptrlist.h>

class k9DVDTitleSet;
  
class k9DVDVideoStream : public TQObject{
Q_OBJECT
TQ_OBJECT
friend class k9DVDTitle;
private: // Private attributes
public: // Public methods

};
  
class k9DVDAudioStream : public TQObject{
Q_OBJECT
TQ_OBJECT
friend class k9DVDTitle;
friend class k9DVD;
private: // Private attributes
  /**  */
  TQString langCod;
  /**  */
  TQString language;
  /**  */
  TQString format;
  /**  */
  TQString frequency;
  /**  */
  TQString quantization;
  /**  */
  int channels;
  /**  */
  int appMode;
  /**  */
  TQString content;
  /**  */
  float size_mb;
  /**  */
  bool selected;
    int id;
   k9DVDTitle *title;
  int m_streamId;
public: // Public methods
  k9DVDAudioStream();
  /** Read property of TQString langCod. */
  virtual const TQString& getlangCod();
  /** Read property of TQString language. */
  virtual const TQString& getlanguage();
  /** Read property of TQString format. */
  virtual const TQString& getformat();
  /** Read property of TQString frequency. */
  virtual const TQString& getfrequency();
  /** Read property of TQString quantization. */
  virtual const TQString& getquantization();
  /** Read property of int channels. */
  virtual const int& getchannels();
  /** Read property of int appMode. */
  virtual const int& getappMode();
  /** Read property of TQString content. */
  virtual const TQString& getcontent();
  /** Read property of float size_mb. */
  virtual const float& getsize_mb();
  /** Write property of bool selected. */
  virtual void setselected( const bool& _newVal);
  /** Read property of bool selected. */
  virtual const bool& getselected();

  virtual k9DVDTitle* gettitle();
  virtual  int getID();

  virtual int getStreamId() const {return m_streamId;};
	
};

class k9DVDSubtitle : public TQObject{
Q_OBJECT
TQ_OBJECT
friend class k9DVDTitle;
friend class k9DVD;
private: // Private attributes
  /**  */
  TQString langCod;
  /**  */
  TQString language;
  /**  */
  int num;
  /**  */
  TQString content;
  /**  */
  float size_mb;
  /**  */
  bool selected;
  TQValueList<int> id;
  k9DVDTitle *title;
public: // Public methods
  k9DVDSubtitle();
  /** Read property of TQString langCod. */
  virtual const TQString& getlangCod();
  /** Read property of TQString language. */
  virtual const TQString& getlanguage();
  /** Read property of int num. */
  virtual const int& getnum();
  /** Read property of TQString content. */
  virtual const TQString& getcontent();
  /** Read property of float size_mb. */
  virtual const float& getsize_mb();
  /** Write property of bool selected. */
  virtual void setselected( const bool& _newVal);
  /** Read property of bool selected. */
  virtual const bool& getselected();
  virtual k9DVDTitle* gettitle();
  virtual TQValueList<int>& getID();
};
  

class k9TitleEncOpt;


class k9DVDTitle : public TQObject{
Q_OBJECT
TQ_OBJECT  
friend class k9DVD;
private: // Public attributes
  unsigned int ts_nr;
  int chapterCount;
  int streamCount;
  int audioStreamCount;
  int subPictureCount;
  TQTime length;
  k9DVDVideoStream videoStream;
  TQObjectList audioStreams;
  TQObjectList subtitles;
  int VTS;
  int TTN;
  float FPS;
  TQString format;
  TQString aspectRatio;
  int numTitle;
  TQString width;
  TQString height;
  TQStringList palette;
  TQString DF;
  float size_mb;
  int angleCount;
  float videosize_mb;
  float vobusize_mb;
  TQString name;
   k9DVDTitle* nextTitle;
  int id;
  k9DVDTitleset *m_titleset;
  k9DVDAudioStream *m_defAudio;
  k9DVDSubtitle *m_defSubtitle;
  bool m_defAudioSet;
  bool m_defSubtitleSet;
  TQPtrList <k9DVDTitle> m_titles;
  uint32_t m_sectors;
  bool m_forceFactor;
  float m_factor;
  k9TitleEncOpt *m_encOpt;
public: // Public methods
  k9DVDTitle();
  virtual k9DVDTitleset *gettitleset() {return m_titleset;};
  virtual const int& getchapterCount();
  virtual const int& getstreamCount();
  virtual const int& getaudioStreamCount();
  virtual const int& getsubPictureCount();    
  virtual const TQTime& getlength();
  virtual TQTime gettotallength();
  virtual TQTime getSelectedLength();

  virtual const int& getVTS();
  virtual const int& getTTN();
  virtual const float& getFPS();
  virtual const TQString& getformat();
  virtual const TQString& getaspectRatio();
  virtual const TQString& getwidth();
  virtual const TQString& getheight();
  virtual void getpalette(int i,TQString & c);
  virtual const TQString& getDF();
  virtual const int& getangleCount();
  virtual const int& getnumTitle();
  virtual k9DVDAudioStream *getaudioStream(int num);
  virtual k9DVDSubtitle *getsubtitle(int num);
  virtual const float& getsize_mb();
  virtual const float  gettotalsize_mb();
  virtual const float  gettotalvideosize_mb();
  virtual const float  getChaptersSize_mb(bool _selected);
  virtual const uint64_t  getChaptersSize(bool _selected);
  virtual const float& getvideosize_mb();
  virtual bool isSelected();
  virtual void setname( const TQString& _newVal);
  virtual const TQString& getname();
  virtual int getpgc();
  virtual void setnextTitle(k9DVDTitle * nTitle);
  virtual k9DVDTitle* getnextTitle();
  virtual k9DVDChapter *getChapter(int num);
  virtual bool getIndexed() {return indexed;};
  virtual void setforceSelection(bool _state);
  virtual int getId() {return id;};
  virtual void setDefAudio(k9DVDAudioStream* _value);
  virtual k9DVDAudioStream* getDefAudio() const;
  virtual void setDefSubtitle(k9DVDSubtitle* _value);
  virtual k9DVDSubtitle* getDefSubtitle() const;
  virtual bool getDefAudioSet() const {return m_defAudioSet;};
  virtual bool getDefSubtitleSet() const {return m_defSubtitleSet;};
  virtual TQPtrList< k9DVDTitle > getTitles() const {return m_titles;};
  virtual uint32_t getsectors() { return m_sectors;};	
  virtual float getfactor() { return m_factor;};
  virtual bool getforceFactor() { return m_forceFactor;};
  virtual void selectChapters(bool _state);
  virtual TQPtrList< k9DVDChapter > getChapters() const {return chapters;};
  virtual k9TitleEncOpt* getEncOpt() ;
  
public slots:
  virtual void setfactor(float _value) {m_factor=_value;};
  virtual void setforceFactor(bool _value) {m_forceFactor=_value;};	
	
signals:
  void selectionChanged();
private: // Private methods
  k9DVDAudioStream* addAudioStream();
  k9DVDChapter* addChapter(int num);
  k9DVDSubtitle* addSubtitle(int num);
  TQPtrList <k9DVDChapter> chapters;
  bool indexed;
  bool forceSelection;
   int pgc;

public: // Public attributes
};
  



#endif