diff --git a/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.cpp b/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.cpp index b594cff..fe9faef 100644 --- a/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.cpp +++ b/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.cpp @@ -72,7 +72,7 @@ bool AbstractionLayer_1::RemoveConstraintOnPosition(const coor constraintCoordin void AbstractionLayer_1::CreateRandomPuzzle() { std::minstd_rand simple_rand; - simple_rand.seed((unsigned int)"dumbo"); + simple_rand.seed((unsigned int)time(nullptr)); //dumbo for(int col = 0; col < m_constraintMatrix.size()-2; col++){ for(int row = 0; row < (m_constraintMatrix[col].size() - 2);) diff --git a/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.h b/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.h index d079332..7889a14 100644 --- a/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.h +++ b/Source/functions/AbstractionLayers/Layer1/AbstractionLayer_1.h @@ -24,7 +24,15 @@ #include #define DISPLAY false + +#ifdef _WIN32 #define PATH "..\\..\\..\\pieces\\%04d.jpg" +#elif defined __unix__ +#define PATH "..//..//..//pieces//%04d.jpg" +#elif defined __APPLE__ + #define PATH "..//..//..//pieces//%04d.jpg" +#endif + #define IMG_SIZE 400 #define TOP 6 #define RIGHT 4 diff --git a/Source/functions/solve/puzzleExtension.cpp b/Source/functions/solve/puzzleExtension.cpp index d3ced5c..cf38fcf 100644 --- a/Source/functions/solve/puzzleExtension.cpp +++ b/Source/functions/solve/puzzleExtension.cpp @@ -128,7 +128,6 @@ Mat Puzzle::readImage(int fileIndex, const char* inputDir){ } Mat Puzzle::resultImage( vector& log){ - int Y_size = 600; // chose this to fit your monitor! int separator = 1; int partHeight = 90;