Add backends
- Renamed GfxOpenGL to GfxOPenGL2 - Added GfxOpenGL3 backend for OpenGL 3.3+ - Added WIP DirectX9 backend - Added structure for Citro3D - Added linear Allocator
This commit is contained in:
@@ -3,19 +3,20 @@
|
||||
namespace PD {
|
||||
PD_API std::unique_ptr<GfxDriver> Gfx::driver;
|
||||
|
||||
GfxDriver::GfxDriver(std::string_view name) : DriverInterface(name) {}
|
||||
PD_API GfxDriver::GfxDriver(std::string_view name) : DriverInterface(name) {}
|
||||
|
||||
void GfxDriver::SetViewPort(const ivec2& size) {
|
||||
PD_API void GfxDriver::SetViewPort(const ivec2& size) {
|
||||
ViewPort = size;
|
||||
Projection = Mat4::Ortho(0.f, ViewPort.x, ViewPort.y, 0.f, 1.f, -1.f);
|
||||
}
|
||||
void GfxDriver::SetViewPort(int x, int y) {
|
||||
|
||||
PD_API void GfxDriver::SetViewPort(int x, int y) {
|
||||
ViewPort.x = x;
|
||||
ViewPort.y = y;
|
||||
Projection = Mat4::Ortho(0.f, ViewPort.x, ViewPort.y, 0.f, 1.f, -1.f);
|
||||
}
|
||||
|
||||
void GfxDriver::Reset() {
|
||||
PD_API void GfxDriver::Reset() {
|
||||
CurrentVertex = 0;
|
||||
CurrentIndex = 0;
|
||||
ResetPools();
|
||||
|
||||
Reference in New Issue
Block a user