added cut back
This commit is contained in:
parent
be49687f31
commit
a289ccee57
@ -6,7 +6,7 @@
|
|||||||
#include "opencv2/imgproc/imgproc.hpp"
|
#include "opencv2/imgproc/imgproc.hpp"
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
#define PATH_FULL_PUZZLE "..\\..\\..\\puzzle_img\\puzzle2.jpg"
|
#define PATH_FULL_PUZZLE "..\\..\\..\\puzzle_img\\puzzle1.jpg"
|
||||||
#elif defined __unix__
|
#elif defined __unix__
|
||||||
#define PATH_FULL_PUZZLE "..//..//..//puzzle_img//puzzle1.jpg"
|
#define PATH_FULL_PUZZLE "..//..//..//puzzle_img//puzzle1.jpg"
|
||||||
#elif defined __APPLE__
|
#elif defined __APPLE__
|
||||||
|
@ -226,7 +226,7 @@ float capLogElements(vector<LogEntry>& log)
|
|||||||
newid = id;
|
newid = id;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//cut(log,newid);
|
cut(log,newid);
|
||||||
|
|
||||||
vectorsizeAfter = log.back().PieceCollector.size();
|
vectorsizeAfter = log.back().PieceCollector.size();
|
||||||
destroyed = ((double)vectorsizeBefore - (double)vectorsizeAfter) / (double)vectorsizeBefore;
|
destroyed = ((double)vectorsizeBefore - (double)vectorsizeAfter) / (double)vectorsizeBefore;
|
||||||
@ -241,7 +241,6 @@ void cut(vector<LogEntry>& log, int& cutID)
|
|||||||
{
|
{
|
||||||
while(cutID<log.back().PieceCollector.size())
|
while(cutID<log.back().PieceCollector.size())
|
||||||
{
|
{
|
||||||
cerr << "!";
|
|
||||||
log.back().PieceCollector.erase(log.back().PieceCollector.begin()+cutID);
|
log.back().PieceCollector.erase(log.back().PieceCollector.begin()+cutID);
|
||||||
}
|
}
|
||||||
cerr << endl;
|
cerr << endl;
|
||||||
|
Loading…
Reference in New Issue
Block a user