2 Copyright (C) 2012-2019 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/>.
21 #include "lib/config.h"
22 #include <boost/shared_ptr.hpp>
23 #include <boost/noncopyable.hpp>
39 class InteropMetadataDialog;
40 class SMPTEMetadataDialog;
45 class DCPPanel : public boost::noncopyable
48 DCPPanel (wxNotebook *, boost::shared_ptr<Film>, boost::weak_ptr<FilmViewer> viewer);
50 void set_film (boost::shared_ptr<Film>);
51 void set_general_sensitivity (bool);
53 void film_changed (int);
54 void film_content_changed (int);
56 wxPanel* panel () const {
62 void use_isdcf_name_toggled ();
63 void edit_isdcf_button_clicked ();
64 void copy_isdcf_name_button_clicked ();
65 void container_changed ();
66 void dcp_content_type_changed ();
67 void j2k_bandwidth_changed ();
68 void frame_rate_choice_changed ();
69 void frame_rate_spin_changed ();
70 void best_frame_rate_clicked ();
71 void content_timeline_clicked ();
72 void audio_channels_changed ();
73 void resolution_changed ();
74 void three_d_changed ();
75 void standard_changed ();
76 void encrypted_toggled ();
77 void audio_processor_changed ();
78 void show_audio_clicked ();
79 void reel_type_changed ();
80 void reel_length_changed ();
81 void markers_clicked ();
82 void metadata_clicked ();
83 void reencode_j2k_changed ();
85 void setup_frame_rate_widget ();
86 void setup_container ();
87 void setup_dcp_name ();
89 void add_video_panel_to_grid ();
90 void add_audio_panel_to_grid ();
91 void add_audio_processors ();
93 int minimum_allowed_audio_channels () const;
95 wxPanel* make_general_panel ();
96 wxPanel* make_video_panel ();
97 wxPanel* make_audio_panel ();
99 void config_changed (Config::Property p);
101 void setup_sensitivity ();
104 wxNotebook* _notebook;
106 wxGridBagSizer* _grid;
107 wxGridBagSizer* _video_grid;
108 wxGridBagSizer* _audio_grid;
110 wxStaticText* _name_label;
112 wxStaticText* _dcp_name;
113 wxCheckBox* _use_isdcf_name;
114 wxStaticText* _container_label;
115 wxChoice* _container;
116 wxStaticText* _container_size;
117 wxButton* _edit_isdcf_button;
118 wxButton* _copy_isdcf_name_button;
119 wxStaticText* _j2k_bandwidth_label;
120 wxStaticText* _mbits_label;
121 wxSpinCtrl* _j2k_bandwidth;
122 wxStaticText* _dcp_content_type_label;
123 wxChoice* _dcp_content_type;
124 wxStaticText* _frame_rate_label;
125 wxChoice* _frame_rate_choice;
126 wxSpinCtrl* _frame_rate_spin;
127 wxSizer* _frame_rate_sizer;
128 wxStaticText* _channels_label;
129 wxChoice* _audio_channels;
130 wxStaticText* _processor_label;
131 wxChoice* _audio_processor;
132 wxButton* _show_audio;
133 wxButton* _best_frame_rate;
134 wxCheckBox* _three_d;
135 wxCheckBox* _reencode_j2k;
136 wxStaticText* _resolution_label;
137 wxChoice* _resolution;
138 wxStaticText* _standard_label;
140 wxCheckBox* _encrypted;
141 wxStaticText* _reels_label;
142 wxChoice* _reel_type;
143 wxStaticText* _reel_length_label;
144 wxStaticText* _reel_length_gb_label;
145 wxSpinCtrl* _reel_length;
148 wxSizer* _audio_panel_sizer;
150 AudioDialog* _audio_dialog;
151 MarkersDialog* _markers_dialog;
152 InteropMetadataDialog* _interop_metadata_dialog;
153 SMPTEMetadataDialog* _smpte_metadata_dialog;
155 boost::shared_ptr<Film> _film;
156 boost::weak_ptr<FilmViewer> _viewer;
157 bool _generally_sensitive;