MythTV  master
Macros | Functions
musicutils.h File Reference
#include <QString>
#include "mythmetaexp.h"
Include dependency graph for musicutils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define QStringToTString(s)   TagLib::String(s.toUtf8().data(), TagLib::String::UTF8)
 
#define TStringToQString(s)   QString::fromUtf8(s.toCString(true))
 

Functions

META_PUBLIC QString fixFilename (const QString &filename)
 remove any bad filename characters More...
 
META_PUBLIC QString findIcon (const QString &type, const QString &name, bool ignoreCache=false)
 find an image for a artist or genre More...
 
META_PUBLIC QString filenameFromMetadata (MusicMetadata *track)
 create a filename using the template in the settings and a MusicMetadata object More...
 
META_PUBLIC bool isNewTune (const QString &artist, const QString &album, const QString &title)
 try to find a track in the db using the given artist, album and title More...
 

Macro Definition Documentation

◆ QStringToTString

#define QStringToTString (   s)    TagLib::String(s.toUtf8().data(), TagLib::String::UTF8)

Definition at line 14 of file musicutils.h.

◆ TStringToQString

#define TStringToQString (   s)    QString::fromUtf8(s.toCString(true))

Definition at line 16 of file musicutils.h.

Function Documentation

◆ fixFilename()

META_PUBLIC QString fixFilename ( const QString &  filename)

remove any bad filename characters

Definition at line 26 of file musicutils.cpp.

Referenced by filenameFromMetadata(), and findIcon().

◆ findIcon()

META_PUBLIC QString findIcon ( const QString &  type,
const QString &  name,
bool  ignoreCache = false 
)

◆ filenameFromMetadata()

META_PUBLIC QString filenameFromMetadata ( MusicMetadata track)

create a filename using the template in the settings and a MusicMetadata object

Definition at line 77 of file musicutils.cpp.

Referenced by ImportMusicDialog::addPressed(), CDRipperThread::run(), and ImportCoverArtDialog::updateStatus().

◆ isNewTune()

META_PUBLIC bool isNewTune ( const QString &  artist,
const QString &  album,
const QString &  title 
)