diff options
| author | Carl Hetherington <cth@carlh.net> | 2024-12-23 21:53:32 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2024-12-26 00:27:08 +0100 |
| commit | 8caf013a9b8d709ed7c3d5e9febee0067e6fcf1f (patch) | |
| tree | 40da87cb357e8b1c54a1464bdbac2d014640e30c /src/lib/shuffler.cc | |
| parent | cec6ff92aef45c687085ecfc1059004407c18c57 (diff) | |
Replace String::compose with fmt::format().
Diffstat (limited to 'src/lib/shuffler.cc')
| -rw-r--r-- | src/lib/shuffler.cc | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/lib/shuffler.cc b/src/lib/shuffler.cc index a4ea0f5dc..6b477073c 100644 --- a/src/lib/shuffler.cc +++ b/src/lib/shuffler.cc @@ -23,6 +23,7 @@ #include "content_video.h" #include "dcpomatic_assert.h" #include "dcpomatic_log.h" +#include <fmt/format.h> #include <string> #include <iostream> @@ -51,7 +52,7 @@ struct Comparator void Shuffler::video (weak_ptr<Piece> weak_piece, ContentVideo video) { - LOG_DEBUG_THREE_D("Shuffler::video time=%1 eyes=%2 part=%3", to_string(video.time), static_cast<int>(video.eyes), static_cast<int>(video.part)); + LOG_DEBUG_THREE_D("Shuffler::video time={} eyes={} part={}", to_string(video.time), static_cast<int>(video.eyes), static_cast<int>(video.part)); if (video.eyes != Eyes::LEFT && video.eyes != Eyes::RIGHT) { /* Pass through anything that we don't care about */ @@ -84,9 +85,9 @@ Shuffler::video (weak_ptr<Piece> weak_piece, ContentVideo video) ); if (!store_front_in_sequence) { - string const store = _store.empty() ? "store empty" : String::compose("store front time=%1 eyes=%2", to_string(_store.front().second.time), static_cast<int>(_store.front().second.eyes)); - string const last = _last ? String::compose("last time=%1 eyes=%2", to_string(_last->time), static_cast<int>(_last->eyes)) : "no last"; - LOG_DEBUG_THREE_D("Shuffler not in sequence: %1 %2", store, last); + string const store = _store.empty() ? "store empty" : fmt::format("store front time={} eyes={}", to_string(_store.front().second.time), static_cast<int>(_store.front().second.eyes)); + string const last = _last ? fmt::format("last time={} eyes={}", to_string(_last->time), static_cast<int>(_last->eyes)) : "no last"; + LOG_DEBUG_THREE_D("Shuffler not in sequence: {} {}", store, last); } if (!store_front_in_sequence && _store.size() <= _max_size) { @@ -98,10 +99,10 @@ Shuffler::video (weak_ptr<Piece> weak_piece, ContentVideo video) } if (_store.size() > _max_size) { - LOG_WARNING("Shuffler is full after receiving frame at %1; 3D sync may be incorrect.", to_string(video.time)); + LOG_WARNING("Shuffler is full after receiving frame at {}; 3D sync may be incorrect.", to_string(video.time)); } - LOG_DEBUG_THREE_D("Shuffler emits time=%1 eyes=%2 store=%3", to_string(_store.front().second.time), static_cast<int>(_store.front().second.eyes), _store.size()); + LOG_DEBUG_THREE_D("Shuffler emits time={} eyes={} store={}", to_string(_store.front().second.time), static_cast<int>(_store.front().second.eyes), _store.size()); Video (_store.front().first, _store.front().second); _last = _store.front().second; _store.pop_front (); |
