MapLibre Native Core
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
mode.hpp
Go to the documentation of this file.
1 
5 #pragma once
6 
7 #include <mbgl/util/util.hpp>
8 #include <mbgl/util/traits.hpp>
9 
10 #include <cstdint>
11 
12 namespace mbgl {
13 
14 using EnumType = uint32_t;
15 
16 enum class MapMode : EnumType {
17  Continuous,
18  Static,
19  Tile
20 };
21 
24 enum class ConstrainMode : EnumType {
25  None,
26  HeightOnly,
28 };
29 
32 enum class ViewportMode : EnumType {
33  Default,
34  FlippedY,
35 };
36 
37 enum class MapDebugOptions : EnumType {
38  NoDebug = 0,
39  TileBorders = 1 << 1,
40  ParseStatus = 1 << 2,
41  Timestamps = 1 << 3,
42  Collision = 1 << 4,
43  Overdraw = 1 << 5,
44  StencilClip = 1 << 6,
45  DepthBuffer = 1 << 7,
46 };
47 
50 }
51 
54 }
55 
58 }
59 
62 }
63 
65  return MapDebugOptions(~mbgl::underlying_type(value));
66 }
67 
68 } // namespace mbgl
Definition: actor.hpp:15
MBGL_CONSTEXPR bool operator&(MapDebugOptions lhs, MapDebugOptions rhs)
Definition: mode.hpp:56
MapDebugOptions
Definition: mode.hpp:37
MBGL_CONSTEXPR MapDebugOptions & operator|=(MapDebugOptions &lhs, MapDebugOptions rhs)
Definition: mode.hpp:52
MapMode
Definition: mode.hpp:16
@ Continuous
continually updating map
@ Static
a once-off still image of an arbitrary viewport
@ Tile
a once-off still image of a single tile
MBGL_CONSTEXPR MapDebugOptions operator|(MapDebugOptions lhs, MapDebugOptions rhs)
Definition: mode.hpp:48
uint32_t EnumType
Definition: mode.hpp:14
MBGL_CONSTEXPR MapDebugOptions operator~(MapDebugOptions value)
Definition: mode.hpp:64
ViewportMode
Definition: mode.hpp:32
MBGL_CONSTEXPR MapDebugOptions & operator&=(MapDebugOptions &lhs, MapDebugOptions rhs)
Definition: mode.hpp:60
ConstrainMode
Definition: mode.hpp:24
constexpr auto underlying_type(T t) -> typename std::underlying_type_t< T >
Definition: traits.hpp:11
#define MBGL_CONSTEXPR
Definition: util.hpp:18