a914ff2d9e06893328abee2fe40fb7b82ac89c02 from master; display DCP container size...
authorCarl Hetherington <cth@carlh.net>
Mon, 25 May 2015 02:13:15 +0000 (03:13 +0100)
committerCarl Hetherington <cth@carlh.net>
Mon, 25 May 2015 02:13:15 +0000 (03:13 +0100)
ChangeLog
TO_PORT
src/wx/dcp_panel.cc
src/wx/dcp_panel.h

index 307068e5b1df2514c549dfbe1d1839324b1b2f2d..1472137f0df077f4428d9f7785e3b9e67a4a2f6e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2015-05-25  Carl Hetherington  <cth@carlh.net>
 
+       * Display DCP container size beside the choice
+       in the DCP tab.
+
        * Try to set up useful default colour conversions
        depending on the type and resolution of content (#565).
 
diff --git a/TO_PORT b/TO_PORT
index d153948fa7d8f5a7315b1c298de8a479cbaf0961..383230e8ce5364d207a267636a8b17d1617ab740 100644 (file)
--- a/TO_PORT
+++ b/TO_PORT
@@ -1,4 +1,3 @@
-ccb883a479cb341c686fc4237763f483d15e1ec5
 8e5f3e2d989a119f41ba4c69434545c0929e92e0
 468a7437c8ec82a8f74ae30197a2c5b04100b75d
 2bf46f7c75c59e4cd3d91f1ddd322bdabb19b6f4
index ccfe5711cf717b3b9586be6d0188308cc0f88a1c..5957dc9d0013f409ce0e82d8e7ada60771ffdcdb 100644 (file)
@@ -299,6 +299,7 @@ DCPPanel::film_changed (int p)
                break;
        case Film::RESOLUTION:
                checked_set (_resolution, _film->resolution() == RESOLUTION_2K ? 0 : 1);
+               setup_container ();
                setup_dcp_name ();
                break;
        case Film::J2K_BANDWIDTH:
@@ -375,8 +376,11 @@ DCPPanel::setup_container ()
        
        if (i == ratios.end()) {
                checked_set (_container, -1);
+               checked_set (_container_size, wxT (""));
        } else {
                checked_set (_container, n);
+               dcp::Size const size = fit_ratio_within (_film->container()->ratio(), _film->full_frame ());
+               checked_set (_container_size, wxString::Format ("%dx%d", size.width, size.height));
        }
        
        setup_dcp_name ();
@@ -554,9 +558,15 @@ DCPPanel::make_video_panel ()
        int r = 0;
        
        add_label_to_grid_bag_sizer (grid, panel, _("Container"), true, wxGBPosition (r, 0));
-       _container = new wxChoice (panel, wxID_ANY);
-       grid->Add (_container, wxGBPosition (r, 1));
-       ++r;
+       {
+               wxBoxSizer* s = new wxBoxSizer (wxHORIZONTAL);
+               _container = new wxChoice (panel, wxID_ANY);
+               s->Add (_container, 1, wxEXPAND | wxRIGHT, DCPOMATIC_SIZER_X_GAP);
+               _container_size = new wxStaticText (panel, wxID_ANY, wxT (""));
+               s->Add (_container_size, 1, wxLEFT | wxALIGN_CENTER_VERTICAL);
+               grid->Add (s, wxGBPosition (r,1 ), wxDefaultSpan, wxEXPAND);
+               ++r;
+       }
 
        {
                add_label_to_grid_bag_sizer (grid, panel, _("Frame Rate"), true, wxGBPosition (r, 0));
index 96786d8a1d93ef912881498e796fc2654b4c2501..d2f32cc211c2ef4ffcde31d07970fce7813d554f 100644 (file)
@@ -87,6 +87,7 @@ private:
        wxStaticText* _dcp_name;
        wxCheckBox* _use_isdcf_name;
        wxChoice* _container;
+       wxStaticText* _container_size;
        wxButton* _edit_isdcf_button;
        wxButton* _copy_isdcf_name_button;
        wxSpinCtrl* _j2k_bandwidth;