aboutsummaryrefslogtreecommitdiff
path: root/visualization/renderer/qmpvisrendercore.cpp
diff options
context:
space:
mode:
authorGravatar Chris Xiong <chirs241097@gmail.com> 2020-05-02 23:06:39 +0800
committerGravatar Chris Xiong <chirs241097@gmail.com> 2020-05-02 23:06:39 +0800
commit437b7b16c322a8e53ac55a5f831098494d9a7073 (patch)
treeadb9df613a3c44c74ecdb8ffe01887d88b385248 /visualization/renderer/qmpvisrendercore.cpp
parent3190dcfb79057cea4cdbe86a6354341b9974ee75 (diff)
downloadQMidiPlayer-437b7b16c322a8e53ac55a5f831098494d9a7073.tar.xz
Blindly committed Windows code never worked.
I successfully kept my clean record of zero ports working first try.
Diffstat (limited to 'visualization/renderer/qmpvisrendercore.cpp')
-rw-r--r--visualization/renderer/qmpvisrendercore.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/visualization/renderer/qmpvisrendercore.cpp b/visualization/renderer/qmpvisrendercore.cpp
index c4d1079..b12ed91 100644
--- a/visualization/renderer/qmpvisrendercore.cpp
+++ b/visualization/renderer/qmpvisrendercore.cpp
@@ -9,8 +9,8 @@
#ifdef _WIN32
#include <windows.h>
#define dlopen(a,b) LoadLibraryW(a)
-#define dlsym GetProcAddress
-#define dlclose FreeLibrary
+#define dlsym(a,b) GetProcAddress((HMODULE)a,b)
+#define dlclose(a) FreeLibrary((HMODULE)a)
#else
#include <dlfcn.h>
#endif
@@ -35,13 +35,13 @@ bool qmpVisRenderCore::loadVisualizationLibrary()
{
#ifdef _WIN32
std::vector<std::wstring> libpath={
- QCoreApplication::applicationDirPath().toStdWString()+L"/plugins/libvisualization.dll"
+ QCoreApplication::applicationDirPath().toStdWString()+L"/plugins/libvisualization.dll",
L"libvisualization.dll",
L"../libvisualization.dll"//for debugging only...?
};
#else
std::vector<std::string> libpath={
- QCoreApplication::applicationDirPath().toStdString()+"/plugins/libvisualization.so"
+ QCoreApplication::applicationDirPath().toStdString()+"/plugins/libvisualization.so",
QT_STRINGIFY(INSTALL_PREFIX)+std::string("/lib/qmidiplayer/libvisualization.so"),
"../libvisualization.so"//for debugging only
};