2016-06-05 01:43:50 +00:00
|
|
|
//
|
|
|
|
// Vic20.hpp
|
|
|
|
// Clock Signal
|
|
|
|
//
|
|
|
|
// Created by Thomas Harte on 04/06/2016.
|
2018-05-13 19:19:52 +00:00
|
|
|
// Copyright 2016 Thomas Harte. All rights reserved.
|
2016-06-05 01:43:50 +00:00
|
|
|
//
|
|
|
|
|
|
|
|
#ifndef Vic20_hpp
|
|
|
|
#define Vic20_hpp
|
|
|
|
|
2020-03-19 00:23:55 +00:00
|
|
|
#include "../../../Configurable/Configurable.hpp"
|
|
|
|
#include "../../../Configurable/StandardOptions.hpp"
|
2018-07-11 00:00:46 +00:00
|
|
|
#include "../../../Analyser/Static/StaticAnalyser.hpp"
|
|
|
|
#include "../../ROMMachine.hpp"
|
|
|
|
|
|
|
|
#include <memory>
|
2016-07-10 16:57:17 +00:00
|
|
|
|
2023-05-10 21:02:18 +00:00
|
|
|
namespace Commodore::Vic20 {
|
2016-06-05 01:43:50 +00:00
|
|
|
|
2017-11-21 02:55:32 +00:00
|
|
|
/// @returns The options available for a Vic-20.
|
2020-03-16 03:48:53 +00:00
|
|
|
std::unique_ptr<Reflection::Struct> get_options();
|
2017-11-21 02:55:32 +00:00
|
|
|
|
2018-03-09 20:19:02 +00:00
|
|
|
class Machine {
|
2016-06-05 02:00:50 +00:00
|
|
|
public:
|
2017-08-16 20:05:30 +00:00
|
|
|
virtual ~Machine();
|
2016-12-03 18:30:27 +00:00
|
|
|
|
2017-08-16 20:23:33 +00:00
|
|
|
/// Creates and returns a Vic-20.
|
2024-01-13 03:03:19 +00:00
|
|
|
static std::unique_ptr<Machine> Vic20(const Analyser::Static::Target *target, const ROMMachine::ROMFetcher &rom_fetcher);
|
2020-03-19 00:23:55 +00:00
|
|
|
|
|
|
|
class Options: public Reflection::StructImpl<Options>, public Configurable::DisplayOption<Options>, public Configurable::QuickloadOption<Options> {
|
|
|
|
friend Configurable::DisplayOption<Options>;
|
|
|
|
friend Configurable::QuickloadOption<Options>;
|
|
|
|
public:
|
|
|
|
Options(Configurable::OptionsType type) :
|
|
|
|
Configurable::DisplayOption<Options>(type == Configurable::OptionsType::UserFriendly ? Configurable::Display::SVideo : Configurable::Display::CompositeColour),
|
|
|
|
Configurable::QuickloadOption<Options>(type == Configurable::OptionsType::UserFriendly) {
|
|
|
|
if(needs_declare()) {
|
|
|
|
declare_display_option();
|
|
|
|
declare_quickload_option();
|
|
|
|
limit_enum(&output, Configurable::Display::SVideo, Configurable::Display::CompositeColour, -1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
2016-06-05 01:43:50 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif /* Vic20_hpp */
|