26 lines
497 B
C++
26 lines
497 B
C++
#pragma once
|
|
|
|
#define GLFW_INCLUDE_VULKAN
|
|
#include <GLFW/glfw3.h>
|
|
|
|
class CoreInstance;
|
|
|
|
class RenderEngineBase
|
|
{
|
|
GLFWwindow* window_ = nullptr;
|
|
|
|
public:
|
|
explicit RenderEngineBase();
|
|
virtual ~RenderEngineBase();
|
|
|
|
virtual void start() = 0;
|
|
virtual void stop_render() const = 0;
|
|
|
|
GLFWwindow* get_window() const { return window_; }
|
|
};
|
|
|
|
#define RENDER_ENGINE_FACTORY_GENERATE(Class) \
|
|
RenderEngineBase* RenderEngineFactory(CoreInstance& core) {\
|
|
return new Class(core); \
|
|
}
|