Commit Graph
66 Commits
Author SHA1 Message Date
clobber ee43b089a6 Use a custom-build runloop in an internally managed thread to handle timing. 2016-07-31 19:57:08 -07:00
clobber fd826593ef Runloop implementation. 2016-07-28 22:19:21 -07:00
clobber 5cd5bf0327 Set _lastFrameTime to the time set for the next timer execution. 2016-07-24 23:02:07 -07:00
clobber 8645449ea3 Dispatch queue support 2016-07-24 17:37:34 -07:00
mrvacbob 6d5a059fe1 Run the HID event loop after the wait, not before
This gives it the most time to collect HID events. Otherwise, input
could arrive while waiting but not be read until after the next frame.

Tried running the event loop for 'advance' seconds but the timer is
too imprecise to work.
2016-03-31 01:51:22 -07:00
mrvacbob 7f0e6e1aa4 Add isPausedExecution API to handle saving in Mupen and Dolphin properly
Mupen always unpaused and paused after saving, which could lead to it
getting out of sync with the UI's play button state. Dolphin has trouble
with the rendering thread deadlocking.
2016-03-31 00:07:08 -07:00
mrvacbob d9c8b8cc74 Rename frameRefreshThread: since it's not a thread 2016-03-21 02:10:29 -07:00
mrvacbob 308f1c1c9f Simplify the number of timing variables used in OEGameCore, remove some unused deprecated ones 2016-03-21 00:03:15 -07:00
mrvacbob d5fce4037f Fix thread-safety in init_mach_time() 2016-01-04 01:15:06 -08:00
clobber b2ca17fe05 Clean up deprecated methods. 2015-12-12 17:06:00 -08:00
mrvacbob cb4d30d37f Implement hasAlternateRenderingThread/needsDoubleBufferedFBO in cores 2015-11-08 00:31:52 -08:00
clobber 897555f3b2 Fixes compat with older compiled cores linked against the framework 2015-10-30 01:17:39 -05:00
Alexander Strange a3006b82fa Remove a log 2015-10-21 03:39:49 -07:00
Alexander Strange bee40dc496 implement default -internalPixelFormat 2015-10-19 01:20:40 -07:00
Alexander Strange bb13a70b4b Pretty new OEGameCore refactor in preparation for OpenGL3 support. Should not break backwards compatibility. 2015-10-18 17:40:22 -07:00
Kyle Lacy 53754cac6f Don't call serialize/deserialize when loading a file
This fixes compatibility with the Mednafen core (and probably other
cores as well)
2015-06-02 10:00:05 -07:00
clobber 6d0610cedb OEGameCore API: add methods for multiple disc handling 2015-05-17 17:37:41 -05:00
Kyle Lacy b8fa724e09 Fix error propagation with serialization/deserialization 2015-02-28 12:48:12 -08:00
Kyle Lacy 3ff3beb96f Use OEGameCoreController to get rewind properties 2015-02-27 22:42:04 -08:00
Kyle Lacy 95e874f5cb Initialize rewindQueue with a limited capacity 2015-02-27 22:40:08 -08:00
Kyle Lacy bfb01e974f Rearrange some properties in OEGameCore 2015-02-27 22:35:35 -08:00
Kyle Lacy 7b33a7cd21 Lazily initialize rewindQueue 2015-02-27 17:43:17 -08:00
Kyle Lacy 4313975b8b Add rewindBufferSeconds property 2015-02-27 17:33:12 -08:00
Kyle Lacy cbf5f1a1d3 Make rewindQueue into a property 2015-02-27 17:32:30 -08:00
Kyle Lacy 4ad01d4e05 Change rewindInterval into an NSUInteger 2015-02-27 16:24:16 -08:00
Kyle Lacy 5ec621f8f0 Rename canRewind to supportsRewinding 2015-02-25 14:40:35 -08:00
Kyle Lacy 85a42a6e36 Only record states every rewindInterval frames 2015-02-24 14:59:38 -08:00
Kyle Lacy 677bafdb20 Add rewindInterval property 2015-02-24 14:59:34 -08:00
Kyle Lacy 0168ecb55d Only record rewind states if a core can be rewound 2015-02-23 13:06:59 -08:00
Kyle Lacy 56e224abde Add [OEGameCore canRewind]
For now, it always returns YES
2015-02-23 13:06:05 -08:00
Kyle Lacy 5afb1256a8 Add support for stepFrameBackward 2015-02-20 18:40:32 -08:00
Kyle Lacy 79262a973a Refactor rewinding
`initialState` is no longer necessary
2015-02-20 18:40:32 -08:00
Kyle Lacy 389f6d550c Add dummy implementation for stepFrameBackward 2015-02-20 18:40:32 -08:00
Kyle Lacy 012475b161 Fix rewinding to the beginning of the rewind queue
Rewinding to the beginning to the queue would end up removing the first
state in the queue, so every time you rewound to the beginning, you
would be one frame ahead of last time you rewound to the beginning
2015-02-18 11:12:24 -08:00
Kyle Lacy eb2e6e3573 'Pause' when rewinding beyond the rewind queue 2015-02-18 11:12:24 -08:00
Kyle Lacy a4b43b8b28 Don't save rewind states when paused 2015-02-18 11:12:24 -08:00
Kyle Lacy 00f01a1983 Use OEDiffQueue for rewinding 2015-02-18 11:12:24 -08:00
Kyle Lacy 196c2a2487 Implement rewinding 2015-02-16 13:32:26 -08:00
Kyle Lacy 872dd10dcf Add placeholder [OEGameCore rewind:] method 2015-02-16 10:51:31 -08:00
Kyle Lacy 501e519095 Defer default state file saving/loading
`saveStateToFileAtPath:` now calls `serializeStateWithError:`, and
`loadStateFromFileAtPath:` calls `deserializeState:withError`. This
means that a Game Core can choose to implement only the
serialize/deserialize methods, and file saving/loading will work
automatically
2015-02-15 13:27:44 -08:00
Kyle Lacy 31104d1fae Add state serialization methods to OEGameCore 2015-02-15 12:14:01 -08:00
clobber 31252cca9d Add the old method back to call it from the new method to ensure compatibility, but keep the method deprecated. 2014-02-08 15:19:49 -08:00
clobber 52d6f62389 Add error: parameter to -loadFileAtPath: method. 2014-02-08 14:25:41 -08:00
clobber 2910371549 Small OEGameCore cleanup to make developer API less confusing 2013-11-27 23:47:45 -06:00
clobber 64d60411d4 Improve error handling in OEGameCore. 2013-09-15 12:53:02 -07:00
clobber 1fb4163d2b Add a method to run a single frame for start up in OEGameCore. 2013-09-07 21:11:51 -07:00
Remy Demarest de54f59ef7 Add asynchronous stopping in OEGameCore and delegate to signal when the frame thread is finished. 2013-09-02 15:38:07 -07:00
Remy Demarest 38e0cec0bd Merge branch 'master' into XPC 2013-08-15 21:03:06 -07:00
clobber ecc31d6aa0 Added Display Mode global key
This is available for Cores through [OEGameCore changeDisplayMode] to
change screen modes (NDS), color palettes (VB) or other display-related
functions
2013-08-15 21:49:42 -05:00
Remy Demarest 54c26546ba Merge master into XPC. 2013-08-02 23:55:40 -07:00