MythTV master
mythdvdinfo.h
Go to the documentation of this file.
1#ifndef MYTHDVDINFO_H
2#define MYTHDVDINFO_H
3
4// C++
5#include <array>
6
7// Qt
8#include <QCoreApplication>
9
10// MythTV
11#include "libmythtv/mythtvexp.h"
12
13// libdvd
14#include "dvdnav/dvdnav.h"
15
16static constexpr size_t DVD_BLOCK_SIZE { 2048 };
17using DvdBuffer = std::array<uint8_t,DVD_BLOCK_SIZE>;
18
20{
21 friend class MythDVDBuffer;
22 Q_DECLARE_TR_FUNCTIONS(DVDInfo)
23
24 public:
25 explicit MythDVDInfo(const QString &Filename);
26 ~MythDVDInfo(void);
27
28 bool IsValid (void) const;
29 bool GetNameAndSerialNum (QString &Name, QString &SerialNumber);
30 QString GetLastError (void) const;
31
32 protected:
33 static void GetNameAndSerialNum(dvdnav_t* Nav, QString &Name,
34 QString &Serialnum, const QString &Filename,
35 const QString &LogPrefix);
36
37 dvdnav_t *m_nav { nullptr };
38 QString m_name;
40 QString m_lastError;
41};
42
43#endif // MYTHDVDINFO_H
bool GetNameAndSerialNum(QString &Name, QString &SerialNumber) override
Get the dvd title and serial num.
QString m_name
Definition: mythdvdinfo.h:38
QString m_lastError
Definition: mythdvdinfo.h:40
QString m_serialnumber
Definition: mythdvdinfo.h:39
QString GetLastError(void) const
static constexpr size_t DVD_BLOCK_SIZE
Definition: mythdvdinfo.h:16
std::array< uint8_t, DVD_BLOCK_SIZE > DvdBuffer
Definition: mythdvdinfo.h:17
#define MTV_PUBLIC
Definition: mythtvexp.h:15