diff options
| author | Carl Hetherington <cth@carlh.net> | 2024-12-30 15:43:14 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2025-01-05 12:58:13 +0100 |
| commit | b03f2277a205ff7e7cdaa12c6e52322ea474a7af (patch) | |
| tree | d6067668105b2f0c6d0651bd1b8bd4186e0b8893 /src/lib/subtitle_analysis.cc | |
| parent | e46ff5f1cf168fb73ea930f3e8469165e5f6644e (diff) | |
Bump libdcp for raw_convert changes.
raw_convert<string> is gone, so here we use fmt::{to_string,format} instead.
Other raw_converts now use fast_float.
Diffstat (limited to 'src/lib/subtitle_analysis.cc')
| -rw-r--r-- | src/lib/subtitle_analysis.cc | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/lib/subtitle_analysis.cc b/src/lib/subtitle_analysis.cc index 2968416c6..5f7da6e02 100644 --- a/src/lib/subtitle_analysis.cc +++ b/src/lib/subtitle_analysis.cc @@ -23,17 +23,16 @@ #include "exceptions.h" #include <libcxml/cxml.h> #include <dcp/filesystem.h> -#include <dcp/raw_convert.h> #include <dcp/warnings.h> LIBDCP_DISABLE_WARNINGS #include <libxml++/libxml++.h> LIBDCP_ENABLE_WARNINGS +#include <fmt/format.h> using std::make_shared; using std::shared_ptr; using std::string; -using dcp::raw_convert; int const SubtitleAnalysis::_current_state_version = 1; @@ -70,18 +69,18 @@ SubtitleAnalysis::write (boost::filesystem::path path) const auto doc = make_shared<xmlpp::Document>(); xmlpp::Element* root = doc->create_root_node ("SubtitleAnalysis"); - cxml::add_text_child(root, "Version", raw_convert<string>(_current_state_version)); + cxml::add_text_child(root, "Version", fmt::to_string(_current_state_version)); if (_bounding_box) { auto bounding_box = cxml::add_child(root, "BoundingBox"); - cxml::add_text_child(bounding_box, "X", raw_convert<string>(_bounding_box->x)); - cxml::add_text_child(bounding_box, "Y", raw_convert<string>(_bounding_box->y)); - cxml::add_text_child(bounding_box, "Width", raw_convert<string>(_bounding_box->width)); - cxml::add_text_child(bounding_box, "Height", raw_convert<string>(_bounding_box->height)); + cxml::add_text_child(bounding_box, "X", fmt::to_string(_bounding_box->x)); + cxml::add_text_child(bounding_box, "Y", fmt::to_string(_bounding_box->y)); + cxml::add_text_child(bounding_box, "Width", fmt::to_string(_bounding_box->width)); + cxml::add_text_child(bounding_box, "Height", fmt::to_string(_bounding_box->height)); } - cxml::add_text_child(root, "AnalysisXOffset", raw_convert<string>(_analysis_x_offset)); - cxml::add_text_child(root, "AnalysisYOffset", raw_convert<string>(_analysis_y_offset)); + cxml::add_text_child(root, "AnalysisXOffset", fmt::to_string(_analysis_x_offset)); + cxml::add_text_child(root, "AnalysisYOffset", fmt::to_string(_analysis_y_offset)); doc->write_to_file_formatted (path.string()); } |
