Don't show DSP stats of inserts that don't collect them.
[ardour.git] / gtk2_ardour / utils_videotl.cc
index 3933022adc1fa0959800f6610c2d12caa52307a4..11b7230dde4c27a504d7f2a9c41eec107611589c 100644 (file)
@@ -23,6 +23,7 @@
 #include <gtkmm.h>
 
 #include "pbd/error.h"
+#include "pbd/string_convert.h"
 
 #include "ardour/ardour.h"
 #include "ardour/session_directory.h"
@@ -266,14 +267,13 @@ VideoUtils::video_query_info (
                double &video_aspect_ratio
                )
 {
-       LocaleGuard lg;
        char url[2048];
 
        snprintf(url, sizeof(url), "%s%sinfo/?file=%s&format=csv"
                        , video_server_url.c_str()
                        , (video_server_url.length()>0 && video_server_url.at(video_server_url.length()-1) == '/')?"":"/"
                        , filepath.c_str());
-       std::string res = ArdourCurl::http_get (url);
+       std::string res = ArdourCurl::http_get (url, false);
        if (res.empty ()) {
                return false;
        }
@@ -286,9 +286,9 @@ VideoUtils::video_query_info (
        }
        if (atoi(lines.at(0).at(0)) != 1) return false; // version
        video_start_offset = 0.0;
-       video_aspect_ratio = atof (lines.at(0).at(3));
-       video_file_fps = atof (lines.at(0).at(4));
-       video_duration = atoll(lines.at(0).at(5));
+       video_aspect_ratio = string_to<double>(lines.at(0).at(3));
+       video_file_fps = string_to<double>(lines.at(0).at(4));
+       video_duration = string_to<int64_t>(lines.at(0).at(5));
 
        if (video_aspect_ratio < 0.01 || video_file_fps < 0.01) {
                /* catch errors early, aspect == 0 or fps == 0 will