Files
MapLibreParticleLab/include/llmr/text/collision.hpp
Ansis Brammanis 4b2b19ccd3 use separate trees for horizontal and curved labels
from e4186926ed38fc1dc232c70098154251a9019669
2014-05-16 16:06:24 -04:00

33 lines
982 B
C++

#ifndef LLMR_TEXT_COLLISION
#define LLMR_TEXT_COLLISION
#include <llmr/text/types.hpp>
namespace llmr {
class Collision {
public:
Collision();
~Collision();
PlacementProperty place(const PlacedGlyphs &boxes,
const CollisionAnchor &anchor,
float minPlacementScale, float maxPlacementScale,
float padding, bool horizontal, bool alwaysVisible);
float getPlacementScale(const GlyphBoxes &glyphs, float minPlacementScale,
float maxPlacementScale, float pad);
PlacementRange getPlacementRange(const GlyphBoxes &glyphs,
float placementScale, bool horizontal);
void insert(const GlyphBoxes &glyphs, const CollisionAnchor &anchor,
float placementScale, const PlacementRange &placementRange,
bool horizontal, float padding);
private:
void *cTree;
void *hTree;
};
}
#endif