write shit
This commit is contained in:
35
BasaltPresenter/Presenter/dll_loader.hpp
Normal file
35
BasaltPresenter/Presenter/dll_loader.hpp
Normal file
@@ -0,0 +1,35 @@
|
||||
#include <basalt_char.hpp>
|
||||
#include <string_view>
|
||||
|
||||
#if defined(BASALT_OS_WINDOWS)
|
||||
#include <Windows.h>
|
||||
#else
|
||||
#include <dlfcn.h>
|
||||
#endif
|
||||
|
||||
namespace Basalt::Presenter {
|
||||
|
||||
enum class DllKind {
|
||||
RenderEngine,
|
||||
DataDeliver,
|
||||
ObjectLoader,
|
||||
AnimationLoader,
|
||||
};
|
||||
|
||||
class DllLoader {
|
||||
public:
|
||||
#if defined(BASALT_OS_WINDOWS)
|
||||
using Handle = HMODULE;
|
||||
#else
|
||||
using Handle = void *;
|
||||
#endif
|
||||
|
||||
public:
|
||||
DllLoader(DllKind kind, const std::basic_string_view<BSCHAR> filename);
|
||||
~DllLoader();
|
||||
|
||||
private:
|
||||
Handle m_Handle;
|
||||
};
|
||||
|
||||
} // namespace Basalt::Presenter
|
||||
Reference in New Issue
Block a user