blob: b345297027bed202aeb316f28ba10909fefa11da (
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
|
#include <mbgl/style/layer_impl.hpp>
namespace mbgl {
namespace style {
std::unique_ptr<Layer> Layer::Impl::copy(const std::string& id_,
const std::string& ref_,
const std::string& source_) const {
std::unique_ptr<Layer> result = clone();
result->baseImpl->id = id_;
result->baseImpl->ref = ref_;
result->baseImpl->source = source_;
return result;
}
const std::string& Layer::Impl::bucketName() const {
return ref.empty() ? id : ref;
}
bool Layer::Impl::hasRenderPass(RenderPass pass) const {
return bool(passes & pass);
}
bool Layer::Impl::needsRendering() const {
return passes != RenderPass::None && visibility != VisibilityType::None;
}
} // namespace style
} // namespace mbgl
|