- Added -log option to command line

- Added COPYRIGHT VERSION LICENSE marocs in libremediaserver.h
This commit is contained in:
Santi Noreña 2013-03-02 14:26:06 +01:00
parent b877185c0d
commit 794552bdea
6 changed files with 54 additions and 25 deletions

View file

@ -105,17 +105,29 @@ libreMediaServer::libreMediaServer(QStringList args, QWidget *parent)
m_tcpsocket_audio(NULL),
m_gui(FALSE)
{
qDebug() << "******************************************************************************************************";
qDebug() << "********************************************************************************";
qDebug() << QDate::currentDate() << QTime::currentTime();
qDebug() << "Parsing the command line";
// Iniciamos el User Interface
ui.setupUi(this);
// Parse the command line options
if (args.contains("-gui"))
{
qDebug()<< "libremediaserver Constructor option GUI detected";
m_gui = true;
ui.textEdit->appendPlainText("Pure Data GUI's will be shown");
}
// Iniciamos el User Interface
ui.setupUi(this);
// Unix Local Sockets
//Print the version
QString ver;
ver = VERSION;
ui.textEdit->appendPlainText(ver);
ver = COPYRIGHT;
ui.textEdit->appendPlainText(ver);
ver = LICENSE;
ui.textEdit->appendPlainText(ver);
qDebug() << VERSION;
qDebug() << COPYRIGHT;
qDebug() << LICENSE;
// Init Unix Local Sockets
QFile socket(SOCKET);
if (socket.exists())
{
@ -125,7 +137,7 @@ libreMediaServer::libreMediaServer(QStringList args, QWidget *parent)
Q_CHECK_PTR(m_server_vid);
if (!m_server_vid->listen(SOCKET))
{
qErrnoWarning("Init: Can not listen on unix local server");
qErrnoWarning("libremediaserver::constructor L132: Can not listen on unix local server");
}
connect(m_server_vid, SIGNAL(newConnection()),this, SLOT(newPeer()));
// Start preview Timer
@ -199,9 +211,9 @@ libreMediaServer::~libreMediaServer()
delete m_pd_read_audio;
}
socket.remove();
qDebug() << "PD Video starts: " << m_startvideo << " PD Audio starts: " << m_startaudio;
qDebug() << "PD Video restarts: " << m_startvideo << " PD Audio restarts: " << m_startaudio;
qDebug() << QDate::currentDate() << QTime::currentTime();
qDebug() << "******************************************************************************************************";
qDebug() << "********************************************************************************";
return;
}
@ -879,7 +891,7 @@ void libreMediaServer::pdrestart()
return;
}
save_finish();
qDebug()<<"**************************************************************************";
qDebug()<<"********************************************************************************";
qDebug()<<"PD Video Restarts:" << ++m_startvideo;
ui.textEdit->appendPlainText("PD Video Restarting.");
disconnect(m_pd_video, SIGNAL(finished(int)), this, SLOT(pdrestart()));