Load at3plus decoders through "at3plusdecoder64.dll" under win64.

This way 32 and 64-bit builds can coexist in the same folder.
This commit is contained in:
Henrik Rydgard 2013-05-30 13:58:10 +02:00
parent 169ca97377
commit 820fd52c48

View File

@ -25,7 +25,12 @@ namespace Atrac3plus_Decoder {
int initdecoder() { int initdecoder() {
#ifdef _WIN32 #ifdef _WIN32
#ifdef _M_X64
hlib = LoadLibraryA("at3plusdecoder64.dll");
#else
hlib = LoadLibraryA("at3plusdecoder.dll"); hlib = LoadLibraryA("at3plusdecoder.dll");
#endif
if (hlib) { if (hlib) {
frame_decoder = (ATRAC3PLUS_DECODEFRAME)GetProcAddress(hlib, "Atrac3plusDecoder_decodeFrame"); frame_decoder = (ATRAC3PLUS_DECODEFRAME)GetProcAddress(hlib, "Atrac3plusDecoder_decodeFrame");
open_context = (ATRAC3PLUS_OPENCONTEXT)GetProcAddress(hlib, "Atrac3plusDecoder_openContext"); open_context = (ATRAC3PLUS_OPENCONTEXT)GetProcAddress(hlib, "Atrac3plusDecoder_openContext");