diff --git a/viewer/glow-extras/viewer/canvas.hh b/viewer/glow-extras/viewer/canvas.hh index 71d71164e95963fbe09e0e4e8e8890ddee381754..a24c8e70c259c8ad4d3dbeafcc0507a1fbeed4c6 100644 --- a/viewer/glow-extras/viewer/canvas.hh +++ b/viewer/glow-extras/viewer/canvas.hh @@ -897,6 +897,16 @@ public: { return add_lines(tg::segment(p, p + dir), mat); } + template <class PosT> + line_ref add_line(pm::edge_handle edge, pm::vertex_attribute<PosT> const& pos, material const& mat = {}) + { + return add_lines(tg::segment(pos[edge.vertexA()], pos[edge.vertexB()]), mat); + } + template <class PosT> + line_ref add_line(pm::halfedge_handle edge, pm::vertex_attribute<PosT> const& pos, material const& mat = {}) + { + return add_lines(tg::segment(pos[edge.vertex_from()], pos[edge.vertex_to()]), mat); + } // lines public: