add in touch screen input smoothing, fixes #3397
This commit is contained in:
parent
a046ea901b
commit
53c8deae29
Binary file not shown.
|
@ -17,7 +17,6 @@
|
|||
#include <waterboxcore.h>
|
||||
|
||||
static bool SkipFW;
|
||||
static time_t CurTime;
|
||||
static bool GLPresentation;
|
||||
|
||||
struct NDSTime
|
||||
|
@ -140,7 +139,6 @@ ECL_EXPORT const char* Init(InitConfig* initConfig,
|
|||
|
||||
struct MyFrameInfo : public FrameInfo
|
||||
{
|
||||
s64 Time;
|
||||
u32 Keys;
|
||||
u8 TouchX;
|
||||
u8 TouchY;
|
||||
|
@ -190,7 +188,8 @@ ECL_EXPORT void FrameAdvance(MyFrameInfo* f)
|
|||
|
||||
if (f->Keys & 0x1000)
|
||||
{
|
||||
NDS::TouchScreen(f->TouchX, f->TouchY);
|
||||
// move touch coords incrementally to our new touch point
|
||||
NDS::MoveTouch(f->TouchX, f->TouchY);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -222,10 +221,14 @@ ECL_EXPORT void FrameAdvance(MyFrameInfo* f)
|
|||
}
|
||||
}
|
||||
|
||||
CurTime = f->Time;
|
||||
|
||||
NDS::RunFrame();
|
||||
|
||||
if (f->Keys & 0x1000)
|
||||
{
|
||||
// finalize touch after emulation finishes
|
||||
NDS::TouchScreen(f->TouchX, f->TouchY);
|
||||
}
|
||||
|
||||
if (!GPU3D::CurrentRenderer->Accelerated)
|
||||
{
|
||||
auto softRenderer = reinterpret_cast<GPU3D::SoftRenderer*>(GPU3D::CurrentRenderer.get());
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 0506a84cdede08a4ebc7f71799265d91ac1d79dc
|
||||
Subproject commit 51e3886de1d01097b18dbc783eee175a012fc76c
|
Loading…
Reference in New Issue