lag frame in mgba
This commit is contained in:
parent
7a090edcb0
commit
b2ead68c4d
|
@ -25,7 +25,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.GBA
|
|||
public static extern bool BizLoad(IntPtr ctx, byte[] data, int length);
|
||||
|
||||
[DllImport(dll, CallingConvention = cc)]
|
||||
public static extern void BizAdvance(IntPtr ctx, LibVBANext.Buttons keys, int[] vbuff, ref int nsamp, short[] sbuff,
|
||||
public static extern bool BizAdvance(IntPtr ctx, LibVBANext.Buttons keys, int[] vbuff, ref int nsamp, short[] sbuff,
|
||||
long time, short gyrox, short gyroy, short gyroz, byte luma);
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
|
|
|
@ -65,12 +65,14 @@ namespace BizHawk.Emulation.Cores.Nintendo.GBA
|
|||
if (Controller["Power"])
|
||||
LibmGBA.BizReset(core);
|
||||
|
||||
LibmGBA.BizAdvance(core, VBANext.GetButtons(Controller), videobuff, ref nsamp, soundbuff,
|
||||
IsLagFrame = LibmGBA.BizAdvance(core, VBANext.GetButtons(Controller), videobuff, ref nsamp, soundbuff,
|
||||
0, // TODO RTC hookup
|
||||
(short)Controller.GetFloat("Tilt X"),
|
||||
(short)Controller.GetFloat("Tilt Y"),
|
||||
(short)Controller.GetFloat("Tilt Z"),
|
||||
(byte)(255 - Controller.GetFloat("Light Sensor")));
|
||||
if (IsLagFrame)
|
||||
_lagCount++;
|
||||
}
|
||||
|
||||
public int Frame { get; private set; }
|
||||
|
|
Loading…
Reference in New Issue