Add HidDriver base and small HidGLFW driver
This commit is contained in:
@@ -88,9 +88,12 @@ int main(int argc, char** argv) {
|
||||
pList.SetFont(&font);
|
||||
App app(font);
|
||||
while (pOs->Mainloop()) {
|
||||
PD::Hid::Update();
|
||||
pOs->ClearViewPort();
|
||||
PD::Li::ResetPools(); // Move to other place (or refactor this)
|
||||
app.Update(pOs->GetViewport(), pList);
|
||||
pList.DrawText(5, std::format("Mouse: {}", PD::Hid::MousePos()).c_str(),
|
||||
PD::Color("#ffffffff"));
|
||||
PD::Gfx::Reset();
|
||||
PD::Gfx::Draw(pList);
|
||||
pList.Clear();
|
||||
|
||||
@@ -72,6 +72,7 @@ void DesktopOS::Init() {
|
||||
}
|
||||
#endif
|
||||
glfwSwapInterval(1);
|
||||
PD::Hid::UseDriver<HidGlfw>(impl->win);
|
||||
}
|
||||
|
||||
void DesktopOS::Deinit() {
|
||||
|
||||
@@ -42,6 +42,7 @@ void HorizonCtr::Init() {
|
||||
C3D_RenderTargetSetOutput(impl->Bottom, GFX_BOTTOM, GFX_LEFT,
|
||||
DisplayTransferFlags);
|
||||
PD::Gfx::UseDriver<PD::GfxCitro3D>();
|
||||
PD::Hid::UseDriver<PD::HidDriver>();
|
||||
}
|
||||
|
||||
void HorizonCtr::Deinit() {
|
||||
|
||||
@@ -29,6 +29,7 @@ void HorizonNX::Init() {
|
||||
gladLoadGL();
|
||||
glfwSwapInterval(1);
|
||||
PD::Gfx::UseDriver<PD::GfxOpenGL3>();
|
||||
PD::Hid::UseDriver<PD::HidDriver>();
|
||||
}
|
||||
|
||||
void HorizonNX::Deinit() {
|
||||
|
||||
Reference in New Issue
Block a user