11 const fs::path output_path(filename);
12 const fs::path parent = output_path.has_parent_path() ? output_path.parent_path() : fs::path(
".");
13 const std::string name = output_path.filename().empty() ? std::string(
"output") : output_path.filename().string();
14 return parent / (
"video_file-" + name +
"-" + std::string(suffix));
45 fs::path
snapshot_path(
const fs::path &directory, std::uint32_t width, std::uint32_t height, std::uint64_t &counter,
SnapshotFormat format, std::chrono::system_clock::time_point timestamp) {
46 const std::time_t timestamp_time = std::chrono::system_clock::to_time_t(timestamp);
49 localtime_s(&local_time, ×tamp_time);
51 localtime_r(×tamp_time, &local_time);
54 std::ostringstream filename;
55 filename <<
"ACMXVK.Snapshot-" << std::put_time(&local_time,
"%Y.%m.%d-%H.%M.%S") <<
'-' << width <<
'x' << height <<
'-' << counter <<
snapshot_extension(format);
56 const fs::path candidate = directory / filename.str();
57 if (!fs::exists(candidate)) {
fs::path snapshot_path(const fs::path &directory, std::uint32_t width, std::uint32_t height, std::uint64_t &counter, SnapshotFormat format, std::chrono::system_clock::time_point timestamp)