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() noexcept override;
38  void postVideoSystemChange() noexcept 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) noexcept override;
46 
47  // Observer<Setting>
48  void update(const Setting& setting) noexcept 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
Interface for display layers.
Definition: Layer.hh:12
An MSXDevice is an emulated hardware component connected to the bus of the emulated MSX.
Definition: MSXDevice.hh:33
A frame buffer where pixels can be written to.
Abstract base class for post processors.
Implementation of the Yamaha V9990 VDP as used in the GFX9000 cartridge by Sunrise.
Definition: V9990.hh:31
Unified implementation of MSX Video Display Processors (VDPs).
Definition: VDP.hh:63
Video9000(const DeviceConfig &config)
Definition: Video9000.cc:17
void reset(EmuTime::param time) override
This method is called on reset.
Definition: Video9000.cc:57
~Video9000() override
Definition: Video9000.cc:50
void init() override
Definition: Video9000.cc:32
void serialize(Archive &ar, unsigned version)
Definition: Video9000.cc:170
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
This file implemented 3 utility functions:
Definition: Autofire.cc:9
constexpr const char *const filename
uint16_t word
16 bit unsigned integer
Definition: openmsx.hh:29