From 437b7b16c322a8e53ac55a5f831098494d9a7073 Mon Sep 17 00:00:00 2001 From: Chris Xiong Date: Sat, 2 May 2020 23:06:39 +0800 Subject: Blindly committed Windows code never worked. I successfully kept my clean record of zero ports working first try. --- visualization/renderer/qmpvisrendercore.cpp | 8 ++++---- 1 file 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 #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 #endif @@ -35,13 +35,13 @@ bool qmpVisRenderCore::loadVisualizationLibrary() { #ifdef _WIN32 std::vector 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 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 }; -- cgit v1.2.3