1//============================================================================
2//
3// SSSS tt lll lll
4// SS SS tt ll ll
5// SS tttttt eeee ll ll aaaa
6// SSSS tt ee ee ll ll aa
7// SS tt eeeeee ll ll aaaaa -- "An Atari 2600 VCS Emulator"
8// SS SS tt ee ll ll aa aa
9// SSSS ttt eeeee llll llll aaaaa
10//
11// Copyright (c) 1995-2019 by Bradford W. Mott, Stephen Anthony
12// and the Stella Team
13//
14// See the file "License.txt" for information on usage and redistribution of
15// this file, and for a DISCLAIMER OF ALL WARRANTIES.
16//============================================================================
17
18#ifndef VIDEO_DIALOG_HXX
19#define VIDEO_DIALOG_HXX
20
21class CommandSender;
22class CheckboxWidget;
23class DialogContainer;
24class PopUpWidget;
25class SliderWidget;
26class StaticTextWidget;
27class TabWidget;
28class OSystem;
29
30#include "Dialog.hxx"
31#include "NTSCFilter.hxx"
32#include "bspf.hxx"
33
34class VideoDialog : public Dialog
35{
36 public:
37 VideoDialog(OSystem& osystem, DialogContainer& parent, const GUI::Font& font,
38 int max_w, int max_h);
39 virtual ~VideoDialog() = default;
40
41 private:
42 void loadConfig() override;
43 void saveConfig() override;
44 void setDefaults() override;
45
46 void handleTVModeChange(NTSCFilter::Preset);
47 void loadTVAdjustables(NTSCFilter::Preset preset);
48 void handleFullScreenChange();
49 void handleOverscanChange();
50 void handlePhosphorChange();
51 void handleCommand(CommandSender* sender, int cmd, int data, int id) override;
52
53 private:
54 TabWidget* myTab;
55
56 // General options
57 PopUpWidget* myRenderer;
58 SliderWidget* myTIAZoom;
59 PopUpWidget* myTIAPalette;
60 CheckboxWidget* myTIAInterpolate;
61 SliderWidget* myNAspectRatio;
62 SliderWidget* myPAspectRatio;
63 SliderWidget* mySpeed;
64
65 CheckboxWidget* myFullscreen;
66 //PopUpWidget* myFullScreenMode;
67 CheckboxWidget* myUseStretch;
68 SliderWidget* myTVOverscan;
69 CheckboxWidget* myUseVSync;
70 CheckboxWidget* myUIMessages;
71 CheckboxWidget* myCenter;
72 CheckboxWidget* myFastSCBios;
73 CheckboxWidget* myUseThreads;
74
75 // TV effects adjustables (custom mode)
76 PopUpWidget* myTVMode;
77 SliderWidget* myTVSharp;
78 SliderWidget* myTVHue;
79 SliderWidget* myTVRes;
80 SliderWidget* myTVArtifacts;
81 SliderWidget* myTVFringe;
82 SliderWidget* myTVBleed;
83 SliderWidget* myTVBright;
84 SliderWidget* myTVContrast;
85 SliderWidget* myTVSatur;
86 SliderWidget* myTVGamma;
87
88 // TV phosphor effect
89 CheckboxWidget* myTVPhosphor;
90 SliderWidget* myTVPhosLevel;
91
92 // TV scanline intensity and interpolation
93 StaticTextWidget* myTVScanLabel;
94 SliderWidget* myTVScanIntense;
95
96 // TV effects adjustables presets (custom mode)
97 ButtonWidget* myCloneComposite;
98 ButtonWidget* myCloneSvideo;
99 ButtonWidget* myCloneRGB;
100 ButtonWidget* myCloneBad;
101 ButtonWidget* myCloneCustom;
102
103 enum {
104 kSpeedupChanged = 'VDSp',
105 kFullScreenChanged = 'VDFs',
106 kOverscanChanged = 'VDOv',
107
108 kTVModeChanged = 'VDtv',
109 kCloneCompositeCmd = 'CLcp',
110 kCloneSvideoCmd = 'CLsv',
111 kCloneRGBCmd = 'CLrb',
112 kCloneBadCmd = 'CLbd',
113 kCloneCustomCmd = 'CLcu',
114 kPhosphorChanged = 'VDph',
115 kPhosBlendChanged = 'VDbl',
116 kScanlinesChanged = 'VDsc'
117 };
118
119 private:
120 // Following constructors and assignment operators not supported
121 VideoDialog() = delete;
122 VideoDialog(const VideoDialog&) = delete;
123 VideoDialog(VideoDialog&&) = delete;
124 VideoDialog& operator=(const VideoDialog&) = delete;
125 VideoDialog& operator=(VideoDialog&&) = delete;
126};
127
128#endif
129