diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2023-11-22 13:41:14 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2023-11-22 13:41:14 +0100 |
commit | a5c6ca806b2bde216effbea7cd5d964b3f235b5f (patch) | |
tree | bd859c8082ff1460c957d965aca9f485d97bc973 /bench/loader.cpp | |
parent | be44dc48469437370abab260fbd2c91a82109f9c (diff) |
a
Diffstat (limited to 'bench/loader.cpp')
-rw-r--r-- | bench/loader.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bench/loader.cpp b/bench/loader.cpp index 6e891ab7..ec0eed17 100644 --- a/bench/loader.cpp +++ b/bench/loader.cpp @@ -10,6 +10,8 @@ namespace floormat { namespace { +using nlohmann::json; + void Loader_json(benchmark::State& state) { loader.destroy(); @@ -17,7 +19,7 @@ void Loader_json(benchmark::State& state) // warmup { for (const auto& x : loader.anim_atlas_list()) json_helper::from_json<anim_def>(Path::join(loader.ANIM_PATH, ""_s.join({x, ".json"}))); - json_helper::from_json<std::vector<nlohmann::json>>(Path::join(loader.VOBJ_PATH, "vobj.json")); + json_helper::from_json<std::vector<json>>(Path::join(loader.VOBJ_PATH, "vobj.json")); } for (auto _ : state) @@ -25,7 +27,7 @@ void Loader_json(benchmark::State& state) { for (const auto& x : loader.anim_atlas_list()) json_helper::from_json<anim_def>(Path::join(loader.ANIM_PATH, ""_s.join({x, ".json"}))); - json_helper::from_json<std::vector<nlohmann::json>>(Path::join(loader.VOBJ_PATH, "vobj.json")); + json_helper::from_json<std::vector<json>>(Path::join(loader.VOBJ_PATH, "vobj.json")); } } |