Commit graph

64 commits

Author SHA1 Message Date
Muhammad Nauman Raza da4a9bf216 chore: initialise fork
Former-commit-id: 5065b2cb02b02093c42e21dedd7983d19a62232d
Former-commit-id: f92b7f776b8e260643de1d6fa1040f426137b4e1
2024-03-22 19:37:29 +00:00
Michel Heily 91bb17f6dc Deprecated minifb
Former-commit-id: 7b4be22333cd43fdcc6a78fa8b9f855f5de96e51
Former-commit-id: 78b19d497d359af5b7d97eea4c6c26ff030993d7
2022-09-11 23:42:09 +03:00
Michel Heily 255806ff69 Move rustbodyadvance-jni to platform/
Former-commit-id: c4565bfe5bf7c4887b6b86c44afbf6b55ac76811
Former-commit-id: b3f296200b0a718ba5509db0cce1117e0fb38a1a
2022-09-05 00:02:00 +03:00
Michel Heily 28fb9ffa70 chore: Refactor into crates
Been wanting to do this for a long time.
This does impose performance issues when building with the vanilla
release profile, as cargo does not perform optimizations across crate
boundary (we care mostly about inlining).
so I added release-lto profile

Also fixed some broken stuff I found across the project, meh


Former-commit-id: 06d03263cc6245313f3ea22c715479ab6da7c4d4
Former-commit-id: f93abd10c67ea8a3b8072b47462be5eca4f3e02b
2022-09-04 23:54:44 +03:00
Michel Heily 1535062e6c Make the rustboyadvance-sdl2 as the default target for cargo
Former-commit-id: 30a23b71305ba7dc7e18f843f08b8e544dae825e
Former-commit-id: 8d23da59ad40a8f716cdbc06f56a9c4d7bd471e1
2022-09-04 22:10:16 +03:00
Michel Heily 8ea942e973 Update my cargo profiles
Former-commit-id: bdc727d4a0a3f7138d2d97505d7ef75cac24b575
Former-commit-id: 17f26c2a5e831c0b361cd328d8d2f72a440e4c89
2022-09-04 22:08:50 +03:00
Michel Heily a51a0d4962 Build with debuginfo
Former-commit-id: 3fc245a05643baf60f10d08350baf9e72762d992
Former-commit-id: 14002ce5c901b926258677ed1062ded4f47e5920
2021-06-05 18:44:46 +03:00
Michel Heily 879374a9b0 Refactor dir rustboyadvance-core -> core
Former-commit-id: 5af970f6d56d321472f2b91885e41ca113390986
Former-commit-id: 748e222a36362eb5ac8909068c32f2d3f98ca536
2020-05-30 13:43:37 +03:00
Michel Heily be36345849 Add experimental RetroArch Core
Former-commit-id: 5d6bd10c6e9214f5980eddf86ed92d35c0e9ea93
Former-commit-id: 2ad4828ecbb3de7924f6103b106c7ec06c7822cc
2020-05-15 13:25:12 +03:00
Michel Heily ac43292051 Add rustboyadvance-wasm
Former-commit-id: 04a1ad2f382055d46b943cb0e4e467d925d99298
2020-04-13 17:55:39 +03:00
Michel Heily 1e9cf89cb1 Add simple fps benchmark
Former-commit-id: d4bb368fa0b5ab98819aa509f799e96a4da58308
2020-04-13 00:34:50 +03:00
sapir 0a226a4d7c Move profile definition to workspace root
Former-commit-id: 2ad50e35e9250c44ed538540d245ae23f0a7f2ff
2020-04-12 22:23:45 +03:00
Michel Heily 884f39ca8f Refactor workspace structure
Former-commit-id: d6ab90563fa209b431661086f9ec2672bda02a96
2020-04-11 16:06:34 +03:00
Michel Heily b21cd1e3d9 Refactor project workspace and fix build
Former-commit-id: 8e264cdbc9e5290654c29e6893a121bce73c29c9
2020-04-10 00:53:41 +03:00
Michel Heily ff95b67ae1 Update gdbstub crate to version 0.1.2 and run cargo-update
Former-commit-id: 2db24a3f835b817519cc544d722c58437e98011f
2020-04-07 23:57:29 +03:00
Michel Heily fb93ebb4ed feat/arm7tdmi_dispatch_table: Done!
Moved away from using lazy_static for this one since every access to a
lazy_static reference adds a runtime check, Currently using a build.rs script to generate a const table instead.

