2024-11-16 01:31:36 +00:00
|
|
|
#pragma once
|
2024-11-26 00:54:31 +00:00
|
|
|
#include "audioplayerinterface.hh"
|
|
|
|
#include "ffmpegaudioplayer.hh"
|
|
|
|
#include "multimediaaudioplayer.hh"
|
|
|
|
#include <QScopedPointer>
|
2024-11-16 01:31:36 +00:00
|
|
|
#include <QStringList>
|
|
|
|
|
|
|
|
/// Overly engineered dummy/helper/wrapper "backend", which is not, to manage backends.
|
|
|
|
class InternalPlayerBackend
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
/// Returns true if at least one backend is available.
|
|
|
|
static bool anyAvailable();
|
2024-11-26 00:54:31 +00:00
|
|
|
AudioPlayerInterface * getActualPlayer();
|
2024-11-16 01:31:36 +00:00
|
|
|
/// Returns the name list of supported backends.
|
2024-11-26 00:54:31 +00:00
|
|
|
/// The first one willl be the default one
|
|
|
|
static QStringList availableBackends();
|
2024-11-16 01:31:36 +00:00
|
|
|
|
2024-11-26 00:54:31 +00:00
|
|
|
QString const & getName() const
|
2024-11-16 01:31:36 +00:00
|
|
|
{
|
|
|
|
return name;
|
|
|
|
}
|
|
|
|
|
2024-11-26 00:54:31 +00:00
|
|
|
void setName( QString const & name_ )
|
2024-11-16 01:31:36 +00:00
|
|
|
{
|
|
|
|
name = name_;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool operator==( InternalPlayerBackend const & other ) const
|
|
|
|
{
|
|
|
|
return name == other.name;
|
|
|
|
}
|
|
|
|
|
|
|
|
bool operator!=( InternalPlayerBackend const & other ) const
|
|
|
|
{
|
|
|
|
return !operator==( other );
|
|
|
|
}
|
|
|
|
|
|
|
|
private:
|
|
|
|
QString name;
|
|
|
|
};
|