小编Bru*_*uce的帖子

增强几何中点的最小定向边界矩形

在 boost 几何体中,有一个包络函数可以计算给定几何体的轴对齐边界框。是否有任何函数可以minimum *oriented* bounding rectangle计算 boost 中给定的(也称为定向边界框(OBB))list of points线程中有一个解决方案。但我担心的是许多矩形的快速计算。C++ 中的快速实现也受到赞赏。

c++ boost bounding-box boost-geometry

5
推荐指数
1
解决办法
1746
查看次数

通过顶点标签属性创建一个boostfiltered_graph

目前,我有一个图表,我vertices通过. 因此,每当我需要访问标签属性时,我都会在地图中找到标签并获取.labelsexternal mapmapped vertex

/// vertex properties
struct VertexData
{
    std::string label;
    int num;
};

/// edges properties
struct EdgeData
{
    std::string edge_name;
    double edge_confidence;
};

/// define the boost-graph
typedef boost::adjacency_list<boost::vecS, boost::vecS,
        boost::bidirectionalS,
        boost::property<boost::edge_index_t , size_t , VertexData>,
        boost::property<boost::edge_weight_t, double, EdgeData> > Graph;

/// define vertexMap
std::map<std::string, vertex_t> vertexMap;

///loop through the vertices to make the vertexMap here ...
vertexMap.insert(std::pair<std::string, vertex_t> (label, v));

/// find any label in the map and access the corresponding …
Run Code Online (Sandbox Code Playgroud)

boost boost-graph c++11

4
推荐指数
1
解决办法
1775
查看次数

标签 统计

boost ×2

boost-geometry ×1

boost-graph ×1

bounding-box ×1

c++ ×1

c++11 ×1