MythTV  master
Classes | Typedefs | Enumerations | Functions | Variables
musicmetadata.h File Reference
#include <array>
#include <cstdint>
#include <utility>
#include <QCoreApplication>
#include <QDateTime>
#include <QImage>
#include <QMap>
#include <QMetaType>
#include <QStringList>
#include "libmythbase/mthread.h"
#include "libmythbase/mythcorecontext.h"
#include "libmythbase/mythtypes.h"
#include "libmythmetadata/mythmetaexp.h"
Include dependency graph for musicmetadata.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  AlbumArtImage
 
class  MusicMetadata
 
class  MetadataLoadingThread
 
class  AllMusic
 
class  AllStream
 
class  AlbumArtScannerThread
 
class  AlbumArtImages
 

Typedefs

using AlbumArtList = QList< AlbumArtImage * >
 
using UrlList = std::array< QString, STREAMURLCOUNT >
 
using MetadataPtrList = QList< MusicMetadata * >
 
using StreamList = QList< MusicMetadata * >
 

Enumerations

enum  ImageType : std::uint8_t {
  IT_UNKNOWN = 0, IT_FRONTCOVER, IT_BACKCOVER, IT_CD,
  IT_INLAY, IT_ARTIST, IT_LAST
}
 
enum  RepoType : std::uint8_t { RT_Database = 0, RT_CD = 1, RT_Radio = 2 }
 

Functions

static constexpr uint32_t ID_TO_ID (uint32_t x)
 
static constexpr uint32_t ID_TO_REPO (uint32_t x)
 
bool operator== (MusicMetadata &a, MusicMetadata &b)
 
bool operator!= (MusicMetadata &a, MusicMetadata &b)
 
 Q_DECLARE_METATYPE (ImageType)
 
 Q_DECLARE_METATYPE (AlbumArtImage *)
 

Variables

static constexpr uint8_t METADATA_BITS_FOR_REPO { 8 }
 
static constexpr uint8_t METADATA_REPO_SHIFT { 24 }
 
static constexpr uint32_t METADATA_REPO_MASK { 0xff000000 }
 
static constexpr uint32_t METADATA_ID_MASK { 0x00ffffff }
 
static constexpr const char * METADATA_INVALID_FILENAME { "**NOT FOUND**" }
 
static constexpr const char * STREAMUPDATEURL { "https://services.mythtv.org/music/data/?data=streams" }
 
static constexpr size_t STREAMURLCOUNT { 5 }
 

Typedef Documentation

◆ AlbumArtList

using AlbumArtList = QList<AlbumArtImage*>

Definition at line 56 of file musicmetadata.h.

◆ UrlList

using UrlList = std::array<QString,STREAMURLCOUNT>

Definition at line 78 of file musicmetadata.h.

◆ MetadataPtrList

using MetadataPtrList = QList<MusicMetadata*>

Definition at line 395 of file musicmetadata.h.

◆ StreamList

using StreamList = QList<MusicMetadata*>

Definition at line 473 of file musicmetadata.h.

Enumeration Type Documentation

◆ ImageType

enum ImageType : std::uint8_t
Enumerator
IT_UNKNOWN 
IT_FRONTCOVER 
IT_BACKCOVER 
IT_CD 
IT_INLAY 
IT_ARTIST 
IT_LAST 

Definition at line 28 of file musicmetadata.h.

◆ RepoType

enum RepoType : std::uint8_t
Enumerator
RT_Database 
RT_CD 
RT_Radio 

Definition at line 58 of file musicmetadata.h.

Function Documentation

◆ ID_TO_ID()

static constexpr uint32_t ID_TO_ID ( uint32_t  x)
staticconstexpr

◆ ID_TO_REPO()

static constexpr uint32_t ID_TO_REPO ( uint32_t  x)
staticconstexpr

◆ operator==()

bool operator== ( MusicMetadata a,
MusicMetadata b 
)

Definition at line 40 of file musicmetadata.cpp.

◆ operator!=()

bool operator!= ( MusicMetadata a,
MusicMetadata b 
)

Definition at line 45 of file musicmetadata.cpp.

◆ Q_DECLARE_METATYPE() [1/2]

Q_DECLARE_METATYPE ( ImageType  )

◆ Q_DECLARE_METATYPE() [2/2]

Q_DECLARE_METATYPE ( AlbumArtImage )

Variable Documentation

◆ METADATA_BITS_FOR_REPO

constexpr uint8_t METADATA_BITS_FOR_REPO { 8 }
staticconstexpr

Definition at line 65 of file musicmetadata.h.

◆ METADATA_REPO_SHIFT

constexpr uint8_t METADATA_REPO_SHIFT { 24 }
staticconstexpr

Definition at line 66 of file musicmetadata.h.

Referenced by ID_TO_REPO(), and MusicMetadata::setRepo().

◆ METADATA_REPO_MASK

constexpr uint32_t METADATA_REPO_MASK { 0xff000000 }
staticconstexpr

Definition at line 67 of file musicmetadata.h.

◆ METADATA_ID_MASK

constexpr uint32_t METADATA_ID_MASK { 0x00ffffff }
staticconstexpr

Definition at line 68 of file musicmetadata.h.

Referenced by ID_TO_ID(), and MusicMetadata::setRepo().

◆ METADATA_INVALID_FILENAME

constexpr const char* METADATA_INVALID_FILENAME { "**NOT FOUND**" }
staticconstexpr

Definition at line 73 of file musicmetadata.h.

Referenced by MusicMetadata::Filename(), and MusicPlayer::play().

◆ STREAMUPDATEURL

constexpr const char* STREAMUPDATEURL { "https://services.mythtv.org/music/data/?data=streams" }
staticconstexpr

Definition at line 75 of file musicmetadata.h.

Referenced by MusicMetadata::updateStreamList().

◆ STREAMURLCOUNT

constexpr size_t STREAMURLCOUNT { 5 }
staticconstexpr