Added WidgetMerger, Polyline - colors support for each point independently, simple widgets now compute color array instead of setting global color

This commit is contained in:
Anatoly Baksheev
2014-02-15 17:02:17 +04:00
parent 261546f6f6
commit 1a5dfe421d
6 changed files with 222 additions and 85 deletions

View File

@@ -201,6 +201,7 @@ namespace cv
class CV_EXPORTS WPolyLine : public Widget3D
{
public:
WPolyLine(InputArray points, InputArray colors);
WPolyLine(InputArray points, const Color &color = Color::white());
};
@@ -362,6 +363,19 @@ namespace cv
WMesh(InputArray cloud, InputArray polygons, InputArray colors = noArray(), InputArray normals = noArray());
};
class CV_EXPORTS WWidgetMerger : public Widget3D
{
public:
WWidgetMerger();
//! Add widget to merge with optional position change
void addWidget(const Widget3D& widget, const Affine3d &pose = Affine3d::Identity());
//! Repacks internal structure to sinle widget
void finalize();
};
/////////////////////////////////////////////////////////////////////////////
/// Utility exports
@@ -391,6 +405,7 @@ namespace cv
template<> CV_EXPORTS WCloudCollection Widget::cast<WCloudCollection>();
template<> CV_EXPORTS WCloudNormals Widget::cast<WCloudNormals>();
template<> CV_EXPORTS WMesh Widget::cast<WMesh>();
template<> CV_EXPORTS WWidgetMerger Widget::cast<WWidgetMerger>();
} /* namespace viz */
} /* namespace cv */