hyporo-cpp/source/hyporo/window_system/window_context.hpp

45 lines
544 B
C++
Raw Normal View History

2022-10-27 22:27:50 +05:00
#pragma once
namespace hpr::gpu
{
class WindowContext
{
public:
enum class Provider
{
Unknown,
GLFW
};
private:
Provider p_provider;
public:
inline
WindowContext() :
p_provider {Provider::Unknown}
{}
inline
WindowContext(Provider provider) :
p_provider {provider}
{}
virtual
~WindowContext() = default;
2022-10-28 21:16:03 +05:00
bool checkCompability(const WindowContext* ctx) const
{
return (ctx != nullptr) ? ctx->p_provider == p_provider : true;
}
2022-10-27 22:27:50 +05:00
};
}