///This plot class allows you to easily plot data from a Mat or a vector. You can plot 1D or 2D plots, change the window size and the axis limits. It's simple yet very effective and usefull.
//This plot class allows you to easily plot data from a Mat or a vector. You can plot 1D or 2D plots, change the window size and the axis limits. It's simple yet very effective and usefull.
namespacecv
{
...
...
@@ -69,7 +69,7 @@ namespace cv
cv::MatplotDataY_plusZero;
constchar*plotName;
///dimensions and limits of the plot
//dimensions and limits of the plot
intplotSizeWidth;
intplotSizeHeight;
doubleplotMinX;
...
...
@@ -82,19 +82,19 @@ namespace cv
doubleplotMaxY_plusZero;
intplotLineWidth;
///colors of each plot element
//colors of each plot element
cv::ScalarplotLineColor;
cv::ScalarplotBackgroundColor;
cv::ScalarplotAxisColor;
cv::ScalarplotGridColor;
cv::ScalarplotTextColor;
///the final plot result
//the final plot result
cv::MatplotResult;
public:
///constructor accepting only Y data to be plotted
//constructor accepting only Y data to be plotted
Plot(cv::Mat_plotData)
{
//if the matrix is not Nx1 or 1xN
...
...
@@ -124,11 +124,11 @@ namespace cv
plotDataX.at<double>(i,0)=i;
}
///calling the main constructor
//calling the main constructor
plotHelper(plotDataX,plotDataY);
}
///constructor accepting X data and Y data to be plotted
//constructor accepting X data and Y data to be plotted