summaryrefslogtreecommitdiffhomepage
path: root/serialize/scenery.hpp
blob: 93ceeb578222a01095741f8c975192779b6c123b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#pragma once
#include "src/scenery.hpp"
#include <Corrade/Containers/String.h>
#include <nlohmann/json_fwd.hpp>

namespace floormat { struct serialized_scenery; }

namespace nlohmann {

template<> struct adl_serializer<floormat::scenery_type> {
    static void to_json(json& j, floormat::scenery_type val);
    static void from_json(const json& j, floormat::scenery_type& val);
};

template<> struct adl_serializer<floormat::rotation> {
    static void to_json(json& j, floormat::rotation val);
    static void from_json(const json& j, floormat::rotation& val);
};

template<> struct adl_serializer<floormat::scenery_proto> {
    static void to_json(json& j, const floormat::scenery_proto& val);
    static void from_json(const json& j, floormat::scenery_proto& val);
};

template<> struct adl_serializer<floormat::serialized_scenery> {
    static void to_json(json& j, const floormat::serialized_scenery& val);
    static void from_json(const json& j, floormat::serialized_scenery& val);
};

} // namespace nlohmann