bsnes build broke when rewind.c was removed because it defined the GB_rewind_reset, which was being linked in despite being no longer present. -DGB_DISABLE_REWIND turns off this link.
* Waterbox setup has been revamped to use the latest llvm parts (llvm 16 for compiler_rt/libunwind/libcxx/libcxxabi).
* Clang is now possible to use, and is the preferred compiler (due to superior performance).
* Supported compilers are now clang 14/15/16, and gcc 12.
* Other core updates are mixed in.
---------
Co-authored-by: Morilli <35152647+Morilli@users.noreply.github.com>
* Use SameBoy submodule symlink for BSNES
* SGB memory domains
* Fix SGB saveram issues (extra data like rtc will be saved correctly now here)
* Various cleanups, avoid unneeded unsafe use, a little better EnterExit use
Co-authored-by: Morilli <35152647+Morilli@users.noreply.github.com>
* Partial port of graphics debugger to new BSNES
* minimal "working" copy-paste
* small fix for the previous commit
* Implement more stuff
* no idea whose responsibility "EnterExit" is but this should work
* add support for backdropcolor
i have 0% trust in this code
* implement mode7, apply backcolor on load
* 🙈
un-"implement" the nonfunctional scanlinehookmanager as well as the non-functional palette setting logic
- this may actually break config lol
* don't break libsnes config
* Provide IBSNESForGfxDebugger in the subbsnes core
* Remove redundant semicolon
* Clean up diff of `comboPalette_SelectedIndexChanged`
* Fix crash
Co-authored-by: YoshiRulz <OSSYoshiRulz@gmail.com>
* BSNESv115+: Replace the 'snes_audio_sample' callback with a dynamic audio sample vector to reduce callbacks
* fix integration for subbsnes core
* reduce buffer allocations
- also make frame setter private now that it's possible
* BSNESv115: allow subframe inputs
* BSNESv115: Implement ICycleTiming
may be correct, not sure
* BSNESv115: add dedicated subframe core
I have probably overlooked something...
* Don't implement ICycleTiming in the non-subframe core
requires re-implementing the "FrameAdvance" function in the subframe core
* Register previously missing services in the subframe core as well
* Wire up SubBsnes everywhere in the frontend
* Change reset cycle to reset instruction
* Deduplicate some code
* Slightly rework frame advance logic. The main intent here is to prevent a case where two frames are ran within a single "frame." The current code probably wouldn't crash due to that, but best not to do that.
Also make SGB work here. A bit of a joke since you really can only abuse it for subframe resets, but might as well especially with the settings implying it's possible (and someone is bound to complain).
Co-authored-by: CasualPokePlayer <50538166+CasualPokePlayer@users.noreply.github.com>
* Fix#3173 by only calling bus.map() on initial power, not subsequent calls
* yeah screw that, we'll just lock the bus to prevent map calls from going through
* initialize peekable in reset with false, just for safety i guess
* region override for bsnes
* hook up SnesInitData right. still needs region override sync setting
* settings stuff, also need to make sure sameboy is using the right region for sgb
* and build
* clearer struct definition; move struct to header file
Co-authored-by: Morilli <35152647+Morilli@users.noreply.github.com>
* testing...
* more testing...
* this is probably a bad idea
* well this probably fixes state size issues
* time to debug this
* oh derp it's just not enough memory in invis heap
* let's see if this works?
* apparently this breaks slow ppu?
* testing...
* testing...
* testing...
* sanity checking
* let's try again
* i do not know what the fuck is up with this emulator nor do i care enough, state size is still under a mb anyways with slow ppu
* oops forgot to commit this
* resolve some issues
* tweak memory allocation sizes
* dont save more cache stuff
* wtf was i even thinking here
* move comment back to original pos, comment on double loading
* BSNESv115+: get rid of input_state + input_poll; just poll
* call `snes_controller_latch` on latches done in the core,
- this now also actually calls the InputCallbackSystem
- needed some edits in the core to support executing the callback even when no controller is connected in port 1
* Fix and somewhat normalize the SnesCallbacks order
- saveram was not working at all on certain roms, as the "CARTRIDGE_RAM" memory domain was returning a null pointer (similar thing for "CARTRIDGE_ROM"; changed it to correctly return the current rom)
- add sa1_bwram domain for clarity and an SGB_ROM domain
* Actually working callbacks
now actually work after natt's changes
* Set whether memory hooks exist every frame to prevent unnecessary function calls if not
* add support for more SGB firmware
* replace illegally provided bootroms with legal homebrew bootroms
* let's swap these with homebrew bootroms too
* add builds
* this should probably be preferred
* Fix incorrect assignment
* Fix whitespace changes to Designer files
Co-authored-by: Morilli <35152647+Morilli@users.noreply.github.com>
Co-authored-by: YoshiRulz <OSSYoshiRulz@gmail.com>
- also patched out the left/right and up/down handling in the core, where it didn't belong
- also fixed the existing payloadcontroller because it wasn't working at all lol
* Slam all this shit in here i don't care
* no lzma pls
* un-hack things that i hacked earlier (closer to bsnes source now)
* remove more unused files
* remove more files
* get some stuff working on this weird ass branch
* do this to get actual video (holy shit it works) while palette is incorrect
* make video look correct and hopefully fix stack waterbox allocation size uh ?
* Move the new bsnes core to its own dir as a new core and get input working
* remove leftover files from old bsnes
* fix some shit for now
* make lag frame detection work
* Improve cartridge loading to hopefully make sgb work (haven't tested)
- also changes some audio buffer stuff, might be better or worse than before idk
- need to figure out the saveram stuff
- path requests might actually completely fail atm, no idea how to verify that
* refactor to use a switch instead of some weird array with function pointers
- and implement snes_get_mapper, might be helpful or smth idk
* implement entropy c++-side and delete all this useless code holy
* delete dumb unnecessary code
* implement snes_peek_logical_register c++-side
* normalize all indentation
* attempt to properly support sharprtc and epsonrtc data loading and writing
* Duplicate winforms code to add entropy support c#-side and implement layer_enable functionality
The duplicated code is just so i can have a proper window for the new bsnes core. I do not like duplicating code like this, so this should be improved if possible
* Checkpoint for the start of getting rid of the ugly api wrapper stuff
* Next checkpoint for a full api refactor
* bullshit denied
just no.
every file is either copied or manually edited or written from scratch etc.
do not. force. one indent_style on every single file.
It just does not work.
* remove the entire eMessage_CMD handling and convert to native function calls
* general improvements regarding functionality
- adds hotfixes and fast_ppu core options
- add back the alwaysDoubleSize setting
- use bsnes's own serialize function for savestating now
- generate and use the color palette only in c# cause it doesn't need to be on the c++-side
- and more cleanup like always
* somewhat implement IMemoryDomains
* Implement trace logger and cleanup more unused stuff
* Implement ISaveRam, fix controller mapping for TAStudio and remove the pwrap stuff
* Fix ISaveRam, add a controller configuration box for the new core, (hopefully) fix controller inputs
- also differentiates BG prio0 and prio1 now (with options for it)
- some minor irrelevant edits in bsnes source
* Cleanup some more and optimize a bit
* Support firmware loading and make sgb work (hopefully)
* Remove all unused files
* Add back CropSGBFrame option and cleanup snes_video_refresh logic
* Some hopefully sensible changes
* One more cleanup pass
* Change to new PortedCore attribute
necessary after the changes in 98b07c42d5
Co-authored-by: nattthebear <goyuken@gmail.com>