2011-05-31 19:04:45 +02:00
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
2010-11-06 23:04:47 +01:00
|
|
|
|
// LameXP - Audio Encoder Front-End
|
2013-02-08 23:50:51 +01:00
|
|
|
|
// Copyright (C) 2004-2013 LoRd_MuldeR <MuldeR2@GMX.de>
|
2010-11-06 23:04:47 +01:00
|
|
|
|
//
|
|
|
|
|
// 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.
|
|
|
|
|
//
|
|
|
|
|
// http://www.gnu.org/licenses/gpl-2.0.txt
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
#include "Model_AudioFile.h"
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
#include "Global.h"
|
|
|
|
|
|
2010-11-06 23:04:47 +01:00
|
|
|
|
#include <QTime>
|
2011-01-14 23:34:31 +01:00
|
|
|
|
#include <QObject>
|
2011-03-20 23:32:11 +01:00
|
|
|
|
#include <QMutexLocker>
|
|
|
|
|
#include <QFile>
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
#include <limits.h>
|
2011-05-31 19:04:45 +02:00
|
|
|
|
|
2012-08-22 23:52:55 +02:00
|
|
|
|
const unsigned int AudioFileModel::BITDEPTH_IEEE_FLOAT32 = UINT_MAX-1;
|
|
|
|
|
|
2013-10-13 20:50:12 +02:00
|
|
|
|
#define PRINT_S(VAR) do \
|
|
|
|
|
{ \
|
|
|
|
|
if((VAR).isEmpty()) qDebug(#VAR " = N/A"); else qDebug(#VAR " = \"%s\"", (VAR).toUtf8().constData()); \
|
|
|
|
|
} \
|
|
|
|
|
while(0)
|
|
|
|
|
|
|
|
|
|
#define PRINT_U(VAR) do \
|
|
|
|
|
{ \
|
|
|
|
|
if((VAR) < 1) qDebug(#VAR " = N/A"); else qDebug(#VAR " = %u", (VAR)); \
|
|
|
|
|
} \
|
|
|
|
|
while(0)
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
// Audio File - Meta Info
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
2010-11-06 23:04:47 +01:00
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_MetaInfo::AudioFileModel_MetaInfo(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
reset();
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_MetaInfo::AudioFileModel_MetaInfo(const AudioFileModel_MetaInfo &model)
|
2011-01-14 23:34:31 +01:00
|
|
|
|
{
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_titel = model.m_titel;
|
|
|
|
|
m_artist = model.m_artist;
|
|
|
|
|
m_album = model.m_album;
|
|
|
|
|
m_genre = model.m_genre;
|
|
|
|
|
m_comment = model.m_comment;
|
|
|
|
|
m_cover = model.m_cover;
|
|
|
|
|
m_year = model.m_year;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_position = model.m_position;
|
2011-01-14 23:34:31 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_MetaInfo &AudioFileModel_MetaInfo::operator=(const AudioFileModel_MetaInfo &model)
|
2011-01-14 23:34:31 +01:00
|
|
|
|
{
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_titel = model.m_titel;
|
|
|
|
|
m_artist = model.m_artist;
|
|
|
|
|
m_album = model.m_album;
|
|
|
|
|
m_genre = model.m_genre;
|
|
|
|
|
m_comment = model.m_comment;
|
|
|
|
|
m_cover = model.m_cover;
|
|
|
|
|
m_year = model.m_year;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_position = model.m_position;
|
2011-01-14 23:34:31 +01:00
|
|
|
|
|
|
|
|
|
return (*this);
|
|
|
|
|
}
|
|
|
|
|
|
2013-10-13 20:50:12 +02:00
|
|
|
|
void AudioFileModel_MetaInfo::update(const AudioFileModel_MetaInfo &model, const bool replace)
|
2013-10-12 22:55:41 +02:00
|
|
|
|
{
|
2013-10-13 20:50:12 +02:00
|
|
|
|
if((!model.m_titel.isEmpty()) && (replace || m_titel.isEmpty())) m_titel = model.m_titel;
|
|
|
|
|
if((!model.m_artist.isEmpty()) && (replace || m_artist.isEmpty())) m_artist = model.m_artist;
|
|
|
|
|
if((!model.m_album.isEmpty()) && (replace || m_album.isEmpty())) m_album = model.m_album;
|
|
|
|
|
if((!model.m_genre.isEmpty()) && (replace || m_genre.isEmpty())) m_genre = model.m_genre;
|
|
|
|
|
if((!model.m_comment.isEmpty()) && (replace || m_comment.isEmpty())) m_comment = model.m_comment;
|
|
|
|
|
if((!model.m_cover.isEmpty()) && (replace || m_cover.isEmpty())) m_cover = model.m_cover;
|
|
|
|
|
if((model.m_year > 0) && (replace || (m_year == 0))) m_year = model.m_year;
|
|
|
|
|
if((model.m_position > 0) && (replace || (m_position == 0))) m_position = model.m_position;
|
2013-10-12 22:55:41 +02:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_MetaInfo::~AudioFileModel_MetaInfo(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
/*nothing to do*/
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
void AudioFileModel_MetaInfo::reset(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_titel.clear();
|
|
|
|
|
m_artist.clear();
|
|
|
|
|
m_album.clear();
|
|
|
|
|
m_genre.clear();
|
|
|
|
|
m_comment.clear();
|
|
|
|
|
m_cover.clear();
|
|
|
|
|
m_year = 0;
|
|
|
|
|
m_position = 0;
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-13 20:50:12 +02:00
|
|
|
|
void AudioFileModel_MetaInfo::print(void) const
|
|
|
|
|
{
|
|
|
|
|
PRINT_S(m_titel);
|
|
|
|
|
PRINT_S(m_artist);
|
|
|
|
|
PRINT_S(m_album);
|
|
|
|
|
PRINT_S(m_genre);
|
|
|
|
|
PRINT_S(m_comment);
|
|
|
|
|
PRINT_S(m_cover.filePath());
|
|
|
|
|
PRINT_U(m_year);
|
|
|
|
|
PRINT_U(m_position);
|
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
// Audio File - Technical Info
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
2010-11-06 23:04:47 +01:00
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_TechInfo::AudioFileModel_TechInfo(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
reset();
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_TechInfo::AudioFileModel_TechInfo(const AudioFileModel_TechInfo &model)
|
2011-03-20 23:32:11 +01:00
|
|
|
|
{
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_containerType = model.m_containerType;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_containerProfile = model.m_containerProfile;
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_audioType = model.m_audioType;
|
|
|
|
|
m_audioProfile = model.m_audioProfile;
|
|
|
|
|
m_audioVersion = model.m_audioVersion;
|
|
|
|
|
m_audioEncodeLib = model.m_audioEncodeLib;
|
|
|
|
|
m_audioSamplerate = model.m_audioSamplerate;
|
|
|
|
|
m_audioChannels = model.m_audioChannels;
|
|
|
|
|
m_audioBitdepth = model.m_audioBitdepth;
|
|
|
|
|
m_audioBitrate = model.m_audioBitrate;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_audioBitrateMode = model.m_audioBitrateMode;
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_duration = model.m_duration;
|
2011-03-20 23:32:11 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_TechInfo &AudioFileModel_TechInfo::operator=(const AudioFileModel_TechInfo &model)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_containerType = model.m_containerType;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_containerProfile = model.m_containerProfile;
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_audioType = model.m_audioType;
|
|
|
|
|
m_audioProfile = model.m_audioProfile;
|
|
|
|
|
m_audioVersion = model.m_audioVersion;
|
|
|
|
|
m_audioEncodeLib = model.m_audioEncodeLib;
|
|
|
|
|
m_audioSamplerate = model.m_audioSamplerate;
|
|
|
|
|
m_audioChannels = model.m_audioChannels;
|
|
|
|
|
m_audioBitdepth = model.m_audioBitdepth;
|
|
|
|
|
m_audioBitrate = model.m_audioBitrate;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_audioBitrateMode = model.m_audioBitrateMode;
|
2013-10-13 20:50:12 +02:00
|
|
|
|
m_duration = model.m_duration;
|
2010-11-06 23:04:47 +01:00
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
return (*this);
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel_TechInfo::~AudioFileModel_TechInfo(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
/*nothing to do*/
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
void AudioFileModel_TechInfo::reset(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_containerType.clear();
|
|
|
|
|
m_containerProfile.clear();
|
|
|
|
|
m_audioType.clear();
|
|
|
|
|
m_audioProfile.clear();
|
|
|
|
|
m_audioVersion.clear();
|
|
|
|
|
m_audioEncodeLib.clear();
|
|
|
|
|
m_audioSamplerate = 0;
|
|
|
|
|
m_audioChannels = 0;
|
|
|
|
|
m_audioBitdepth = 0;
|
|
|
|
|
m_audioBitrate = 0;
|
|
|
|
|
m_audioBitrateMode = 0;
|
2013-10-12 22:55:41 +02:00
|
|
|
|
m_duration = 0;
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
////////////////////////////////////////////////////////////
|
|
|
|
|
// Audio File Model
|
|
|
|
|
////////////////////////////////////////////////////////////
|
2010-11-06 23:04:47 +01:00
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel::AudioFileModel(const QString &path)
|
|
|
|
|
:
|
|
|
|
|
m_filePath(path)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_metaInfo.reset();
|
|
|
|
|
m_techInfo.reset();
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel::AudioFileModel(const AudioFileModel &model)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_filePath = model.m_filePath;
|
|
|
|
|
m_metaInfo = model.m_metaInfo;
|
|
|
|
|
m_techInfo = model.m_techInfo;
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel &AudioFileModel::operator=(const AudioFileModel &model)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_filePath = model.m_filePath;
|
|
|
|
|
m_metaInfo = model.m_metaInfo;
|
|
|
|
|
m_techInfo = model.m_techInfo;
|
2010-11-06 23:04:47 +01:00
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
return (*this);
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
AudioFileModel::~AudioFileModel(void)
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
/*nothing to do*/
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
void AudioFileModel::reset(void)
|
2011-05-31 19:04:45 +02:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
m_filePath.clear();
|
|
|
|
|
m_metaInfo.reset();
|
|
|
|
|
m_techInfo.reset();
|
2011-05-31 19:04:45 +02:00
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
/*------------------------------------*/
|
|
|
|
|
/* Helper functions
|
|
|
|
|
/*------------------------------------*/
|
2011-05-31 19:04:45 +02:00
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
const QString AudioFileModel::durationInfo(void) const
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 22:55:41 +02:00
|
|
|
|
if(m_techInfo.duration())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 22:55:41 +02:00
|
|
|
|
QTime time = QTime().addSecs(m_techInfo.duration());
|
2010-11-06 23:04:47 +01:00
|
|
|
|
return time.toString("hh:mm:ss");
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
return QString();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
const QString AudioFileModel::containerInfo(void) const
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(!m_techInfo.containerType().isEmpty())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
QString info = m_techInfo.containerType();
|
|
|
|
|
if(!m_techInfo.containerProfile().isEmpty()) info.append(QString(" (%1: %2)").arg(tr("Profile"), m_techInfo.containerProfile()));
|
2010-11-06 23:04:47 +01:00
|
|
|
|
return info;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
return QString();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
const QString AudioFileModel::audioBaseInfo(void) const
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(m_techInfo.audioSamplerate() || m_techInfo.audioChannels() || m_techInfo.audioBitdepth())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
|
|
|
|
QString info;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(m_techInfo.audioChannels())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
|
|
|
|
if(!info.isEmpty()) info.append(", ");
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString("%1: %2").arg(tr("Channels"), QString::number(m_techInfo.audioChannels())));
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(m_techInfo.audioSamplerate())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
|
|
|
|
if(!info.isEmpty()) info.append(", ");
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString("%1: %2 Hz").arg(tr("Samplerate"), QString::number(m_techInfo.audioSamplerate())));
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(m_techInfo.audioBitdepth())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
|
|
|
|
if(!info.isEmpty()) info.append(", ");
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(m_techInfo.audioBitdepth() == BITDEPTH_IEEE_FLOAT32)
|
2012-08-22 23:52:55 +02:00
|
|
|
|
{
|
|
|
|
|
info.append(QString("%1: %2 Bit (IEEE Float)").arg(tr("Bitdepth"), QString::number(32)));
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString("%1: %2 Bit").arg(tr("Bitdepth"), QString::number(m_techInfo.audioBitdepth())));
|
2012-08-22 23:52:55 +02:00
|
|
|
|
}
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
|
|
|
|
return info;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
return QString();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2013-10-12 20:38:07 +02:00
|
|
|
|
const QString AudioFileModel::audioCompressInfo(void) const
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(!m_techInfo.audioType().isEmpty())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
|
|
|
|
QString info;
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(!m_techInfo.audioProfile().isEmpty() || !m_techInfo.audioVersion().isEmpty())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2011-01-14 23:34:31 +01:00
|
|
|
|
info.append(QString("%1: ").arg(tr("Type")));
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(m_techInfo.audioType());
|
|
|
|
|
if(!m_techInfo.audioProfile().isEmpty())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString(", %1: %2").arg(tr("Profile"), m_techInfo.audioProfile()));
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(!m_techInfo.audioVersion().isEmpty())
|
2010-11-06 23:04:47 +01:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString(", %1: %2").arg(tr("Version"), m_techInfo.audioVersion()));
|
2010-11-06 23:04:47 +01:00
|
|
|
|
}
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(m_techInfo.audioBitrate() > 0)
|
2011-05-31 19:04:45 +02:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
switch(m_techInfo.audioBitrateMode())
|
2011-05-31 19:04:45 +02:00
|
|
|
|
{
|
|
|
|
|
case BitrateModeConstant:
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString(", %1: %2 kbps (%3)").arg(tr("Bitrate"), QString::number(m_techInfo.audioBitrate()), tr("Constant")));
|
2011-05-31 19:04:45 +02:00
|
|
|
|
break;
|
|
|
|
|
case BitrateModeVariable:
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(WCHAR2QSTR(L", %1: \u2248%2 kbps (%3)").arg(tr("Bitrate"), QString::number(m_techInfo.audioBitrate()), tr("Variable")));
|
2011-05-31 19:04:45 +02:00
|
|
|
|
break;
|
|
|
|
|
default:
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString(", %1: %2 kbps").arg(tr("Bitrate"), QString::number(m_techInfo.audioBitrate())));
|
2011-05-31 19:04:45 +02:00
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
2013-10-12 20:38:07 +02:00
|
|
|
|
if(!m_techInfo.audioEncodeLib().isEmpty())
|
2012-08-01 00:17:12 +02:00
|
|
|
|
{
|
2013-10-12 20:38:07 +02:00
|
|
|
|
info.append(QString(", %1: %2").arg(tr("Encoder"), m_techInfo.audioEncodeLib()));
|
2012-08-01 00:17:12 +02:00
|
|
|
|
}
|
2010-11-06 23:04:47 +01:00
|
|
|
|
return info;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
return QString();
|
|
|
|
|
}
|
|
|
|
|
}
|