2 Copyright (C) 2012-2022 Carl Hetherington <cth@carlh.net>
4 This file is part of DCP-o-matic.
6 DCP-o-matic is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 DCP-o-matic is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with DCP-o-matic. If not, see <http://www.gnu.org/licenses/>.
23 #include "lib/config.h"
24 #include "lib/film_property.h"
42 class DCPTimelineDialog;
45 class InteropMetadataDialog;
48 class SMPTEMetadataDialog;
53 DCPPanel(wxNotebook *, std::shared_ptr<Film>, FilmViewer& viewer);
55 DCPPanel (DCPPanel const&) = delete;
56 DCPPanel& operator= (DCPPanel const&) = delete;
58 void set_film (std::shared_ptr<Film>);
59 void set_general_sensitivity (bool);
61 void film_changed(FilmProperty);
62 void film_content_changed (int);
64 wxPanel* panel () const {
70 void use_isdcf_name_toggled ();
71 void copy_isdcf_name_button_clicked ();
72 void container_changed ();
73 void dcp_content_type_changed ();
74 void j2k_bandwidth_changed ();
75 void frame_rate_choice_changed ();
76 void frame_rate_spin_changed ();
77 void best_frame_rate_clicked ();
78 void content_timeline_clicked ();
79 void audio_channels_changed ();
80 void resolution_changed ();
81 void three_d_changed ();
82 void standard_changed ();
83 void encrypted_toggled ();
84 void audio_processor_changed ();
85 void show_audio_clicked ();
86 void markers_clicked ();
87 void metadata_clicked ();
89 void reencode_j2k_changed ();
90 void enable_audio_language_toggled ();
91 void edit_audio_language_clicked ();
92 void audio_sample_rate_changed ();
94 void setup_frame_rate_widget ();
95 void setup_container ();
96 void setup_dcp_name ();
98 void add_video_panel_to_grid ();
99 void add_audio_panel_to_grid ();
100 void add_audio_processors ();
101 void add_standards();
104 int minimum_allowed_audio_channels () const;
106 wxPanel* make_general_panel ();
107 wxPanel* make_video_panel ();
108 wxPanel* make_audio_panel ();
110 void config_changed (Config::Property p);
112 void setup_sensitivity ();
115 wxNotebook* _notebook;
117 wxGridBagSizer* _grid;
118 wxGridBagSizer* _video_grid;
119 wxGridBagSizer* _audio_grid;
121 wxStaticText* _name_label;
123 wxStaticText* _dcp_name;
124 CheckBox* _use_isdcf_name;
125 CheckBox* _enable_audio_language = nullptr;
126 wxStaticText* _audio_language = nullptr;
127 Button* _edit_audio_language = nullptr;
128 wxStaticText* _container_label;
130 wxStaticText* _container_size;
131 wxButton* _copy_isdcf_name_button;
132 wxStaticText* _j2k_bandwidth_label;
133 wxStaticText* _mbits_label;
134 wxSpinCtrl* _j2k_bandwidth;
135 wxStaticText* _dcp_content_type_label;
136 Choice* _dcp_content_type;
137 wxStaticText* _frame_rate_label;
138 Choice* _frame_rate_choice;
139 wxSpinCtrl* _frame_rate_spin;
140 wxSizer* _frame_rate_sizer;
141 wxStaticText* _channels_label;
142 Choice* _audio_channels;
143 wxStaticText* _audio_sample_rate_label = nullptr;
144 wxChoice* _audio_sample_rate = nullptr;
145 wxStaticText* _processor_label;
146 Choice* _audio_processor;
147 wxButton* _show_audio;
148 wxButton* _best_frame_rate;
150 CheckBox* _reencode_j2k;
151 wxStaticText* _resolution_label;
153 wxStaticText* _standard_label;
155 CheckBox* _encrypted;
159 wxSizer* _audio_panel_sizer;
161 wx_ptr<AudioDialog> _audio_dialog;
162 wx_ptr<MarkersDialog> _markers_dialog;
163 wx_ptr<InteropMetadataDialog> _interop_metadata_dialog;
164 wx_ptr<SMPTEMetadataDialog> _smpte_metadata_dialog;
165 wx_ptr<DCPTimelineDialog> _dcp_timeline;
167 std::shared_ptr<Film> _film;
169 bool _generally_sensitive;