Skip to content

Commit

Permalink
Improve STK rawwave path encoding handling
Browse files Browse the repository at this point in the history
Still incomplete on Windows due to an upstream issue
  • Loading branch information
PhysSong committed Jun 4, 2018
1 parent 0c794b5 commit e162527
Showing 1 changed file with 18 additions and 3 deletions.
21 changes: 18 additions & 3 deletions plugins/stk/mallets/mallets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,12 @@ malletsSynth::malletsSynth( const StkFloat _pitch,
{
Stk::setSampleRate( _sample_rate );
Stk::setRawwavePath( QDir( ConfigManager::inst()->stkDir() ).absolutePath()
.toLatin1().constData() );
#ifdef LMMS_BUILD_WIN32
.toLocal8Bit().constData() );
#else
.toUtf8().constData() );
#endif

#ifndef LMMS_DEBUG
Stk::showWarnings( false );
#endif
Expand Down Expand Up @@ -670,7 +675,12 @@ malletsSynth::malletsSynth( const StkFloat _pitch,
{
Stk::setSampleRate( _sample_rate );
Stk::setRawwavePath( QDir( ConfigManager::inst()->stkDir() ).absolutePath()
.toLatin1().constData() );
#ifdef LMMS_BUILD_WIN32
.toLocal8Bit().constData() );
#else
.toUtf8().constData() );
#endif

#ifndef LMMS_DEBUG
Stk::showWarnings( false );
#endif
Expand Down Expand Up @@ -718,7 +728,12 @@ malletsSynth::malletsSynth( const StkFloat _pitch,
{
Stk::setSampleRate( _sample_rate );
Stk::setRawwavePath( QDir( ConfigManager::inst()->stkDir() ).absolutePath()
.toLatin1().constData() );
#ifdef LMMS_BUILD_WIN32
.toLocal8Bit().constData() );
#else
.toUtf8().constData() );
#endif

#ifndef LMMS_DEBUG
Stk::showWarnings( false );
#endif
Expand Down

0 comments on commit e162527

Please sign in to comment.