Try doing it after Pango::init().
authorCarl Hetherington <cth@carlh.net>
Fri, 1 Feb 2019 22:02:14 +0000 (22:02 +0000)
committerCarl Hetherington <cth@carlh.net>
Fri, 1 Feb 2019 22:02:14 +0000 (22:02 +0000)
src/lib/util.cc

index 4574757e0ae13e522f611aa7ee6870e594b53c42..fe8b193d6f8778d4e149863e97f16cc9c706dbd2 100644 (file)
@@ -364,7 +364,12 @@ dcpomatic_setup ()
 #ifdef DCPOMATIC_WINDOWS
        putenv ("PANGOCAIRO_BACKEND=fontconfig");
        putenv (String::compose("FONTCONFIG_PATH=%1", shared_path().string()).c_str());
+#endif
+
+       Pango::init ();
+       dcp::init ();
 
+#ifdef DCPOMATIC_WINDOWS
        /* Render something to fontconfig to create its cache */
        list<StringText> subs;
        dcp::SubtitleString ss(
@@ -375,9 +380,6 @@ dcpomatic_setup ()
        render_text (subs, list<shared_ptr<Font> >(), dcp::Size(640, 480), DCPTime(), 24);
 #endif
 
-       Pango::init ();
-       dcp::init ();
-
        Ratio::setup_ratios ();
        PresetColourConversion::setup_colour_conversion_presets ();
        VideoContentScale::setup_scales ();