Worked out the ARM decoding issues, seems to run fine now.

Though the dynamic decoding for ARM is broken now since I had to change things in Data Processing and MSR instructions

TODO use `const fn` when it becomes stable


Former-commit-id: ba09748ff74a403c7016adcbe0ca553b591f6855
2020-04-07 02:31:13 +03:00
Michel Heily a523a37d32 [WIP] Start working on arm7tdmi dispatch table.
Lookup tables are generally faster than matching in most architectures.
There is some trouble in decoding some arm data processing instructions
so this is non-default feature for now

* Crashes on armwrestler but many games seem to work


Former-commit-id: 3c06ea344ae0097947d8cd5bd05b1f882c7f743a
2020-04-07 02:30:22 +03:00
Michel Heily d938767430 feat/jni: Add rustboyadvance-jni crate to export some simple JNI bindings
Former-commit-id: d4e7a622a97215a8c1b7b50bb7f08d18cb9c5716
2020-02-23 00:30:38 +02:00
Michel Heily 778274b5ae refactor: split "plat" binaries into separate crates
Former-commit-id: 73554b0128e036279f7ac895acb57d8f89cb1c96
2020-02-23 00:30:38 +02:00
Michel Heily c50ab1ecd8 feat: Add basic gdbserver feature
Initially I began implementing the gdb protocol on my own, but I then found a
nice work-in-progress crate on https://github.com/daniel5151/gdbstub
that suited my needs.


