openMSX
Video9000.hh
Go to the documentation of this file.
1 #ifndef VIDEO9000_HH
2 #define VIDEO9000_HH
3 
4 #include "MSXDevice.hh"
6 #include "VideoLayer.hh"
7 #include "EventListener.hh"
8 
9 namespace openmsx {
10 
11 class VDP;
12 class V9990;
13 class PostProcessor;
14 
15 class Video9000 final : public MSXDevice
17  , private VideoLayer
18  , private EventListener
19 {
20 public:
21  explicit Video9000(const DeviceConfig& config);
22  ~Video9000() override;
23 
24  // MSXDevice
25  void init() override;
26  void reset(EmuTime::param time) override;
27  void writeIO(word port, byte value, EmuTime::param time) override;
28 
29  template<typename Archive>
30  void serialize(Archive& ar, unsigned version);
31 
32 private:
33  void recalc();
34  void recalcVideoSource();
35 
36  // VideoSystemChangeListener
37  void preVideoSystemChange() override;
38  void postVideoSystemChange() override;
39 
40  // VideoLayer
41  void paint(OutputSurface& output) override;
42  void takeRawScreenShot(unsigned height, const std::string& filename) override;
43 
44  // EventListener
45  int signalEvent(const std::shared_ptr<const Event>& event) override;
46 
47  // Observer<Setting>
48  void update(const Setting& setting) override;
49 
50 private:
51  VideoSourceSetting& videoSourceSetting;
52  VDP* vdp;
53  V9990* v9990;
54  Layer* activeLayer;
55  PostProcessor* v99x8Layer;
56  PostProcessor* v9990Layer;
57  byte value;
58 };
59 
60 } // namespace openmsx
61 
62 #endif
openmsx::MSXDevice
An MSXDevice is an emulated hardware component connected to the bus of the emulated MSX.
Definition: MSXDevice.hh:32
openmsx::VideoSourceSetting
Definition: VideoSourceSetting.hh:11
openmsx::Video9000::serialize
void serialize(Archive &ar, unsigned version)
Definition: Video9000.cc:170
openmsx::VDP
Unified implementation of MSX Video Display Processors (VDPs).
Definition: VDP.hh:63
openmsx::DeviceConfig
Definition: DeviceConfig.hh:20
openmsx::Video9000::Video9000
Video9000(const DeviceConfig &config)
Definition: Video9000.cc:17
EventListener.hh
openmsx::Setting
Definition: Setting.hh:120
VideoSystemChangeListener.hh
openmsx::VideoLayer
Definition: VideoLayer.hh:19
openmsx::Video9000::init
void init() override
Definition: Video9000.cc:32
openmsx::Video9000
Definition: Video9000.hh:19
openmsx::V9990
V9990
Definition: V9990.cc:963
openmsx::filename
constexpr const char *const filename
Definition: FirmwareSwitch.cc:10
MSXDevice.hh
openmsx::Layer
Interface for display layers.
Definition: Layer.hh:12
openmsx::PostProcessor
Abstract base class for post processors.
Definition: PostProcessor.hh:30
openmsx::EventListener
Definition: EventListener.hh:11
openmsx::VDP
VDP
Definition: VDP.cc:1918
VideoLayer.hh
openmsx::word
uint16_t word
16 bit unsigned integer
Definition: openmsx.hh:29
openmsx::Video9000::reset
void reset(EmuTime::param time) override
This method is called on reset.
Definition: Video9000.cc:57
openmsx::OutputSurface
A frame buffer where pixels can be written to.
Definition: OutputSurface.hh:20
openmsx::Video9000::~Video9000
~Video9000() override
Definition: Video9000.cc:50
openmsx::VideoSystemChangeListener
Definition: VideoSystemChangeListener.hh:7
openmsx
This file implemented 3 utility functions:
Definition: Autofire.cc:5
openmsx::Video9000::writeIO
void writeIO(word port, byte value, EmuTime::param time) override
Write a byte to a given IO port at a certain time to this device.
Definition: Video9000.cc:62
openmsx::V9990
Implementation of the Yamaha V9990 VDP as used in the GFX9000 cartridge by Sunrise.
Definition: V9990.hh:31