Flyinghead
ac2637286b
Merge remote-tracking branch 'origin/master' into dev
2023-05-13 15:55:47 +02:00
Flyinghead
4b0d377e66
pvr: don't clip negative depth vertices
...
Fixes baserunner cams depth in World Series Baseball 2K1
Issue #1027
2023-05-12 10:20:46 +02:00
Flyinghead
c0f0a758df
pvr: treat nan intensity as max. avoid nullptr crash in appendSpriteVtx
...
Fixes Gaiamaster Kessen! black texture. Issue #1021
Fix for MINIDUMP-RC
2023-05-09 21:07:40 +02:00
Flyinghead
1a5a2f64d4
naomi: insert card button compatibility with ggpo
...
handle insert card button like standard naomi buttons so it can be used
with ggpo
load card data when it's inserted, not before
2023-05-06 20:54:45 +02:00
scribam
4acb670b88
netbsd build fix
2023-04-29 17:51:25 +02:00
Flyinghead
79b9b49218
naomi: netdimm net client and rfid card reader emulation
...
high-level emulation of netdimm v3.17 net client lib
vf4/mushiking rfid card reader emulation
2023-04-29 17:50:56 +02:00
Flyinghead
92a1c1891b
alienfnt: support for serial modem and worldwide ranking server
...
Emulate modem on sh4 serial port.
Use picotcp stack to handle ppp protocol.
Include nvmem with network settings (server at alienfront.duckdns.org,
disabled by default).
2023-04-16 15:41:54 +02:00
scribam
210100a108
naomi: netbsd/openbsd pthread fixes
...
These systems do not have pthread_condattr_setpshared/pthread_mutexattr_setpshared
2023-04-13 18:10:19 +02:00
Flyinghead
70d3e221a9
mushiking series support
...
Emulate barcode reader. UI to input card id.
scif: SCFSR2.DR should also trigger an interrupt. Fixes the partial read
issue with manic panic ghosts touchscreen.
Add default implementations in SerialPipe for read-only and write-only
devices.
Fix card jammed error in mushiking with custom input code.
Add mushi2k61 and mushi2k62 to naomi rom list.
Cheats to skip rfid check.
2023-04-12 10:09:21 +02:00
Flyinghead
b556617e1d
sh4: only reset serial pipe on hard reset
...
See d3690b12c6
2023-04-09 20:56:14 +02:00
Flyinghead
e327172fd0
sh4: check access length when getting a ram pointer with GetMemPtr
...
Check access length and return nullptr if overflowing ram.
Fix ch2-dma code accordingly.
Fixes MINIDUMP-GX
2023-04-09 20:47:12 +02:00
Flyinghead
c5f82483e6
naomi: fix multiboard windows position
...
Position slave windows over master.
Support any window width.
2023-04-09 20:28:10 +02:00
Flyinghead
87fdd203b5
android scoped storage (ASS) support
...
introduce Storage abstraction interfaces
use Storage i/f to load zip and 7z archives, cdi/cue/gdi/chd media,
cheats and to find custom textures.
Use android file picker to add storage. Request persisted access perms.
jni helper classes.
Issue #813
2023-04-08 18:37:50 +02:00
Flyinghead
f94a08f12f
mmu: avoid crash due to approximative fast mmu matching
...
Fixes MINIDUMP-EA (Sonic Shuffle)
2023-04-02 22:06:22 +02:00
Flyinghead
32e08ca165
modem: don't crash on unexpected register writes
...
Just log and ignore.
Fixes MINIDUMP-62
2023-03-31 20:03:16 +02:00
Flyinghead
7108358ebd
Merge remote-tracking branch 'origin/master' into dev
2023-03-30 17:31:22 +02:00
Flyinghead
48acb03b81
underclock/overclock SH4 option
...
Increase/reduce the dynarec cycle count for each block.
Issue #210
2023-03-30 17:22:24 +02:00
Flyinghead
79be464326
aica: proper write mask on aica dma address registers
...
Fixes MINIDUMP-P3
2023-03-28 21:05:18 +02:00
Flyinghead
f67aad0b2d
pvr: don't wait if Present msg is already in the queue
...
Only Render* msgs are an issue when piling up on slow platforms.
Fixes frame skipping only working when delay frame swap is on
Issue #975
2023-03-28 21:01:56 +02:00
Flyinghead
d76982bbeb
naomi,aw: embed default flash for some games
...
Needed to configure network on first run.
2023-03-27 16:57:48 +02:00
Flyinghead
5e4e48fffe
mmu: don't crash when table full, just ignore
...
Fixes MINIDUMP-NF
2023-03-25 11:45:03 +01:00
Flyinghead
068861d0cc
pvr: mask low address bits according to 32-bit vram access size
...
Avoid crash when accessing the very last vram byte with short or int.
Correct behavior should be to raise an sh4 address exception.
Fixes MINIDUMP-N2
2023-03-24 11:53:38 +01:00
Flyinghead
2d7a1ce71a
atomiswave: fix failure to identify the game
...
regression by 78f80eb7dc
2023-03-23 09:45:25 +01:00
Flyinghead
9512ee657a
Allox f355 deluxe to run with only one screen
2023-03-22 19:01:34 +01:00
Flyinghead
78f80eb7dc
naomi: printer support for f355 and tduno[2]. Fix some bios font glyphs
...
Thermal printer support for f355 (G2 ext bus) and tduno[2] (maple JVS)
Change game id for sgdrvsim and dragntr3 to distinguish them.
Fix cyrillic page in BIOS font.
2023-03-22 19:00:50 +01:00
Flyinghead
fa525b4488
Fix hotd2p inputs
...
Issue #731
2023-03-22 15:36:10 +01:00
Flyinghead
ee3e83e09c
Fix loading of Sega Yonin Uchi Mahjong MJ (mj1)
...
gd cart: load first .bin if the specified one isn't found. Fix loading
of main directory for mj1. Don't update progress too often when
decrypting.
chd: allow loading of 1-track CD-ROMs
Use 2 jvs boards for mj1
Issue #985
2023-03-22 13:00:59 +01:00
Flyinghead
5c5c872afc
aica: small dma transfer must be correctly scheduled
...
Previously transfer taking less than 4096 cycles would be instantly
executed.
Fixes Sports Jam announcer broken audio.
Issue #980
2023-03-21 11:32:21 +01:00
Flyinghead
cb83d319b9
naomi: 4-player and eeprom fixes
...
Add 4-player support to Dirty Pigskin Football, WFF Royal Rumble, World
kicks PCB and Beach Spikers.
Fix several bugs in initEeprom and force 4-player cab when needed.
Get rid of pstone, pstone2 and ringout default eeproms.
2023-03-20 12:35:36 +01:00
Flyinghead
afc1f5f4e1
Merge remote-tracking branch 'origin/master' into dev
2023-03-15 21:09:47 +01:00
Flyinghead
4a2ad8b145
pvr: SortedTriangle has unsafe pointer to PolyParam
...
std::vector elements can be reallocated. Use index instead of pointer.
2023-03-15 20:58:12 +01:00
Flyinghead
4d990947de
sgdrvsim: display or network broadcast speedometer and tachometer
...
Display speedometer value, or network broadcast speedo and tacho on port
8002 (slave 2) if option is set
2023-03-13 17:45:12 +01:00
Flyinghead
ea7dd699b9
only launch sgdrvsim slaves on desktop platforms
2023-03-10 18:10:57 +01:00
Flyinghead
8a28ddbfe6
jvs: allow p2 buttons to be always on. sgdrvsim improvements
...
jvs: allow button mapped to jvs P2 to be always on. Don't overflow
button descriptors table
midiffb: invert axis if needed
Launch sgdrvsim network instances automatically. Remap some buttons and
make some always on.
2023-03-10 17:57:27 +01:00
Flyinghead
f186046c98
partial support for sega driving simulator
2023-03-09 17:54:57 +01:00
Flyinghead
5644e834fa
x86 dynarec: use UpdateSystem_INTC like other recs
...
get rid of unused rdv_DoInterrupts and rdv_DoInterrupts_pc
2023-03-09 09:37:48 +01:00
Flyinghead
b8d47fe0a8
sh4 dmac: more accurate implementation. Fixes sh4_dmac_demo.elf
2023-03-07 18:38:41 +01:00
Flyinghead
abcd9d77d4
set some global to static
2023-03-07 18:36:26 +01:00
Flyinghead
095e5ede81
sh4: more accurate cycle counting
...
get rid of float ops hack for dead or alive 2
get rid of idle skip option and code block hashing
count cycles for high-level wince functions and handlers (GetTickCount,
QueryPerformanceCounter and TLB_MISS handler)
Fixes Dave Mirra Freestyle BMX time counter running too fast.
More FPS for many wince games. Better wince perf on slow devices.
2023-03-07 18:35:01 +01:00
Flyinghead
67bba95dd1
dmac: set DMAOR.AE and raised interrupt if ch2 address error
...
Fixes crackin'dj 1 & 2 freeze at boot
Regression introduced by 66eb08f2d1
2023-03-06 10:26:52 +01:00
Flyinghead
2355bb8bb5
pvr: drop more vertices with large x and y
...
Fixes Manic Panic Ghosts bogus transparent rectangles in first stage
2023-03-05 15:08:17 +01:00
Flyinghead
c4d24254db
naomi2: FFB support for Club Kart and King of Route 66
2023-03-04 17:45:53 +01:00
Flyinghead
014da3a225
naomi: network output FFB for 18 wheeler and f355
2023-02-28 20:23:58 +01:00
Flyinghead
885a0508c0
Merge remote-tracking branch 'origin/master' into dev
...
# Conflicts:
# core/hw/aica/sgc_if.cpp
# core/hw/naomi/naomi.cpp
# core/hw/sh4/dyna/driver.cpp
2023-02-28 20:02:23 +01:00
namtsui
a1472fb190
OpenBSD 7.2 patches ( #953 )
...
* OpenBSD: BSS is immutable so mark it as mutable so that mprotect RWX works
see: mimmutable(1)
bc009f82ea
* OpenBSD does not have mcontext_t
<signal.h> provides `typedef struct sigcontext ucontext_t;'.
take register names from <machine/signal.h>, which provides struct
sigcontext.
see:
1a13d3ae4e
* OpenBSD uses major.minor for shared libs, so properly dlopen libGL.so
* OpenBSD remove redefinition of swap16
* OpenBSD: SDL2 controller detection
Use sdl_open_joystick() to open controllers on startup instead of
SDL_JOYDEVICEADDED event, which never gets detected.
* OpenBSD does not have mcontext_t but linux does
2023-02-28 18:22:45 +01:00
Flyinghead
26815d042a
arcade ouput: send game name before any output
...
Send the game id before any output to inform clients of the current
running game.
2023-02-27 17:46:00 +01:00
Flyinghead
026f21eddf
naomi: report error if rom is invalid instead of crashing
...
Fixes MINIDUMP-CS
2023-02-27 17:43:08 +01:00
Flyinghead
8d54382b10
aica: apply RAM mask to sample address (SA)
...
Fixes MINIDUMP-B9
2023-02-24 21:24:56 +01:00
Flyinghead
97dfabc416
pvr: don't reset TA parser during soft reset
...
Rendering might be in progress in another thread and this leads to
crashes.
Fixes MINIDUMP-AW and MINIDUMP-AY
2023-02-22 17:49:01 +01:00
Flyinghead
9b24984b07
crash when switching to full mmu
...
The MMU now has a state variable, which must be set before the dynarec
is reset.
Regression in afcb3b7ad8
Fixes MINIDUMP-AZ, MINIDUMP-B7, MINIDUMP-B0
2023-02-20 22:56:23 +01:00
Flyinghead
7ce08ea860
Fix Touch de Uno 1 & 2 inputs
...
Fix touchscreen touch detection
Default eeproms with calibrated touchscreen and disabled printer
2023-02-20 11:14:02 +01:00
Flyinghead
a156edbd73
Merge remote-tracking branch 'origin/master' into dev
2023-02-19 14:10:37 +01:00
Flyinghead
9dae5827cc
naomi: touchscreen emulation for manic panic ghosts and touch de zunou
2023-02-19 13:51:23 +01:00
Flyinghead
bf79183bd6
mmu: max alignment requirement is 32-bit
...
a 64-bit access only needs to be 32-bit aligned.
use enum for mmu errors
2023-02-18 13:33:38 +01:00
Flyinghead
afcb3b7ad8
mmu: get rid of FullMMU option. Detect wince with string id in ram
...
ForceWindowsCE now just sets ExtraDepthScale
2023-02-18 13:33:38 +01:00
Flyinghead
5bfbcb210c
dynarec: refactor imm mem r/w and store queue handlers. clean up mmu
...
Eliminate duplicate code for immediate memory read/write in all dynarecs
Simplify PREF to use do_sqw_nommu even for simple SQ remap
Check for address errors before mmu translation
Get rid of unneeded template params in mmu translation funcs
2023-02-18 13:33:38 +01:00
scribam
d8137a967c
C++17 ( #926 )
...
* cmake: use c++17
* Use std::size
* Use std::make_unique
* Use std::clamp
* Use structured binding
* Use [[fallthrough]]
* Use enable_if_t/is_enum_v/is_integral_v/is_same_v
* Use if constexpr
* Use try_emplace
* Use auto for iterators
* Use inline variables
2023-02-18 13:24:34 +01:00
Flyinghead
04df0da7cb
pvr: increase index size for wild riders
...
Index overrun with wild riders
Fixes MINIDUMP-7A
2023-02-12 15:05:02 +01:00
Flyinghead
5eeddecb40
maple: set bus speed back to 2Mbps. Worms Pinball needs FFBE
...
Power Drift crashes with 1Mbps
partial revert of 2332884d8b
Force Slave Zero to use real bios (still has issues)
Worms Pinball prototype needs full framebuffer emulation
2023-02-12 15:05:02 +01:00
Flyinghead
0f90293252
dynarec: handle illegal instructions
2023-02-10 14:53:54 +01:00
Flyinghead
0d166e1403
msvc build fix
2023-02-10 14:17:45 +01:00
Flyinghead
5b169b7f9d
naomi: use master pid to make unique multiboard shared mem file on unix
2023-02-10 12:54:20 +01:00
Flyinghead
099a758c94
hw: new hardware register implementation
...
used for sh4 mm registers and holly
ignore incorrect size reads and writes
separate data and read/write handlers
2023-02-10 12:51:36 +01:00
Flyinghead
5020a267af
pvr: fix unsorted pass triangle count. tr count should accumulate
...
partial revert of 927db7f189
Fix missing walls in Bust a Move 4 (vs)
2023-02-06 15:09:18 +01:00
Flyinghead
debe21de7b
Merge remote-tracking branch 'origin/master' into dev
2023-02-05 22:20:28 +01:00
Flyinghead
37c17e4300
pvr: re-use TA contexts if not used for 60 frames
2023-02-05 18:32:35 +01:00
Flyinghead
927db7f189
pvr: sorted triangle count incorrect with multiple render passes
...
causes crash in setProvokingVertex
Fix for MINIDUMP-7A, MINIDUMP-7H, MINIDUMP-7J
2023-02-05 11:18:18 +01:00
Flyinghead
6e940e4d08
ggpo: move endOfFrame() call back to start render
...
Naomi2 TA context geometry for the current frame is lost when
rollbacking during vblank in because it hasn't been queued for render
yet.
Fixes black screen after GGPO rollback for Naomi 2 games
2023-02-03 11:34:58 +01:00
Flyinghead
bfdab4db20
pvr: add dummy sorted triangle to signal that per triangle is in use
...
Avoids crash when sorted triangle list is empty and renderer uses wrong
index values
2023-02-03 11:07:21 +01:00
Flyinghead
f0e4574132
aica arm: stop the cpu if setting an illegal mode instead of crashing
...
Fixes MINIDUMP-70
2023-02-03 11:03:08 +01:00
Flyinghead
d1e6ee9cd7
pvr: add a dummy sorted triangle if list is empty
...
this signals that sorted triangles are being used otherwise wrong
indexes values lead to a crash
2023-02-02 20:19:52 +01:00
Flyinghead
6b2063b06f
GGPO fixes
...
Memwatchers weren't properly reset after a ggpo session.
Race condition when stopping if GGPO restarts the cpu for a new frame.
The emu thread might still run some rollback frames before stopping, so
the emu state must be updated only after ggpo is stopped.
Fixes MINIDUMP-6P
Don't autosavestate when GGPO is on
Really disable renderer during GGPO advance frame
Don't stop the sh4 after render (single threaded) when GGPO is on
android: Don't restart when unpaused if online
2023-02-01 18:04:26 +01:00
Flyinghead
e70a0dcf3d
sh4_fpu clean up. tests
2023-02-01 13:53:32 +01:00
Flyinghead
d1ab3461a6
savestates: dropping support for old formats
...
savestates older than 3 years aren't supported anymore
2023-01-31 17:57:54 +01:00
Flyinghead
04c418d02a
serialize: move code out of serialize.cpp and into modules
2023-01-31 10:13:03 +01:00
Flyinghead
528235ce9d
jvs: fix kingrt66 instant win with accelerator
2023-01-30 13:28:14 +01:00
Flyinghead
27ea6ca092
aica: rename mem and reg accessors
2023-01-30 13:21:43 +01:00
Flyinghead
53dab29ddb
iOS and Switch build fixes
2023-01-30 11:10:14 +01:00
Flyinghead
b1479e6e34
aica: use namespaces, simplify api, handle serialization
...
Rename VArray2 to RamRegion. Add alloc(), free(), setRegion() and
de/serialize()
2023-01-30 10:40:07 +01:00
Flyinghead
143073b61d
rename _vmem to addrspace and move platform vmem stuff to virtmem ns
...
use namespaces
simplify names
no functional changes
2023-01-29 18:48:33 +01:00
Flyinghead
0c01075ba8
__fastcall goes after return type
2023-01-29 14:07:37 +01:00
Flyinghead
1149d499a8
x86: windows ce support in dynarec
...
clean up some unused methods and return values
2023-01-28 19:22:36 +01:00
Flyinghead
0a27b63584
aica: remove useless verify on reg access sizes
...
Fixes MINIDUMP-6C
2023-01-28 18:22:39 +01:00
Flyinghead
99d5266aa0
Merge remote-tracking branch 'origin/master' into dev
...
# Conflicts:
# core/hw/holly/sb_mem.cpp
# core/hw/naomi/naomi.cpp
# core/hw/naomi/naomi_flashrom.cpp
# core/hw/pvr/ta_ctx.h
# core/rend/gui.cpp
2023-01-27 15:41:45 +01:00
Flyinghead
610e3cf968
naomi: avoid crash with M4 carts if M4 key is missing
...
Fix shorsepr crash at boot
Fixes MINIDUMP-5Z
2023-01-27 13:03:52 +01:00
Flyinghead
e18a4afcbb
vk and pvr fixes. Renderer::Process returns void. N2 light 0 is no-light
...
pvr: Heap use after free due to PolyParam vector reallocation
vk: fix wrong buffer size calculation
Renderer::Process now returns void since it can't fail anymore
naomi2: light model at index 0 is "no light"
dx9, gles: throw if naomi 2 not supported
2023-01-27 11:16:25 +01:00
Flyinghead
499f86b065
pvr: use std::vector instead of List<> in render context
...
Remove overrun-related code.
Replace N2 matrix and light model pointers with indices.
2023-01-26 14:13:28 +01:00
scribam
80cf4406a7
cleanup include headers
2023-01-26 10:06:51 +01:00
Flyinghead
1c4871acb3
naomi: fix derbyocw rom list
...
was using drbyocwa roms
2023-01-25 17:16:52 +01:00
Flyinghead
1a681746b5
mmu: fix rte delay slot fetch address error with slow mmu
...
slow mmu clean up
P4 isn't executable
mmu test
mmu_TranslateSQW: throw exception but don't return status
2023-01-24 21:17:48 +01:00
Flyinghead
5096d50d37
move rom/flash stuff to hw/flashrom. nvmem api
2023-01-24 19:17:48 +01:00
Flyinghead
bbff377ceb
maple: less log on dma error
...
Fixes GameShark CDX log spam
See MINIDUMP-5R
2023-01-24 14:30:09 +01:00
Flyinghead
f8372c51a7
Revert "wip headers"
...
This reverts commit e3e2c3a0d2
.
2023-01-24 14:26:14 +01:00
Flyinghead
31debefbe1
release dynarec mem allocs when terminating, including arm and dsp
...
Issue #453
2023-01-24 09:21:46 +01:00
Flyinghead
c7d214e55a
aica: update pending ints when enable mask is changed
...
Updating interrupts masks SCIEB and MCIEB can enable new interrupts so
check for that.
Only avoid race condition when needed.
2023-01-23 20:04:18 +01:00
scribam
e3e2c3a0d2
wip headers
2023-01-23 18:29:04 +01:00
Flyinghead
cc408f9688
aica arm7: fallback to interpreter for invalid LDR/STR
...
Fixes MINIDUMP-4X
2023-01-22 18:11:03 +01:00
Flyinghead
88384ad7d1
dynarec: crash in rdv_BlockCheckFail when current block can't be found
...
Only when MMU is on and used to compute blockcheck_failures so can be
ignored.
Tentative fix for MINIDUMP-59
2023-01-22 17:13:34 +01:00
Flyinghead
464b459073
modem: don't die when reg11 is written
...
Fix for MINIDUMP-5A
2023-01-22 17:10:12 +01:00
Flyinghead
9473c235f2
sh4: Fix CCN_MMUCR register definition
...
Some reserved bits were missing, which was breaking the (slow) MMU since
the write mask is correct.
2023-01-21 12:11:42 +01:00