Former-commit-id: f77557cbbd8652c2ed05ac439efc1956d8e99729
2020-02-21 22:12:58 +02:00
Michel Heily 84004ddb5c windows: Add file icon to build targets
Former-commit-id: 2dae2e7818d86ddf9470afafd0404f0e7e021718
2020-02-12 22:18:58 +02:00
dependabot-preview[bot] 3a488e4487 build(deps): bump ansi_term from 0.11.0 to 0.12.1
Bumps [ansi_term](https://github.com/ogham/rust-ansi-term) from 0.11.0 to 0.12.1.
- [Release notes](https://github.com/ogham/rust-ansi-term/releases)
- [Commits](https://github.com/ogham/rust-ansi-term/compare/v0.11.0...v0.12.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 702534f36b62f34f48c13c64e0db1d195206c215
2020-02-07 17:10:21 +02:00
dependabot-preview[bot] 66d7f0f7f2 build(deps): bump zip from 0.5.3 to 0.5.4
Bumps [zip](https://github.com/mvdnes/zip-rs) from 0.5.3 to 0.5.4.
- [Release notes](https://github.com/mvdnes/zip-rs/releases)
- [Commits](https://github.com/mvdnes/zip-rs/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 2c546f001f0e53ab6936f382ba9a9a40698337dd
2020-02-07 17:10:14 +02:00
dependabot-preview[bot] 6c879136f1 build(deps): bump colored from 1.8.0 to 1.9.2
Bumps [colored](https://github.com/mackwic/colored) from 1.8.0 to 1.9.2.
- [Release notes](https://github.com/mackwic/colored/releases)
- [Changelog](https://github.com/mackwic/colored/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mackwic/colored/compare/v1.8.0...v1.9.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 1b24d07dd253bedd15df2eba727118cbb01ef44b
2020-02-07 17:05:13 +02:00
dependabot-preview[bot] 194b9a0b2a build(deps): bump time from 0.1.42 to 0.2.6
Bumps [time](https://github.com/time-rs/time) from 0.1.42 to 0.2.6.
- [Release notes](https://github.com/time-rs/time/releases)
- [Commits](https://github.com/time-rs/time/commits/v0.2.6)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 9a9533684df743a5441be6ed0d0cd40633189c6b
2020-02-07 17:02:24 +02:00
dependabot-preview[bot] 9d383fa2c5 build(deps): bump num from 0.2.0 to 0.2.1
Bumps [num](https://github.com/rust-num/num) from 0.2.0 to 0.2.1.
- [Release notes](https://github.com/rust-num/num/releases)
- [Changelog](https://github.com/rust-num/num/blob/master/RELEASES.md)
- [Commits](https://github.com/rust-num/num/compare/num-0.2.0...num-0.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: ba192b84e744980c2edb3969f94b25fc0974a1bb
2020-02-07 17:01:55 +02:00
dependabot-preview[bot] 26f016182b build(deps): bump bitflags from 1.1.0 to 1.2.1
Bumps [bitflags](https://github.com/bitflags/bitflags) from 1.1.0 to 1.2.1.
- [Release notes](https://github.com/bitflags/bitflags/releases)
- [Changelog](https://github.com/bitflags/bitflags/blob/master/CHANGELOG.md)
- [Commits](https://github.com/bitflags/bitflags/compare/1.1.0...1.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 741a46a69dddb03d423776d760c933dab4076426
2020-02-07 17:01:35 +02:00
dependabot-preview[bot] 2a9f2270da build(deps): bump rustyline from 5.0.6 to 6.0.0
Bumps [rustyline](https://github.com/kkawakam/rustyline) from 5.0.6 to 6.0.0.
- [Release notes](https://github.com/kkawakam/rustyline/releases)
- [Commits](https://github.com/kkawakam/rustyline/compare/v5.0.6...v6.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 138a28066ed7d421ac4d6cf54b5710f45bc02c4b
2020-02-07 16:59:55 +02:00
dependabot-preview[bot] 70eaedcc77 build(deps): bump sdl2 from 0.32.2 to 0.33.0
Bumps [sdl2](https://github.com/Rust-SDL2/rust-sdl2) from 0.32.2 to 0.33.0.
- [Release notes](https://github.com/Rust-SDL2/rust-sdl2/releases)
- [Changelog](https://github.com/Rust-SDL2/rust-sdl2/blob/master/changelog.md)
- [Commits](https://github.com/Rust-SDL2/rust-sdl2/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
Former-commit-id: 3a2416ac596acb7f59ac94ff375fd02c9c60b1b4
2020-02-07 16:57:39 +02:00
Michel Heily 17560eeb0c fix: Completly refactor GPU scanline composition code.
This change fixes #9 and emulates:
- Correct layer ordering
- Correct emulation of blending sfx
- Correct emulation of the object window (BIOS boot animation is now fixed)


Former-commit-id: caf46fe4b62cc54e6f2c02a8001da552f8e6b54a
2020-02-07 16:11:16 +02:00
Michel Heily 8f4e42d6d4 feat(logger): Add a logger to the project
Former-commit-id: aa0579884951857a136904b3147eaa553117e68e
2020-01-31 16:15:29 +02:00
Michel Heily c20ac9cdf8 core: cartridge: Try to detect and print the backup type
In preparation for backup impl


Former-commit-id: 75efbbaea82ba30899787b46b8eaca834622493c
2020-01-17 16:11:43 +02:00
Michel Heily dc1cd84225 feat/savestates: Implement savestates for plat/sdl2
Former-commit-id: e61193e0c9a937dd3b4b7e7e748d9a9b1e170e44
2020-01-16 20:18:32 +02:00
Michel Heily d887602266 feat/savestates: Add serde and bincode traits to the project
Former-commit-id: b4699586bba03b8fcfc718ea08363a7067d31e20
2020-01-16 19:49:13 +02:00
Michel Heily 12ebcf44a2 refactor: Make debugger into a cargo feature
Former-commit-id: 50f28963d5f7c7b04a0ecd4be82ddd61bd59a39b
2020-01-13 01:11:58 +02:00
Michel Heily 49a3bc6fd0 feat: Add temporary project icon
Former-commit-id: 05da47f328f076045f4b27f521c72e03648ede77
2020-01-12 01:30:35 +02:00
Michel Heily b00fbfb38c gpu: refactor: Big refactor preparations
1) Decouple SysBus from Gpu
2) Split Gpu rendering function into separate modules
3) Cleanup


Former-commit-id: 0435ad1c9c1de72ed50769fabfea7c5f33b670e0
2019-12-29 23:44:34 +02:00
Michel Heily d8545dd8cd sdl2: Use callbacks with ring buffer instead of audio queue.
Better latencies, and also fast-forward (aka Turbo mode) sounds normal
this way.


Former-commit-id: d1075087e847c765a871157a7973c897575ef4d7
2019-12-28 17:03:59 +02:00
Michel Heily a01e3ed9cd Make sdl2 run as default for "cargo run"
Former-commit-id: 11c411582fa10e8391d1a9ce528e876b3da7cb22
2019-12-27 13:12:03 +02:00
Michel Heily c9e80f4f60 Remove dead code
Former-commit-id: 5d5768ca6b73060197d9bacda61cba4c03804ad0
2019-12-27 12:41:36 +02:00
Michel Heily c2ac3c5a10 Improve DMA code
Former-commit-id: 8fdb6195ceb323aebd8a26da98fe286d89ef8363
2019-12-27 12:37:32 +02:00
Michel Heily 38e504515b rba-sdl2: Trying spin_sleep crate
Former-commit-id: 1c6a36a1a61be3949080a8c86915235aaf25d0e5
2019-12-20 19:02:33 +02:00
Michel Heily 3c7a734270 Add minifb based binary, currently it has better performance than the SDL2.
SDL2 rendering is really bottlenecking currently..


Former-commit-id: 8e04b799f248209a138990b2389e740b0d1d9f0f
2019-12-20 16:31:26 +02:00
Michel Heily 04d2edfc01 Refactor "backend" concept
See plat/sdl2


Former-commit-id: 5f7c9625467003d5b73307959095eb5365db523e
2019-12-20 15:11:26 +02:00
Yonatan Goldschmidt 60c77869df Add cpal extern crate
I really hope all these additions to Cargo.lock are actually its deps...


Former-commit-id: 7c85f330ea3c27f8ebae7020dc4a46d7d557affd
2019-12-20 15:11:26 +02:00
Michel Heily c117cbe924 Make the debugger work again, but currently breakpoints are not supported.
Added memory write command and the ability to pause the debugger with Ctrl-C


Former-commit-id: 83d141fa191dadefb84f7c9de163631a69af8324
2019-11-12 18:22:00 +02:00
Michel Heily 3a1d5c10ce Fix many bugs, refactor many things..
Passing: Armwrestler, cpu_test by Dead_Body

Former-commit-id: 80d815d110c5341515dd01c476a0d7e25ecb66a8
2019-11-09 01:06:24 +02:00
Michel Heily 7cc1a50d12 Support zip files and add --no-framerate-limit
Former-commit-id: 62a7122fb0b3e832eeb3cbf347a0966e4cd32d50
2019-09-11 21:26:40 +03:00
Michel Heily 639993edd7 Add blending and mosaic SFX, and cleanup code.
Former-commit-id: b9f0ccaf1820da61f49ebeb2af5beff5cccd722f
2019-08-13 22:15:36 +03:00
Michel Heily c7dd713605 The big ioregs refactoring.
This commit refactors the ioregs:
* Use bitfield crate to implement the GPU ioregs.
* IoRegs are stored in their own variables bindings (i.e, Gpu related ioregs are now fields of the Gpu struct)
  - This optimize performance quiet alot from my testings - since every scanline was accessing deseralizing ioregs from sysbus. (Getting constant 59fps now)
* For now, comment out DMA model

Also, cleaned the code up to eliminate rustc warnings.


Former-commit-id: 9077695c446ebd1a71783acfdd9819245aa02d7a
2019-08-03 00:24:15 +03:00