Commit a2b5910e authored by Dipl.-Ing. Jonas Stienen's avatar Dipl.-Ing. Jonas Stienen
Browse files

Adding dialog

parents 0bb4d113 313615a2
......@@ -50,9 +50,24 @@ if( NOT WIN32 )
add_definitions( -std=gnu++11 )
endif( )
set( Redstart_Sources
"src/main.cpp"
"src/RedstartWindow.cpp"
"src/RedstartWindow.h"
"src/RedstartRunSimpleExample.h"
"src/RedstartUtils.h"
"src/RedstartSessionBinauralHeadphonesDialog.cpp"
"src/RedstartSessionBinauralHeadphonesDialog.h"
)
set( Redstart_UIs
"ui/RedstartWindow.ui"
"ui/RedstartSessionBinauralHeadphonesDialog.ui"
)
# Qt UI form compiler
qt5_wrap_ui( "ui_RedstartWindow.h" "ui/RedstartWindow.ui" )
qt5_wrap_ui( "ui_RedstartSessionBinauralHeadphonesDialog.h" "ui/RedstartSessionBinauralHeadphonesDialog.ui" )
include_directories( "${CMAKE_CURRENT_BINARY_DIR}" ) # Qt UI form compiler generates files into this folder
......@@ -61,7 +76,7 @@ include_directories( "${CMAKE_CURRENT_BINARY_DIR}" ) # Qt UI form compiler gener
qt5_add_resources( VA_REDSTART_RESOURCES "res/QRedstart.qrc" OPTIONS -compress 3 )
add_executable( Redstart ${VA_REDSTART_RESOURCES} "src/main.cpp" "src/RedstartWindow.cpp" "src/RedstartWindow.h" "src/RedstartUtils.h" "ui/RedstartWindow.ui" )
add_executable( Redstart ${VA_REDSTART_RESOURCES} ${Redstart_Sources} ${Redstart_UIs} )
target_link_libraries( Redstart ${VISTA_USE_PACKAGE_LIBRARIES} ${VISTAINTERPROCCOMM_ADDITIONAL_DEPENDENCIES} Qt5::Widgets )
install( TARGETS Redstart RUNTIME DESTINATION "bin" )
......
/*
* --------------------------------------------------------------------------------------------
*
* VVV VVV A Virtual Acoustics (VA) | http://www.virtualacoustics.org
* VVV VVV AAA Licensed under the Apache License, Version 2.0
* VVV VVV AAA
* VVV VVV AAA Copyright 2015-2017
* VVVVVV AAA Institute of Technical Acoustics (ITA)
* VVVV AAA RWTH Aachen University
*
* --------------------------------------------------------------------------------------------
*/
#ifndef IW_REDSTART_RUN_SIMPLE_EXAMPLE
#define IW_REDSTART_RUN_SIMPLE_EXAMPLE
#include <VA.h>
inline void RunSimpleExample( IVAInterface* pVA )
{
const std::string sSignalSourceID = pVA->CreateSignalSourceBufferFromFile( "$(DemoSound)" );
pVA->SetSignalSourceBufferPlaybackAction( sSignalSourceID, IVAInterface::VA_PLAYBACK_ACTION_PLAY );
pVA->SetSignalSourceBufferLooping( sSignalSourceID, true );
const int iSoundSourceID = pVA->CreateSoundSource( "Redstart C++ example sound source" );
pVA->SetSoundSourcePose( iSoundSourceID, VAVec3( 2.0f, 1.7f, 2.0f ), VAQuat( 0.0f, 0.0f, 0.0f, 1.0f ) );
pVA->SetSoundSourceSignalSource( iSoundSourceID, sSignalSourceID );
const int iHRIR = pVA->CreateDirectivityFromFile( "$(DefaultHRIR)" );
const int iSoundReceiverID = pVA->CreateSoundReceiver( "Redstart C++ example sound receiver" );
pVA->SetSoundReceiverPose( iSoundReceiverID, VAVec3( 0.0f, 1.7f, 0.0f ), VAQuat( 0.0f, 0.0f, 0.0f, 1.0f ) );
pVA->SetSoundReceiverDirectivity( iSoundReceiverID, iHRIR );
};
#endif // IW_REDSTART_RUN_SIMPLE_EXAMPLE
/*
* --------------------------------------------------------------------------------------------
*
* VVV VVV A Virtual Acoustics (VA) | http://www.virtualacoustics.org
* VVV VVV AAA Licensed under the Apache License, Version 2.0
* VVV VVV AAA
* VVV VVV AAA Copyright 2015-2017
* VVVVVV AAA Institute of Technical Acoustics (ITA)
* VVVV AAA RWTH Aachen University
*
* --------------------------------------------------------------------------------------------
*/
#include "RedstartSessionBinauralHeadphonesDialog.h"
#include <ui_RedstartSessionBinauralHeadphonesDialog.h>
RedstartSessionBinauralHeadphonesDialog::RedstartSessionBinauralHeadphonesDialog( QWidget *parent )
: QDialog( parent ),
ui( new Ui::RedstartDialogSessionBinauralHeadphones )
{
ui->setupUi( this );
}
RedstartSessionBinauralHeadphonesDialog::~RedstartSessionBinauralHeadphonesDialog()
{
//m_qSettings.setValue( "Redstart/Sessions/", ui->checkBox_IncludeAllChannels->checkState() );
}
QVariantHash RedstartSessionBinauralHeadphonesDialog::GetCoreConfig() const
{
QVariantHash oHash;
//ui->line
return oHash;
}
/*
* --------------------------------------------------------------------------------------------
*
* VVV VVV A Virtual Acoustics (VA) | http://www.virtualacoustics.org
* VVV VVV AAA Licensed under the Apache License, Version 2.0
* VVV VVV AAA
* VVV VVV AAA Copyright 2015-2017
* VVVVVV AAA Institute of Technical Acoustics (ITA)
* VVVV AAA RWTH Aachen University
*
* --------------------------------------------------------------------------------------------
*/
#ifndef IW_REDSTART_SESSION_BINAURAL_HEADPHONES_DIALOG
#define IW_REDSTART_SESSION_BINAURAL_HEADPHONES_DIALOG
#include <QDialog>
#include <QDir>
#include <QString>
#include <QSettings>
#include <QHash>
namespace Ui
{
class RedstartDialogSessionBinauralHeadphones;
}
class RedstartSessionBinauralHeadphonesDialog : public QDialog
{
Q_OBJECT
public:
explicit RedstartSessionBinauralHeadphonesDialog( QWidget *parent );
~RedstartSessionBinauralHeadphonesDialog();
QVariantHash GetCoreConfig() const;
private:
Ui::RedstartDialogSessionBinauralHeadphones* ui;
QDir m_oBasePath;
QString m_sFileBaseName;
QSettings m_qSettings;
};
#endif // IW_REDSTART_SESSION_BINAURAL_HEADPHONES_DIALOG
......@@ -19,15 +19,20 @@
#include "RedstartWindow.h"
#include <ui_RedstartWindow.h>
#include "RedstartRunSimpleExample.h"
#include "RedstartSessionBinauralHeadphonesDialog.h"
#include "RedstartUtils.h"
#include <VA.h>
#include <VACore.h>
#include <VANet.h>
#include <ITAAsioInterface.h>
#include <ITAPortaudioInterface.h>
#include <ITAException.h>
RedstartWindow::RedstartWindow( bool bFailSafeMode, bool bAutoStart, QWidget* pParent )
RedstartWindow::RedstartWindow( bool bFailSafeMode, bool bAutoStart, bool bSkipConfig, QWidget* pParent )
: QMainWindow( pParent )
, ui( new Ui::RedstartWindow )
, m_pVAInterface( NULL )
......@@ -37,7 +42,22 @@ RedstartWindow::RedstartWindow( bool bFailSafeMode, bool bAutoStart, QWidget* pP
m_pVANetServer = IVANetServer::Create();
m_pVANetClient = IVANetClient::Create();
LoadConfiguration();
ui->comboBox_audio_driver->addItem( "ASIO" );
ui->comboBox_audio_driver->addItem( "Portaudio" );
ui->comboBox_audio_iface_sampling_rate->addItem( "44.1 kHz", AudioSamplingRate::FS_44kHz );
ui->comboBox_audio_iface_sampling_rate->addItem( "48 kHz", AudioSamplingRate::FS_48kHz );
//ui->comboBox_audio_iface_sampling_rate->addItem( "96 kHz", AudioSamplingRate::FS_96kHz );
ui->comboBox_audio_iface_buffer_size->addItem( "AUTO", AudioBufferSize::AUTO );
m_iPortaudioDefaultDevice = -1;
if( !bSkipConfig )
LoadConfiguration();
if( ui->checkBox_redstart_network_connect_as_client->isChecked() )
ui->groupBox_redstart_audio_iface->setEnabled( false );
if( ( ui->checkBox_redstart_auto_start->isChecked() || bAutoStart ) && !bFailSafeMode )
on_pushButton_start_stop_clicked();
......@@ -64,29 +84,16 @@ void RedstartWindow::LoadConfiguration()
{
RestoreWindowSize();
ui->comboBox_audio_driver->addItem( "ASIO" );
ui->comboBox_audio_driver->addItem( "Portaudio" );
bool bValOK;
int iAudioBackend = m_qSettings.value( "Redstart/audio/backend_idx" ).toInt( &bValOK );
if( !bValOK )
iAudioBackend = AudioBackend::ASIO;
ui->comboBox_audio_driver->setCurrentIndex( iAudioBackend );
if( iAudioBackend == AudioBackend::PORTAUDIO )
PopulatePortaudioDevicesFromSettings();
else
PopulateAsioDevicesFromSettings();
ui->comboBox_audio_iface_buffer_size->addItem( "AUTO", AudioBufferSize::AUTO );
const int iBufferSizeIndex = m_qSettings.value( "Redstart/audio/buffersize_idx" ).toInt( &bValOK );
if( bValOK && iBufferSizeIndex < ui->comboBox_audio_iface_buffer_size->count() )
ui->comboBox_audio_iface_buffer_size->setCurrentIndex( iBufferSizeIndex );
ui->comboBox_audio_iface_sampling_rate->addItem( "44.1 kHz", AudioSamplingRate::FS_44kHz );
ui->comboBox_audio_iface_sampling_rate->addItem( "48 kHz", AudioSamplingRate::FS_48kHz );
//ui->comboBox_audio_iface_sampling_rate->addItem( "96 kHz", AudioSamplingRate::FS_96kHz );
const int iSamplingRateIndex = m_qSettings.value( "Redstart/audio/fs_idx" ).toInt( &bValOK );
if( bValOK && iSamplingRateIndex < ui->comboBox_audio_iface_sampling_rate->count() )
ui->comboBox_audio_iface_sampling_rate->setCurrentIndex( iSamplingRateIndex );
......@@ -100,6 +107,23 @@ void RedstartWindow::LoadConfiguration()
if( m_qSettings.contains( "Redstart/autostart" ) )
ui->checkBox_redstart_auto_start->setChecked( m_qSettings.value( "Redstart/autostart" ).toBool() );
m_iPortaudioDefaultDevice = m_qSettings.value( "Redstart/audio/portaudio_default_device", -1 ).toInt();
ui->checkBox_portaudio_default_device->setChecked( m_qSettings.value( "Redstart/audio/portaudio_use_default_device", true ).toBool() );
QVariantList voAudioDevices;
voAudioDevices = m_qSettings.value( "Redstart/audio/devicelist" ).toList();
for( const QVariant oAudioDevice : voAudioDevices )
m_voAudioDevices.push_back( CAudioDeviceSpecs( oAudioDevice.toHash() ) );
PopulateAudioDevices();
int iLastDevice = m_qSettings.value( "Redstart/audio/current_device", 0 ).toInt( &bValOK );
if( bValOK && ui->comboBox_audio_iface_device->count() >= iLastDevice )
ui->comboBox_audio_iface_device->setCurrentIndex( iLastDevice );
// Core control
ui->comboBox_core_settings_log_level->addItem( QString::fromStdString( m_pVAInterface->GetLogLevelStr( IVAInterface::VA_LOG_LEVEL_QUIET ) ) );
ui->comboBox_core_settings_log_level->addItem( QString::fromStdString( m_pVAInterface->GetLogLevelStr( IVAInterface::VA_LOG_LEVEL_ERROR ) ) );
......@@ -107,6 +131,7 @@ void RedstartWindow::LoadConfiguration()
ui->comboBox_core_settings_log_level->addItem( QString::fromStdString( m_pVAInterface->GetLogLevelStr( IVAInterface::VA_LOG_LEVEL_INFO ) ) );
ui->comboBox_core_settings_log_level->addItem( QString::fromStdString( m_pVAInterface->GetLogLevelStr( IVAInterface::VA_LOG_LEVEL_VERBOSE ) ) );
ui->comboBox_core_settings_log_level->addItem( QString::fromStdString( m_pVAInterface->GetLogLevelStr( IVAInterface::VA_LOG_LEVEL_TRACE ) ) );
}
void RedstartWindow::StoreConfiguration()
......@@ -128,142 +153,23 @@ void RedstartWindow::StoreConfiguration()
m_qSettings.setValue( "Redstart/network/client_mode", ui->checkBox_redstart_network_connect_as_client->isChecked() );
m_qSettings.setValue( "Redstart/autostart", ui->checkBox_redstart_auto_start->isChecked() );
}
void RedstartWindow::on_actionQuit_triggered()
{
close();
}
void RedstartWindow::on_pushButton_start_stop_clicked()
{
try
{
if( !ui->checkBox_redstart_network_connect_as_client->isChecked() )
{
if( m_pVAInterface )
{
m_pVANetServer->Finalize();
if( m_pVAInterface->GetState() == IVAInterface::VA_CORESTATE_READY )
m_pVAInterface->Finalize();
delete m_pVAInterface;
m_pVAInterface = nullptr;
ui->statusBar->showMessage( "VA core has been stopped." );
PostCoreStop();
}
else
{
// @todo get config from session
CVAStruct oVAConfigArgs = VACore::GetCoreConfigFromFile( "../VACore/conf/VACore.ini" );
QHash<QString, QVariant> oHash, oHash2;
oHash[ QString( "test" ) ] = int(1);
oHash[ QString( "test2" ) ] = QHash< QString, QVariant >();
m_qSettings.setValue( "sessions_test", oHash );
m_qSettings.sync();
oHash2 = m_qSettings.value( "sessions_test" ).toHash();
int c = oHash2.count();
bool bOK2;
int iTest = oHash[ QString( "test" ) ].toInt( &bOK2 );
int iTest2 = oHash2[ QString( "test" ) ].toInt( &bOK2 );
std::string sBackend, sDevice;
// Override configs
switch( ui->comboBox_audio_driver->currentIndex() )
{
case AudioBackend::ASIO:
{
sBackend = "ASIO";
sDevice = ui->comboBox_audio_iface_device->currentText().toStdString();
break;
}
case AudioBackend::PORTAUDIO:
default:
{
sBackend = "Portaudio";
if( ui->checkBox_portaudio_default_device->isChecked() )
sDevice = "default";
else
sDevice = ui->comboBox_audio_iface_device->currentIndex();
}
}
oVAConfigArgs[ "Audio driver" ] = CVAStruct();
oVAConfigArgs[ "Audio driver" ][ "Driver" ] = sBackend;
oVAConfigArgs[ "Audio driver" ][ "Device" ] = sDevice;
oVAConfigArgs[ "Paths" ][ "redstart_data" ] = "../VACore/data";
m_pVAInterface = VACore::CreateCoreInstance( oVAConfigArgs );
m_pVAInterface->Initialize();
// @todo attach event handler
//m_pVAInterface->AttachEventHandler( this );
m_pVANetServer->SetCoreInstance( m_pVAInterface );
bool bOK;
int iPort = ui->lineEdit_redstart_network_port->text().toInt( &bOK );
int iStatus = -1;
if( bOK )
iStatus = m_pVANetServer->Initialize( ui->lineEdit_redstart_network_address->text().toStdString(), iPort );
else
iStatus = m_pVANetServer->Initialize( ui->lineEdit_redstart_network_address->text().toStdString() );
if( m_pVAInterface->GetState() == IVAInterface::VA_CORESTATE_READY && iStatus == IVANetServer::VA_NO_ERROR )
{
ui->statusBar->showMessage( "VA core successfully initialized and network server started." );
PostCoreStart();
}
else
{
ui->statusBar->showMessage( "VA core initialization failed." );
m_pVANetServer->Finalize();
delete m_pVAInterface;
m_pVAInterface = NULL;
}
}
}
else
{
// Client mode
if( m_pVANetClient->IsConnected() )
m_pVANetClient->Disconnect();
m_qSettings.setValue( "Redstart/audio/portaudio_default_device", m_iPortaudioDefaultDevice );
int iLastDevice = ui->comboBox_audio_iface_device->currentIndex();
m_qSettings.setValue( "Redstart/audio/current_device", iLastDevice );
m_pVAInterface = NULL;
m_qSettings.setValue( "Redstart/audio/portaudio_use_default_device", ui->checkBox_portaudio_default_device->isChecked() );
bool bOK;
int iPort = ui->lineEdit_redstart_network_port->text().toInt( &bOK );
int iStatus = -1;
if( bOK )
iStatus = m_pVANetClient->Initialize( ui->lineEdit_redstart_network_address->text().toStdString(), iPort );
else
iStatus = m_pVANetClient->Initialize( ui->lineEdit_redstart_network_address->text().toStdString() );
if( iStatus != IVANetClient::VA_NO_ERROR )
{
VA_EXCEPT2( INVALID_PARAMETER, "Could not initialize client, connection failed." );
}
QVariantList voAudioDevices;
for( const CAudioDeviceSpecs& oDevice : m_voAudioDevices )
voAudioDevices.push_back( oDevice.asHash() );
m_pVAInterface = m_pVANetClient->GetCoreInstance();
m_qSettings.setValue( "Redstart/audio/devicelist", voAudioDevices );
}
// @todo attach event handler
//m_pVANetClient->AttachEventHandler( this );
}
}
catch( const CVAException& ex )
{
ui->statusBar->showMessage( QString::fromStdString( ex.ToString() ) );
ui->checkBox_redstart_auto_start->setChecked( false );
}
void RedstartWindow::on_actionQuit_triggered()
{
close();
}
void RedstartWindow::PostCoreStart()
......@@ -277,7 +183,7 @@ void RedstartWindow::PostCoreStart()
ui->groupBox_core->setEnabled( true );
ui->groupBox_paths->setEnabled( true );
ui->groupBox_macros->setEnabled( true );
ui->menuRun->setEnabled( true );
CVAVersionInfo oVersion;
m_pVAInterface->GetVersionInfo( &oVersion );
......@@ -302,6 +208,7 @@ void RedstartWindow::PostCoreStop()
ui->groupBox_core->setEnabled( false );
ui->groupBox_paths->setEnabled( false );
ui->groupBox_macros->setEnabled( false );
ui->menuRun->setEnabled( false );
}
void RedstartWindow::RestoreWindowSize()
......@@ -312,6 +219,8 @@ void RedstartWindow::RestoreWindowSize()
void RedstartWindow::AcquireAsioDevices()
{
std::vector< CAudioDeviceSpecs > voAudioDevices = m_voAudioDevices;
try
{
ITAsioInitializeLibrary();
......@@ -337,7 +246,7 @@ void RedstartWindow::AcquireAsioDevices()
long out = 0;
ITAsioGetChannels( &in, &out );
oDeviceSpecs.iNumInputChannels = int( in );
oDeviceSpecs.iNumInputChannels = int( out );
oDeviceSpecs.iNumOutputChannels = int( out );
ITAsioFinalizeDriver();
......@@ -363,11 +272,10 @@ void RedstartWindow::AcquireAsioDevices()
oErrMsg.showMessage( sErrorMessage );
oErrMsg.exec();
}
}
void RedstartWindow::PopulateAsioDevicesFromSettings()
{
for( const CAudioDeviceSpecs oDevice : voAudioDevices )
if( oDevice.iBackend != AudioBackend::ASIO )
m_voAudioDevices.push_back( oDevice );
}
void RedstartWindow::PopulateAudioDevices()
......@@ -385,6 +293,8 @@ void RedstartWindow::PopulateAudioDevices()
ui->checkBox_portaudio_default_device->setEnabled( true );
if( ui->checkBox_portaudio_default_device->isChecked() )
ui->comboBox_audio_iface_device->setEnabled( false );
else
ui->comboBox_audio_iface_device->setEnabled( true );
}
else
{
......@@ -395,12 +305,181 @@ void RedstartWindow::PopulateAudioDevices()
void RedstartWindow::AcquirePortaudioDevices()
{
std::vector< CAudioDeviceSpecs > voAudioDevices = m_voAudioDevices;
try
{
ITAPortaudioInterface oPortaudio( 44100, 1024 );
oPortaudio.Initialize();
int lDrivers = oPortaudio.GetNumDevices();
if( lDrivers <= 0 )
ITA_EXCEPT1( INVALID_PARAMETER, "No Portaudio output devices could be found on this system." );
m_iPortaudioDefaultDevice = oPortaudio.GetDefaultOutputDevice();
m_voAudioDevices.clear();
for( long i = 0; i < lDrivers; i++ )
{
CAudioDeviceSpecs oDeviceSpecs;
oDeviceSpecs.iDriverNumber = i;
oDeviceSpecs.iBackend = AudioBackend::PORTAUDIO;
oDeviceSpecs.sName = oPortaudio.GetDeviceName( i ).c_str();
try
{
oPortaudio.GetNumChannels( i, oDeviceSpecs.iNumInputChannels, oDeviceSpecs.iNumOutputChannels );
oDeviceSpecs.bInitializable = true; // only a guess
if( i == oPortaudio.GetDefaultOutputDevice() )
oDeviceSpecs.bDefaultDevice = true;
else
oDeviceSpecs.bDefaultDevice = false;
}
catch( const ITAException& )
{
oDeviceSpecs.bInitializable = false;
continue;
}
if( oDeviceSpecs.bInitializable )
m_voAudioDevices.push_back( oDeviceSpecs );
}
oPortaudio.Finalize();
}
catch( const ITAException& e )
{
QString sErrorMessage = QString( "Error during Portaudio device acquisition: %1" ).arg( QString::fromStdString( e.ToString() ) );
QErrorMessage oErrMsg;
oErrMsg.showMessage( sErrorMessage );
oErrMsg.exec();
}
for( const CAudioDeviceSpecs oDevice : voAudioDevices )
if( oDevice.iBackend != AudioBackend::ASIO )
m_voAudioDevices.push_back( oDevice );
}
void RedstartWindow::PopulatePortaudioDevicesFromSettings()
void RedstartWindow::on_pushButton_start_stop_clicked()
{
try
{
if( !ui->checkBox_redstart_network_connect_as_client->isChecked() )
{
if( m_pVAInterface )
{
m_pVANetServer->Finalize();
if( m_pVAInterface->GetState() == IVAInterface::VA_CORESTATE_READY )
m_pVAInterface->Finalize();
delete m_pVAInterface;
m_pVAInterface = nullptr;
ui->statusBar->showMessage( "VA core has been stopped." );
PostCoreStop();
}
else
{
// @todo get config from session
CVAStruct oVAConfigArgs = VACore::GetCoreConfigFromFile( "../VACore/conf/VACore.ini" );
// Override configs
std::string sBackend, sDevice;
switch( ui->comboBox_audio_driver->currentIndex() )
{
case AudioBackend::ASIO:
{
sBackend = "ASIO";
sDevice = ui->comboBox_audio_iface_device->currentText().toStdString();
break;
}
case AudioBackend::PORTAUDIO:
default:
{
sBackend = "Portaudio";
if( ui->checkBox_portaudio_default_device->isChecked() )
sDevice = "default";
else
sDevice = ui->comboBox_audio_iface_device->currentIndex();
}
}
oVAConfigArgs[ "Audio driver" ] = CVAStruct();
oVAConfigArgs[ "Audio driver" ][ "Driver" ] = sBackend;
oVAConfigArgs[ "Audio driver" ][ "Device" ] = sDevice;
oVAConfigArgs[ "Paths" ][ "redstart_data" ] = "../VACore/data";
m_pVAInterface = VACore::CreateCoreInstance( oVAConfigArgs );
m_pVAInterface->Initialize();
// @todo attach event handler
//m_pVAInterface->AttachEventHandler( this );
m_pVANetServer->SetCoreInstance( m_pVAInterface );
bool bOK;
int iPort = ui->lineEdit_redstart_network_port->text().toInt( &bOK );
int iStatus = -1;
if( bOK )
iStatus = m_pVANetServer->Initialize( ui->lineEdit_redstart_network_address->text().toStdString(), iPort );
else
iStatus = m_pVANetServer->Initialize( ui->lineEdit_redstart_network_address->text().toStdString() );
if( m_pVAInterface->GetState() == IVAInterface::VA_CORESTATE_READY && iStatus == IVANetServer::VA_NO_ERROR )
{
ui->statusBar->showMessage( "VA core successfully initialized and network server started." );
PostCoreStart();
}
else
{
ui->statusBar->showMessage( "VA core initialization failed." );
m_pVANetServer->Finalize();
delete m_pVAInterface;
m_pVAInterface = NULL;
}
}
}
else
{
// Client mode