mirror of
https://github.com/bsnes-emu/bsnes.git
synced 2025-02-24 07:02:27 +01:00
byuu says: Changelog: - higan: Emulator::Interface::videoSize() renamed to videoResolution() - higan: Emulator::Interface::rtcsync() renamed to rtcSynchronize() - higan: added video display rotation support to Video - GBA: substantially improved audio mixing - fixed bug with FIFO 50%/100% volume setting - now properly using SOUNDBIAS amplitude to control output frequencies - reduced quantization noise - corrected relative volumes between PSG and FIFO channels - both PSG and FIFO values cached based on amplitude; resulting in cleaner PCM samples - treating PSG volume=3 as 200% volume instead of 0% volume now (unverified: to match mGBA) - GBA: properly initialize ALL CPU state; including the vital prefetch.wait=1 (fixes Classic NES series games) - GBA: added video rotation with automatic key translation support - PCE: reduced output resolution scalar from 285x242 to 285x240 - the extra two scanlines won't be visible on most TVs; and they make all other cores look worse - this is because all other cores output at 240p or less; so they were all receiving black bars in windowed mode - tomoko: added "Rotate Display" hotkey setting - tomoko: changed hotkey multi-key logic to OR instead of AND - left support for flipping it back inside the core; for those so inclined; by uncommenting one line in input.hpp - tomoko: when choosing Settings→Configuration, it will automatically select the currently loaded system - for instance, if you're playing a Game Gear game, it'll take you to the Game Gear input settings - if no games are loaded, it will take you to the hotkeys panel instead - WS(C): merged "Hardware-Vertical", "Hardware-Horizontal" controls into combined "Hardware" - WS(C): converted rotation support from being inside the core to using Emulator::Video - this lets WS(C) video content scale larger now that it's not bounded by a 224x224 square box - WS(C): added automatic key rotation support - WS(C): removed emulator "Rotate" key (use the general hotkey instead; I recommend F8 for this) - nall: added serializer support for nall::Boolean (boolean) types - although I will probably prefer the usage of uint1 in most cases
64 lines
1.5 KiB
C++
64 lines
1.5 KiB
C++
struct System : IO {
|
|
auto loaded() const -> bool { return _loaded; }
|
|
auto model() const -> Model { return _model; }
|
|
auto color() const -> bool { return r.color; }
|
|
auto planar() const -> bool { return r.format == 0; }
|
|
auto packed() const -> bool { return r.format == 1; }
|
|
auto depth() const -> bool { return r.color && r.depth == 1; }
|
|
|
|
auto init() -> void;
|
|
auto term() -> void;
|
|
auto load(Emulator::Interface*, Model) -> bool;
|
|
auto save() -> void;
|
|
auto unload() -> void;
|
|
auto power() -> void;
|
|
auto run() -> void;
|
|
auto runToSave() -> void;
|
|
auto pollKeypad() -> void;
|
|
|
|
//io.cpp
|
|
auto portRead(uint16 addr) -> uint8 override;
|
|
auto portWrite(uint16 addr, uint8 data) -> void override;
|
|
|
|
//video.cpp
|
|
auto configureVideoPalette() -> void;
|
|
auto configureVideoEffects() -> void;
|
|
|
|
//serialization.cpp
|
|
auto serializeInit() -> void;
|
|
auto serialize() -> serializer;
|
|
auto unserialize(serializer&) -> bool;
|
|
auto serializeAll(serializer&) -> void;
|
|
auto serialize(serializer&) -> void;
|
|
|
|
struct Information {
|
|
string manifest;
|
|
} information;
|
|
|
|
EEPROM eeprom;
|
|
|
|
struct Keypad {
|
|
bool y1, y2, y3, y4;
|
|
bool x1, x2, x3, x4;
|
|
bool b, a, start;
|
|
bool rotate;
|
|
} keypad;
|
|
|
|
private:
|
|
Emulator::Interface* interface = nullptr;
|
|
|
|
struct Registers {
|
|
//$0060 DISP_MODE
|
|
uint5 unknown;
|
|
uint1 format;
|
|
uint1 depth;
|
|
uint1 color;
|
|
} r;
|
|
|
|
bool _loaded = false;
|
|
Model _model = Model::WonderSwan;
|
|
uint _serializeSize = 0;
|
|
};
|
|
|
|
extern System system;
|