mirror of https://github.com/mgba-emu/mgba.git
GB BIOS: Include timing in degenerate ArcTan2 cases (fixes #2763)
This commit is contained in:
parent
520609d12a
commit
0a4cafcd57
1
CHANGES
1
CHANGES
|
@ -7,6 +7,7 @@ Emulation fixes:
|
|||
- GB Audio: Fix channel 3 volume being changed between samples (fixes mgba.io/i/1896)
|
||||
- GB Audio: Fix up boot sequence
|
||||
- GB Audio: Fix updating channels other than 2 when writing NR5x
|
||||
- GB BIOS: Include timing in degenerate ArcTan2 cases (fixes mgba.io/i/2763)
|
||||
- GB Memory: Actually, HDMAs should start when LCD is off (fixes mgba.io/i/2662)
|
||||
- GB Serialize: Don't write BGP/OBP when loading SCGB state (fixes mgba.io/i/2694)
|
||||
- GB SIO: Further fix bidirectional transfer starting
|
||||
|
|
|
@ -336,12 +336,14 @@ static int16_t _ArcTan(int32_t i, int32_t* r1, int32_t* r3, uint32_t* cycles) {
|
|||
|
||||
static int16_t _ArcTan2(int32_t x, int32_t y, int32_t* r1, uint32_t* cycles) {
|
||||
if (!y) {
|
||||
*cycles = 11;
|
||||
if (x >= 0) {
|
||||
return 0;
|
||||
}
|
||||
return 0x8000;
|
||||
}
|
||||
if (!x) {
|
||||
*cycles = 11;
|
||||
if (y >= 0) {
|
||||
return 0x4000;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue