-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
39 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#include "DllUtils.h" | ||
|
||
#include "SDL.h" | ||
|
||
namespace engine | ||
{ | ||
|
||
void* DllUtils::LoadDll(const char* pFilePath) | ||
{ | ||
return SDL_LoadObject(pFilePath); | ||
} | ||
|
||
void* DllUtils::LoadDllFunction(void* pHandle, const char* pFunctionName) | ||
{ | ||
return SDL_LoadFunction(pHandle, pFunctionName); | ||
} | ||
|
||
void DllUtils::UnloadDll(void* pHandle) | ||
{ | ||
return SDL_UnloadObject(pHandle); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#pragma once | ||
|
||
namespace engine | ||
{ | ||
|
||
class DllUtils | ||
{ | ||
public: | ||
DllUtils() = delete; | ||
|
||
static void* LoadDll(const char* pFilePath); | ||
static void* LoadDllFunction(void* pHandle, const char* pFunctionName); | ||
static void UnloadDll(void* pHandle); | ||
}; | ||
|
||
} |