From ae518dae5877ac086787d713a0db4f89363a0e5f Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Mon, 24 Jul 2017 17:11:07 +0900 Subject: [PATCH 01/10] wow --- Kinect_Stream_APP/Kinect_Stream/App.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/Kinect_Stream_APP/Kinect_Stream/App.h b/Kinect_Stream_APP/Kinect_Stream/App.h index 522c3a4..dbeb42a 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.h +++ b/Kinect_Stream_APP/Kinect_Stream/App.h @@ -54,6 +54,4 @@ class App boost::posix_time::ptime workBeginTime; boost::posix_time::time_duration workDuration; boost::mutex mutex_lock; - - }; \ No newline at end of file From 04da8736dc4ff5bc6f43e851e53e4c3a67b02ec1 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Tue, 25 Jul 2017 11:07:39 +0900 Subject: [PATCH 02/10] Settting file update --- Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml | 10 +++++----- Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml index db70ae5..dc00b84 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml @@ -1,9 +1,9 @@ - 0 - 0 - 0 - 0 - 0 + -2.4799999999999911 + 2.389999999999993 + 0.12999999999999995 + 36.500000000000249 + 58.000000000000554 0 diff --git a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml index 425c180..d76d3ac 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml @@ -1,6 +1,6 @@ - 3.0 + 6.0 0.1 3.0 From 7021880e138190f3044e2d87f8312d9590cd4bac Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Tue, 25 Jul 2017 23:04:54 +0900 Subject: [PATCH 03/10] Update For Location "KAIBUTSU". --- Kinect_Master_App/Kinect_Master_App/App.cpp | 10 +-- .../Kinect_Master_App/App_Setting.xml | 4 +- .../Kinect_Master_App/PCLManager.cpp | 8 +- Kinect_Master_App/Kinect_Master_App/typeDef.h | 2 +- Kinect_Stream_APP/Kinect_Stream/App.cpp | 90 +++++++++++++++---- Kinect_Stream_APP/Kinect_Stream/App.h | 4 + .../Kinect_Stream/Kinect_Setting.xml | 12 +-- .../Kinect_Stream/OpticalFlow.cpp | 9 +- .../Kinect_Stream/Range_Setting.xml | 4 +- 9 files changed, 101 insertions(+), 42 deletions(-) diff --git a/Kinect_Master_App/Kinect_Master_App/App.cpp b/Kinect_Master_App/Kinect_Master_App/App.cpp index 4342884..59d6219 100644 --- a/Kinect_Master_App/Kinect_Master_App/App.cpp +++ b/Kinect_Master_App/Kinect_Master_App/App.cpp @@ -152,11 +152,11 @@ void App::run() { } - //----------ポイントクラウドの送信 - vector pointSendBuf = convertPoint(margedCloud); - cout << "Point Send Size: " << pointSendBuf.size() << endl; - sendThreads.create_thread(boost::bind(&BoostUdpServer::send, &*sendServers[0], io_service, pointSendBuf, sendIpaddress.data(), depthSendtPort, 0, 0)); - margedCloud.reset(); + ////----------ポイントクラウドの送信 + //vector pointSendBuf = convertPoint(margedCloud); + //cout << "Point Send Size: " << pointSendBuf.size() << endl; + //sendThreads.create_thread(boost::bind(&BoostUdpServer::send, &*sendServers[0], io_service, pointSendBuf, sendIpaddress.data(), depthSendtPort, 0, 0)); + //margedCloud.reset(); //----------物体の重心位置情報の送信 diff --git a/Kinect_Master_App/Kinect_Master_App/App_Setting.xml b/Kinect_Master_App/Kinect_Master_App/App_Setting.xml index b4763e7..3ef171d 100644 --- a/Kinect_Master_App/Kinect_Master_App/App_Setting.xml +++ b/Kinect_Master_App/Kinect_Master_App/App_Setting.xml @@ -1,8 +1,8 @@ - 192.168.10.100 - 34010 + 127.0.0.1 + 34100 34030 diff --git a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp index d93c1fd..7d51519 100644 --- a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp +++ b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp @@ -83,7 +83,7 @@ void PCLManager::update(std::vector::Ptr> &outputPoin //クラスタ分割 //----------------------------------- //ポイントクラウドをクラスタに分割 - voxelGridFilter(0.06f, calcPoints); + //voxelGridFilter(0.05f, calcPoints); euclideanClusterExtraction(calcPoints, eachClouds); calcPoints.reset(); @@ -96,7 +96,7 @@ void PCLManager::update(std::vector::Ptr> &outputPoin centroids.push_back(center); } - ////分割されたクラスタに色を付けて表示 + //分割されたクラスタに色を付けて表示 //pcl::PointCloud::Ptr clusteredColorCloud(new pcl::PointCloud()); //vector::Ptr> coloredClouds; //for (int i = 0; i < eachClouds.size(); i++) @@ -461,8 +461,8 @@ void PCLManager::euclideanClusterExtraction(pcl::PointCloud::Ptr clou vector cluster_indices; pcl::EuclideanClusterExtraction ec; - ec.setClusterTolerance(0.07); // 2cm - ec.setMinClusterSize(50); + ec.setClusterTolerance(0.02); // 2cm + ec.setMinClusterSize(500); ec.setMaxClusterSize(25000); ec.setSearchMethod(tree); ec.setInputCloud(cloud); diff --git a/Kinect_Master_App/Kinect_Master_App/typeDef.h b/Kinect_Master_App/Kinect_Master_App/typeDef.h index 697b586..b7d5e88 100644 --- a/Kinect_Master_App/Kinect_Master_App/typeDef.h +++ b/Kinect_Master_App/Kinect_Master_App/typeDef.h @@ -4,7 +4,7 @@ using namespace std; using namespace std::chrono; //Kinect -#define NUM_KINECT 2 +#define NUM_KINECT 1 union DataConverter { unsigned char data[4]; diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index a2679aa..1d7ad7a 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -75,7 +75,7 @@ void App::run() { //ポイントクラウド上のインデックス vector indicesOnPointCloud; //画像を生成 - Size depthImageSize(300, 120); + Size depthImageSize(200, 200); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) { @@ -286,18 +286,26 @@ void App::workEnd() { void App::loadAppSettings() { - boost::property_tree::ptree pt; - read_xml("App_Setting.xml", pt); - ipAddress = pt.get_optional("app_setting.send_to.ip_address").get(); - depthPort = pt.get_optional("app_setting.send_to.depth_port").get(); - flowPort = pt.get_optional("app_setting.send_to.flow_port").get(); + boost::property_tree::ptree ptApp; + read_xml("App_Setting.xml", ptApp); + ipAddress = ptApp.get_optional("app_setting.send_to.ip_address").get(); + depthPort = ptApp.get_optional("app_setting.send_to.depth_port").get(); + flowPort = ptApp.get_optional("app_setting.send_to.flow_port").get(); + + boost::property_tree::ptree ptKinect; + read_xml("Range_Setting.xml", ptKinect); + rangeWidth = ptKinect.get_optional("sensing_range.range_width").get(); + + float hMin = ptKinect.get_optional("sensing_range.range_height.min").get(); + float hMax = ptKinect.get_optional("sensing_range.range_height.max").get(); + rangeHeight = hMax - hMin; + + float dMin = ptKinect.get_optional("sensing_range.range_depth.min").get(); + float dMax = ptKinect.get_optional("sensing_range.range_depth.max").get(); + rangeDepth = dMax - dMin; } Mat App::createMatAndOrganizedPointCloud(pcl::PointCloud::Ptr inputCloud, Size imageSize, vector &indicesOnImage, vector &indicesOnPointCloud) { - - //まずDepthSpaceにPointCloudを変換して、 - vector depthData = convertPointCloudToDepthSpace(inputCloud); - //忘れずリセットして indicesOnImage.clear(); indicesOnPointCloud.clear(); @@ -305,29 +313,75 @@ Mat App::createMatAndOrganizedPointCloud(pcl::PointCloud::Ptr inputCl Mat outMat(imageSize.height, imageSize.width, CV_8UC1); rectangle(outMat, Rect(0, 0, imageSize.width, imageSize.height), Scalar(255, 255, 255), -1); - for (int i = 0; i < depthData.size(); i += 1) + for (int i = 0; i < inputCloud->size(); i++) { - int x = (depthData[i].X + 50) * 0.5; + int x = imageSize.width / 2 + (inputCloud->points[i].x / (rangeWidth)) * imageSize.width; if (x > imageSize.width - 1 || x < 0) { continue; } - int y = (depthData[i].Y + 50) * 0.5; + int y = imageSize.height - (inputCloud->points[i].y / (rangeHeight)) * imageSize.height; + //int y = (depthData[i].Y + 350) * 0.3; if (y > imageSize.height - 1 || y < 0) { continue; } int index = y * outMat.size().width + x; - - - outMat.data[index] = 0; + int color = (inputCloud->points[i].z / rangeDepth) * 255 - 50; + if (color >= 255) + { + color = 255; + } + if (color < 0) + { + color = 0; + } + outMat.data[index] = color; //画像上のインデックスと、ポイントクラウド上のインデックスを保存しとく indicesOnImage.push_back(index); indicesOnPointCloud.push_back(i); } + + + + + + ////まずDepthSpaceにPointCloudを変換して、 + //vector depthData = convertPointCloudToDepthSpace(inputCloud); + + ////忘れずリセットして + //indicesOnImage.clear(); + //indicesOnPointCloud.clear(); + + //Mat outMat(imageSize.height, imageSize.width, CV_8UC1); + //rectangle(outMat, Rect(0, 0, imageSize.width, imageSize.height), Scalar(255, 255, 255), -1); + + //for (int i = 0; i < depthData.size(); i += 1) + //{ + // int x = imageSize.width / 2 + (depthData[i].X / (rangeWidth * 1000)) * imageSize.width; + // //int x = (depthData[i].X + 200) * 0.3; + // if (x > imageSize.width - 1 || x < 0) + // { + // continue; + // } + // int y = imageSize.height / 2 + (depthData[i].Y / (rangeHeight * 1000)) * imageSize.height; + // //int y = (depthData[i].Y + 350) * 0.3; + // if (y > imageSize.height - 1 || y < 0) + // { + // continue; + // } + // int index = y * outMat.size().width + x; + // outMat.data[index] = 0; + // + // //画像上のインデックスと、ポイントクラウド上のインデックスを保存しとく + // indicesOnImage.push_back(index); + // indicesOnPointCloud.push_back(i); + //} + + //imshow("test", outMat); return outMat; } @@ -365,7 +419,7 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { for (int arY = -filterLevel; arY <= filterLevel; arY++) { int index = (y + arY) * inputMat.size().width + (x + arX); - if (inputMat.data[index] == 0) { + if (inputMat.data[index] < 255) { counter += 1; } @@ -373,7 +427,7 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { } } //合計計算対象ピクセル数によって、走査ピクセルがノイズってない剛体かどうかチェック - float ratio = 0.4; + float ratio = 0.2; if (counter >= calcPixelCount * ratio) { return true; diff --git a/Kinect_Stream_APP/Kinect_Stream/App.h b/Kinect_Stream_APP/Kinect_Stream/App.h index dbeb42a..e395931 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.h +++ b/Kinect_Stream_APP/Kinect_Stream/App.h @@ -41,6 +41,10 @@ class App string ipAddress; int depthPort; int flowPort; + float rangeWidth; + float rangeHeight; + float rangeDepth; + void loadAppSettings(); //Visualizer diff --git a/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml index dc00b84..327fd6b 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml @@ -1,9 +1,9 @@ - -2.4799999999999911 - 2.389999999999993 - 0.12999999999999995 - 36.500000000000249 - 58.000000000000554 - 0 + 1.7700000000000011 + 2.5699999999999892 + 0.14999999999999997 + 29.500000000000149 + -56.600000000000534 + 6.8999999999999915 diff --git a/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp b/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp index 08387d1..86188a9 100644 --- a/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp @@ -56,7 +56,7 @@ void OpticalFlow::update(UMat &inputMat) { swap(curMat, prevMat); counter += 1; - if (counter > 6) + if (counter > 33) { //for (int i = 0; i < 2; i++) //{ @@ -80,12 +80,13 @@ void OpticalFlow::draw(UMat &drawMat) { { Point2f dist = points[1][i] - points[0][i]; float distance = sqrt(dist.x * dist.x + dist.y * dist.y); - if (distance < 15 && distance > 2) + if (distance < 12 && distance > 2) { line(drawMat, points[0][i], points[1][i], Scalar(0, 0, 255)); + circle(drawMat, points[0][i], 1, Scalar(0, 0, 255)); + //circle(drawMat, points[1][i], 1, Scalar(0, 255, 0)); } - //circle(drawMat, points[0][i], 1, Scalar(255, 0, 0)); - //circle(drawMat, points[1][i], 1, Scalar(0, 255, 0)); + } } diff --git a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml index d76d3ac..ca2cddf 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml @@ -1,12 +1,12 @@ - 6.0 + 2.8 0.1 3.0 0.0 - 6.0 + 3.0 \ No newline at end of file From 52c46c8cb2c6e6eb80989bbc21f838230967b9d5 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Wed, 26 Jul 2017 13:02:33 +0900 Subject: [PATCH 04/10] update --- Kinect_Master_App/Kinect_Master_App/PCLManager.cpp | 4 ++-- Kinect_Stream_APP/Kinect_Stream/App.cpp | 2 +- Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp index 7d51519..ebc73c4 100644 --- a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp +++ b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp @@ -461,8 +461,8 @@ void PCLManager::euclideanClusterExtraction(pcl::PointCloud::Ptr clou vector cluster_indices; pcl::EuclideanClusterExtraction ec; - ec.setClusterTolerance(0.02); // 2cm - ec.setMinClusterSize(500); + ec.setClusterTolerance(0.06); // 2cm + ec.setMinClusterSize(600); ec.setMaxClusterSize(25000); ec.setSearchMethod(tree); ec.setInputCloud(cloud); diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index 1d7ad7a..7fbad1b 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -75,7 +75,7 @@ void App::run() { //ポイントクラウド上のインデックス vector indicesOnPointCloud; //画像を生成 - Size depthImageSize(200, 200); + Size depthImageSize(300, 300); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) { diff --git a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp index cc41df8..c25cdf5 100644 --- a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp @@ -22,11 +22,11 @@ void PCLManager::update(pcl::PointCloud::Ptr inputPoints) passThroughFilter(zeroPointCloud, "z", minDepth, maxDepth); //間引く - voxelGridFilter(0.02f, zeroPointCloud); + voxelGridFilter(0.01f, zeroPointCloud); //ノイズ除去 nanRemovalFilter(zeroPointCloud); - //statisticalOutlierFilter(zeroPointCloud); + statisticalOutlierFilter(zeroPointCloud); //保存 *inputPoints = *zeroPointCloud; From a7328c8adb6b1b10aeb2a3843e6c673372997359 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Wed, 26 Jul 2017 15:19:36 +0900 Subject: [PATCH 05/10] update --- Kinect_Stream_APP/Kinect_Stream/App.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index 7fbad1b..2f937a7 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -75,7 +75,7 @@ void App::run() { //ポイントクラウド上のインデックス vector indicesOnPointCloud; //画像を生成 - Size depthImageSize(300, 300); + Size depthImageSize(300, 200); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) { From b8fa5c15428fea4d843ed27812effefe02371f71 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Thu, 27 Jul 2017 12:26:00 +0900 Subject: [PATCH 06/10] update --- Kinect_Master_App/Kinect_Master_App/App.cpp | 4 +--- .../Kinect_Master_App/BoostUdpServer.cpp | 4 ++++ Kinect_Master_App/Kinect_Master_App/typeDef.h | 2 +- Kinect_Stream_APP/Kinect_Stream/App.cpp | 16 ++++++++-------- Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp | 2 +- 5 files changed, 15 insertions(+), 13 deletions(-) diff --git a/Kinect_Master_App/Kinect_Master_App/App.cpp b/Kinect_Master_App/Kinect_Master_App/App.cpp index 59d6219..aeab5ae 100644 --- a/Kinect_Master_App/Kinect_Master_App/App.cpp +++ b/Kinect_Master_App/Kinect_Master_App/App.cpp @@ -114,7 +114,7 @@ void App::run() { deathCounter[i] += 1; if (deathCounter[i] > 20) { - cout << "-----Points Clear: [" << i << "]" << endl; + //cout << "-----Points Clear: [" << i << "]" << endl; recieveServers[i]->clearPoints(); deathCounter[i] = 0; } @@ -202,8 +202,6 @@ void App::run() { viewer->updatePointCloud(showCloud); viewer->spinOnce(); - - //送信スレッドのジョイン sendThreads.join_all(); } diff --git a/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp b/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp index 75480bb..3e68c04 100644 --- a/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp +++ b/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp @@ -41,6 +41,9 @@ void BoostUdpServer::recv_handler(const boost::system::error_code & error, std:: startReceive(); } + else { + cout << error.message() << endl; + } } void BoostUdpServer::startServer(boost::shared_ptr io_service, unsigned short port) @@ -61,6 +64,7 @@ void BoostUdpServer::startReceive() startReceive(); } else { + _sock.async_receive_from(boost::asio::buffer(_receivedBuf), _remoteEndpoint, boost::bind( &BoostUdpServer::recv_handler, diff --git a/Kinect_Master_App/Kinect_Master_App/typeDef.h b/Kinect_Master_App/Kinect_Master_App/typeDef.h index b7d5e88..812bf76 100644 --- a/Kinect_Master_App/Kinect_Master_App/typeDef.h +++ b/Kinect_Master_App/Kinect_Master_App/typeDef.h @@ -4,7 +4,7 @@ using namespace std; using namespace std::chrono; //Kinect -#define NUM_KINECT 1 +#define NUM_KINECT 4 union DataConverter { unsigned char data[4]; diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index 2f937a7..20e56c1 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -75,14 +75,14 @@ void App::run() { //ポイントクラウド上のインデックス vector indicesOnPointCloud; //画像を生成 - Size depthImageSize(300, 200); + Size depthImageSize(420, 280); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); - for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) - { - if (!midianFilter(i, depthMat, 1)) { - depthMat.data[i] = 255; - } - } + //for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) + //{ + // if (!midianFilter(i, depthMat, 1)) { + // depthMat.data[i] = 255; + // } + //} //Flowの計算 UMat flowMat; depthMat.copyTo(flowMat); @@ -427,7 +427,7 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { } } //合計計算対象ピクセル数によって、走査ピクセルがノイズってない剛体かどうかチェック - float ratio = 0.2; + float ratio = 0.3; if (counter >= calcPixelCount * ratio) { return true; diff --git a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp index c25cdf5..841b919 100644 --- a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp @@ -22,7 +22,7 @@ void PCLManager::update(pcl::PointCloud::Ptr inputPoints) passThroughFilter(zeroPointCloud, "z", minDepth, maxDepth); //間引く - voxelGridFilter(0.01f, zeroPointCloud); + voxelGridFilter(0.015f, zeroPointCloud); //ノイズ除去 nanRemovalFilter(zeroPointCloud); From 60413c95505e9e556a718279d66a44bafe047bd7 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Thu, 27 Jul 2017 19:35:00 +0900 Subject: [PATCH 07/10] update --- Kinect_Stream_APP/Kinect_Stream/App.cpp | 14 +++++++------- Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index 20e56c1..364d148 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -77,12 +77,12 @@ void App::run() { //画像を生成 Size depthImageSize(420, 280); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); - //for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) - //{ - // if (!midianFilter(i, depthMat, 1)) { - // depthMat.data[i] = 255; - // } - //} + for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) + { + if (!midianFilter(i, depthMat, 1)) { + depthMat.data[i] = 255; + } + } //Flowの計算 UMat flowMat; depthMat.copyTo(flowMat); @@ -427,7 +427,7 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { } } //合計計算対象ピクセル数によって、走査ピクセルがノイズってない剛体かどうかチェック - float ratio = 0.3; + float ratio = 0.2; if (counter >= calcPixelCount * ratio) { return true; diff --git a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp index 841b919..f16ec93 100644 --- a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp @@ -26,7 +26,7 @@ void PCLManager::update(pcl::PointCloud::Ptr inputPoints) //ノイズ除去 nanRemovalFilter(zeroPointCloud); - statisticalOutlierFilter(zeroPointCloud); + //statisticalOutlierFilter(zeroPointCloud); //保存 *inputPoints = *zeroPointCloud; From feae61e911904e885ec41c743cd27f0dbe4fbc91 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Fri, 28 Jul 2017 19:15:54 +0900 Subject: [PATCH 08/10] =?UTF-8?q?=E3=82=AF=E3=83=A9=E3=82=A4=E3=82=A2?= =?UTF-8?q?=E3=83=B3=E3=83=88=E3=81=B8=E3=81=AE=E3=83=87=E3=83=A2=E7=B5=82?= =?UTF-8?q?=E4=BA=86@=E3=82=AB=E3=82=A4=E3=83=96=E3=83=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Kinect_Master_App/PCLManager.cpp | 2 +- Kinect_Stream_APP/Kinect_Stream/App.cpp | 75 ++++++++++++++++--- Kinect_Stream_APP/Kinect_Stream/App.h | 3 +- .../Kinect_Stream/OpticalFlow.cpp | 4 +- Kinect_Stream_APP/Kinect_Stream/OpticalFlow.h | 4 +- .../Kinect_Stream/PCLManager.cpp | 4 +- .../Kinect_Stream/Range_Setting.xml | 6 +- 7 files changed, 74 insertions(+), 24 deletions(-) diff --git a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp index ebc73c4..cd6c6a4 100644 --- a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp +++ b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp @@ -461,7 +461,7 @@ void PCLManager::euclideanClusterExtraction(pcl::PointCloud::Ptr clou vector cluster_indices; pcl::EuclideanClusterExtraction ec; - ec.setClusterTolerance(0.06); // 2cm + ec.setClusterTolerance(0.08); // 2cm ec.setMinClusterSize(600); ec.setMaxClusterSize(25000); ec.setSearchMethod(tree); diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index 364d148..7d31e4f 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -22,7 +22,7 @@ HRESULT App::init() { { running = true; } - + return hr; } @@ -33,7 +33,7 @@ void App::run() { //Thread Group //----------------------------------- boost::thread_group threads; - + while (running) { workBegin(); @@ -57,7 +57,7 @@ void App::run() { { continue; } - + //送信 pcl::PointCloud::Ptr sendPCLPtr(new pcl::PointCloud()); *sendPCLPtr = *kinectRawCloud; @@ -75,14 +75,15 @@ void App::run() { //ポイントクラウド上のインデックス vector indicesOnPointCloud; //画像を生成 - Size depthImageSize(420, 280); + Size depthImageSize(300, 200); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); - for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) - { - if (!midianFilter(i, depthMat, 1)) { - depthMat.data[i] = 255; - } - } + Mat culcFlowMat; + //depthMat.copyTo(culcFlowMat); + //for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) + //{ + // culcFlowMat.data[i] = midianFilter(i, depthMat, 1); + //} + //imshow("MFilter", culcFlowMat); //Flowの計算 UMat flowMat; depthMat.copyTo(flowMat); @@ -240,7 +241,7 @@ vector App::createSendBuffer(pcl::PointCloud::Ptr inpu buf.push_back(converter.data[j]); } } - + return buf; } @@ -385,7 +386,7 @@ Mat App::createMatAndOrganizedPointCloud(pcl::PointCloud::Ptr inputCl return outMat; } -bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { +bool App::midianNoiseFilter(int bufIndex, Mat &inputMat, int filterLevel) { if (filterLevel <= 0) { return true; @@ -414,6 +415,7 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { return false; } + vector pixels(0); for (int arX = -filterLevel; arX <= filterLevel; arX++) { for (int arY = -filterLevel; arY <= filterLevel; arY++) @@ -424,8 +426,15 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { } calcPixelCount += 1; + + pixels.push_back(inputMat.data[index]); } } + sort(pixels.begin(), pixels.end()); + int numPixel = pixels.size(); + int midianIndex = numPixel / 2; + + //合計計算対象ピクセル数によって、走査ピクセルがノイズってない剛体かどうかチェック float ratio = 0.2; if (counter >= calcPixelCount * ratio) @@ -433,4 +442,46 @@ bool App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { return true; } return false; +} + + +int App::midianFilter(int bufIndex, Mat &inputMat, int filterLevel) { + if (filterLevel <= 0) + { + return 255; + } + + if (inputMat.data[bufIndex] < 0) + { + return 0; + } + + //まずx,y座標に直し + int x = bufIndex % inputMat.size().width; + int y = bufIndex / inputMat.size().width; + + //その前に無効な値はスルー + if ( + x <= filterLevel || + x >= inputMat.size().width - filterLevel || + y <= filterLevel || + y >= inputMat.size().height - filterLevel + ) { + return 255; + } + + vector pixels(0); + for (int arX = -filterLevel; arX <= filterLevel; arX++) + { + for (int arY = -filterLevel; arY <= filterLevel; arY++) + { + int index = (y + arY) * inputMat.size().width + (x + arX); + pixels.push_back(inputMat.data[index]); + } + } + sort(pixels.begin(), pixels.end()); + int numPixel = pixels.size(); + int midianIndex = numPixel / 2; + + return inputMat.data[midianIndex]; } \ No newline at end of file diff --git a/Kinect_Stream_APP/Kinect_Stream/App.h b/Kinect_Stream_APP/Kinect_Stream/App.h index e395931..83489de 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.h +++ b/Kinect_Stream_APP/Kinect_Stream/App.h @@ -52,7 +52,8 @@ class App //OCV Mat createMatAndOrganizedPointCloud(pcl::PointCloud::Ptr inputCloud, Size imageSize, vector &indicesOnImage, vector &indicesOnPointCloud); - bool midianFilter(int bufIndex, Mat &inputMat, int filterLevel); + bool midianNoiseFilter(int bufIndex, Mat &inputMat, int filterLevel); + int midianFilter(int bufIndex, Mat &inputMat, int filterLevel); //Util boost::posix_time::ptime workBeginTime; diff --git a/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp b/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp index 86188a9..f4ec504 100644 --- a/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.cpp @@ -56,7 +56,7 @@ void OpticalFlow::update(UMat &inputMat) { swap(curMat, prevMat); counter += 1; - if (counter > 33) + if (counter > 20) { //for (int i = 0; i < 2; i++) //{ @@ -86,8 +86,6 @@ void OpticalFlow::draw(UMat &drawMat) { circle(drawMat, points[0][i], 1, Scalar(0, 0, 255)); //circle(drawMat, points[1][i], 1, Scalar(0, 255, 0)); } - - } } imshow("Kinect", drawMat); diff --git a/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.h b/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.h index f1e65a7..705733d 100644 --- a/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.h +++ b/Kinect_Stream_APP/Kinect_Stream/OpticalFlow.h @@ -18,9 +18,9 @@ class OpticalFlow int maxFeatureCount = 600; //計算対象の現在のフレーム - Mat curMat; + UMat curMat; //フロー算出する際の一つ手前のフレーム - Mat prevMat; + UMat prevMat; //算出結果を入れるやつ vector points[2]; diff --git a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp index f16ec93..b0e1bdc 100644 --- a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp @@ -25,8 +25,8 @@ void PCLManager::update(pcl::PointCloud::Ptr inputPoints) voxelGridFilter(0.015f, zeroPointCloud); //ノイズ除去 - nanRemovalFilter(zeroPointCloud); - //statisticalOutlierFilter(zeroPointCloud); + //nanRemovalFilter(zeroPointCloud); + statisticalOutlierFilter(zeroPointCloud); //保存 *inputPoints = *zeroPointCloud; diff --git a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml index ca2cddf..2e5e0b4 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml @@ -2,11 +2,11 @@ 2.8 - 0.1 - 3.0 + 0.2 + 2.0 - 0.0 + 0.1 3.0 \ No newline at end of file From ad74bedc98e8cf8c33d3c86f247c625065cafba9 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Fri, 25 Jan 2019 17:46:30 +0900 Subject: [PATCH 09/10] [update] --- Kinect_Master_App/Kinect_Master_App/stdafx.h | 20 +++--- Kinect_Stream_APP/Kinect_Stream/App.cpp | 61 ++----------------- .../Kinect_Stream/Kinect_Setting.xml | 12 ++-- .../Kinect_Stream/Kinect_Stream.vcxproj | 4 +- .../Kinect_Stream/PCLManager.cpp | 8 +-- .../Kinect_Stream/Range_Setting.xml | 8 +-- Kinect_Stream_APP/Kinect_Stream/stdafx.h | 21 ++++--- 7 files changed, 43 insertions(+), 91 deletions(-) diff --git a/Kinect_Master_App/Kinect_Master_App/stdafx.h b/Kinect_Master_App/Kinect_Master_App/stdafx.h index b58a059..ec2413c 100644 --- a/Kinect_Master_App/Kinect_Master_App/stdafx.h +++ b/Kinect_Master_App/Kinect_Master_App/stdafx.h @@ -7,16 +7,16 @@ #include "targetver.h" //C++ -#define _USE_MATH_DEFINES // for C++ -#include -#include -#include -#include -#include -#include -#include -#include -#include +//#define _USE_MATH_DEFINES // for C++ +//#include +//#include +//#include +//#include +//#include +//#include +//#include +//#include +//#include #include #include diff --git a/Kinect_Stream_APP/Kinect_Stream/App.cpp b/Kinect_Stream_APP/Kinect_Stream/App.cpp index 7d31e4f..7b32fa6 100644 --- a/Kinect_Stream_APP/Kinect_Stream/App.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/App.cpp @@ -53,10 +53,6 @@ void App::run() { pcl::PointCloud::Ptr kinectRawCloud = convertDepthToPointCloud(depthBuf); pclManager.update(kinectRawCloud); - if (kinectRawCloud->size() < 100) - { - continue; - } //送信 pcl::PointCloud::Ptr sendPCLPtr(new pcl::PointCloud()); @@ -75,25 +71,15 @@ void App::run() { //ポイントクラウド上のインデックス vector indicesOnPointCloud; //画像を生成 - Size depthImageSize(300, 200); + Size depthImageSize(200, 200); Mat depthMat = createMatAndOrganizedPointCloud(kinectRawCloud, depthImageSize, indicesOnImage, indicesOnPointCloud); - Mat culcFlowMat; - //depthMat.copyTo(culcFlowMat); - //for (int i = 0; i < depthMat.size().width * depthMat.size().height; i++) - //{ - // culcFlowMat.data[i] = midianFilter(i, depthMat, 1); - //} - //imshow("MFilter", culcFlowMat); + //Flowの計算 UMat flowMat; depthMat.copyTo(flowMat); - //---------- Flow計算(フレームレート早すぎると落ちるので適宜スリープ) - //if (workDuration.total_milliseconds() < 17) - //{ - // Sleep(17 - workDuration.total_milliseconds()); - //} + //---------- Flow計算 flow.update(flowMat); UMat drawMat; cvtColor(flowMat, drawMat, CV_GRAY2BGR); @@ -118,8 +104,8 @@ void App::run() { { Point2f fp = flowEndPoints[i]; Point2f f = forces[i]; + //そもそも無効なやつ - int targetIndex = depthImageSize.width * fp.y + fp.x; if (fp.x < 0 || fp.y < 0) { continue; @@ -133,6 +119,7 @@ void App::run() { } //このインデックス付近で、一番有効そうな値を探す + int targetIndex = depthImageSize.width * fp.y + fp.x; for (int j = 0; j < indicesOnImage.size(); j++) { int indexOnImage = indicesOnImage[j]; @@ -345,44 +332,6 @@ Mat App::createMatAndOrganizedPointCloud(pcl::PointCloud::Ptr inputCl indicesOnPointCloud.push_back(i); } - - - - - - ////まずDepthSpaceにPointCloudを変換して、 - //vector depthData = convertPointCloudToDepthSpace(inputCloud); - - ////忘れずリセットして - //indicesOnImage.clear(); - //indicesOnPointCloud.clear(); - - //Mat outMat(imageSize.height, imageSize.width, CV_8UC1); - //rectangle(outMat, Rect(0, 0, imageSize.width, imageSize.height), Scalar(255, 255, 255), -1); - - //for (int i = 0; i < depthData.size(); i += 1) - //{ - // int x = imageSize.width / 2 + (depthData[i].X / (rangeWidth * 1000)) * imageSize.width; - // //int x = (depthData[i].X + 200) * 0.3; - // if (x > imageSize.width - 1 || x < 0) - // { - // continue; - // } - // int y = imageSize.height / 2 + (depthData[i].Y / (rangeHeight * 1000)) * imageSize.height; - // //int y = (depthData[i].Y + 350) * 0.3; - // if (y > imageSize.height - 1 || y < 0) - // { - // continue; - // } - // int index = y * outMat.size().width + x; - // outMat.data[index] = 0; - // - // //画像上のインデックスと、ポイントクラウド上のインデックスを保存しとく - // indicesOnImage.push_back(index); - // indicesOnPointCloud.push_back(i); - //} - - //imshow("test", outMat); return outMat; } diff --git a/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml index 327fd6b..57f240a 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Kinect_Setting.xml @@ -1,9 +1,9 @@ - 1.7700000000000011 - 2.5699999999999892 - 0.14999999999999997 - 29.500000000000149 - -56.600000000000534 - 6.8999999999999915 + 0 + 1.0 + 0 + 0 + 0 + 0 diff --git a/Kinect_Stream_APP/Kinect_Stream/Kinect_Stream.vcxproj b/Kinect_Stream_APP/Kinect_Stream/Kinect_Stream.vcxproj index fa72b1f..53f6e30 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Kinect_Stream.vcxproj +++ b/Kinect_Stream_APP/Kinect_Stream/Kinect_Stream.vcxproj @@ -139,7 +139,7 @@ true NDEBUG;_CONSOLE;NOMINMAX;_001;%(PreprocessorDefinitions) true - $(PCL_ROOT)\include\pcl-1.8;$(PCL_ROOT)\3rdParty\Boost\include\boost-1_61;$(PCL_ROOT)\3rdParty\Eigen\eigen3;$(PCL_ROOT)\3rdParty\FLANN\include;$(PCL_ROOT)\3rdParty\Qhull\include\libqhullcpp;$(PCL_ROOT)\3rdParty\VTK\include\vtk-7.0;$(OPENNI2_INCLUDE64);$(KINECTSDK20_DIR)\inc;$(OPENCV_INCLUDE);%(AdditionalIncludeDirectories) + $(PCL_ROOT)\include\pcl-1.8;$(PCL_ROOT)\3rdParty\Boost\include\boost-1_64;$(PCL_ROOT)\3rdParty\Eigen\eigen3;$(PCL_ROOT)\3rdParty\FLANN\include;$(PCL_ROOT)\3rdParty\Qhull\include\libqhullcpp;$(PCL_ROOT)\3rdParty\VTK\include\vtk-8.0;$(OPENNI2_INCLUDE64);$(KINECTSDK20_DIR)\inc;$(OPENCV_INCLUDE);%(AdditionalIncludeDirectories) stdafx.h; 4996; @@ -149,7 +149,7 @@ true true $(KINECTSDK20_DIR)\Lib\x64;$(PCL_ROOT)\lib;$(PCL_ROOT)\3rdParty\Boost\lib;$(PCL_ROOT)\3rdParty\FLANN\lib;$(PCL_ROOT)\3rdParty\Qhull\lib;$(PCL_ROOT)\3rdParty\VTK\lib;$(OPENNI2_LIB64);$(OPENCV_LIB);%(AdditionalLibraryDirectories) - Kinect20.lib;winmm.lib;opencv_world320.lib;ws2_32.lib;pcl_common_release.lib;pcl_features_release.lib;pcl_filters_release.lib;pcl_io_release.lib;pcl_io_ply_release.lib;pcl_kdtree_release.lib;pcl_keypoints_release.lib;pcl_ml_release.lib;pcl_octree_release.lib;pcl_outofcore_release.lib;pcl_people_release.lib;pcl_recognition_release.lib;pcl_registration_release.lib;pcl_sample_consensus_release.lib;pcl_search_release.lib;pcl_segmentation_release.lib;pcl_stereo_release.lib;pcl_surface_release.lib;pcl_tracking_release.lib;pcl_visualization_release.lib;flann.lib;flann_s.lib;flann_cpp_s.lib;qhull.lib;qhull_p.lib;qhull_r.lib;qhullcpp.lib;qhullstatic.lib;qhullstatic_r.lib;OpenNI2.lib;vtkalglib-7.0.lib;vtkChartsCore-7.0.lib;vtkCommonColor-7.0.lib;vtkCommonComputationalGeometry-7.0.lib;vtkCommonCore-7.0.lib;vtkCommonDataModel-7.0.lib;vtkCommonExecutionModel-7.0.lib;vtkCommonMath-7.0.lib;vtkCommonMisc-7.0.lib;vtkCommonSystem-7.0.lib;vtkCommonTransforms-7.0.lib;vtkDICOMParser-7.0.lib;vtkDomainsChemistry-7.0.lib;vtkexoIIc-7.0.lib;vtkexpat-7.0.lib;vtkFiltersAMR-7.0.lib;vtkFiltersCore-7.0.lib;vtkFiltersExtraction-7.0.lib;vtkFiltersFlowPaths-7.0.lib;vtkFiltersGeneral-7.0.lib;vtkFiltersGeneric-7.0.lib;vtkFiltersGeometry-7.0.lib;vtkFiltersHybrid-7.0.lib;vtkFiltersHyperTree-7.0.lib;vtkFiltersImaging-7.0.lib;vtkFiltersModeling-7.0.lib;vtkFiltersParallel-7.0.lib;vtkFiltersParallelImaging-7.0.lib;vtkFiltersProgrammable-7.0.lib;vtkFiltersSelection-7.0.lib;vtkFiltersSMP-7.0.lib;vtkFiltersSources-7.0.lib;vtkFiltersStatistics-7.0.lib;vtkFiltersTexture-7.0.lib;vtkFiltersVerdict-7.0.lib;vtkfreetype-7.0.lib;vtkGeovisCore-7.0.lib;vtkhdf5_hl-7.0.lib;vtkhdf5-7.0.lib;vtkImagingColor-7.0.lib;vtkImagingCore-7.0.lib;vtkImagingFourier-7.0.lib;vtkImagingGeneral-7.0.lib;vtkImagingHybrid-7.0.lib;vtkImagingMath-7.0.lib;vtkImagingMorphological-7.0.lib;vtkImagingSources-7.0.lib;vtkImagingStatistics-7.0.lib;vtkImagingStencil-7.0.lib;vtkInfovisCore-7.0.lib;vtkInfovisLayout-7.0.lib;vtkInteractionImage-7.0.lib;vtkInteractionStyle-7.0.lib;vtkInteractionWidgets-7.0.lib;vtkIOAMR-7.0.lib;vtkIOCore-7.0.lib;vtkIOEnSight-7.0.lib;vtkIOExodus-7.0.lib;vtkIOExport-7.0.lib;vtkIOGeometry-7.0.lib;vtkIOImage-7.0.lib;vtkIOImport-7.0.lib;vtkIOInfovis-7.0.lib;vtkIOLegacy-7.0.lib;vtkIOLSDyna-7.0.lib;vtkIOMINC-7.0.lib;vtkIOMovie-7.0.lib;vtkIONetCDF-7.0.lib;vtkIOParallel-7.0.lib;vtkIOParallelXML-7.0.lib;vtkIOPLY-7.0.lib;vtkIOSQL-7.0.lib;vtkIOVideo-7.0.lib;vtkIOXML-7.0.lib;vtkIOXMLParser-7.0.lib;vtkjpeg-7.0.lib;vtkjsoncpp-7.0.lib;vtklibxml2-7.0.lib;vtkmetaio-7.0.lib;vtkNetCDF_cxx-7.0.lib;vtkNetCDF-7.0.lib;vtkoggtheora-7.0.lib;vtkParallelCore-7.0.lib;vtkpng-7.0.lib;vtkproj4-7.0.lib;vtkRenderingAnnotation-7.0.lib;vtkRenderingContext2D-7.0.lib;vtkRenderingCore-7.0.lib;vtkRenderingFreeType-7.0.lib;vtkRenderingImage-7.0.lib;vtkRenderingLabel-7.0.lib;vtkRenderingLOD-7.0.lib;vtkRenderingVolume-7.0.lib;vtksqlite-7.0.lib;vtksys-7.0.lib;vtktiff-7.0.lib;vtkverdict-7.0.lib;vtkViewsContext2D-7.0.lib;vtkViewsCore-7.0.lib;vtkViewsInfovis-7.0.lib;vtkzlib-7.0.lib;opengl32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) + Kinect20.lib;winmm.lib;opencv_world343.lib;ws2_32.lib;pcl_common_release.lib;pcl_features_release.lib;pcl_filters_release.lib;pcl_io_release.lib;pcl_io_ply_release.lib;pcl_kdtree_release.lib;pcl_keypoints_release.lib;pcl_ml_release.lib;pcl_octree_release.lib;pcl_outofcore_release.lib;pcl_people_release.lib;pcl_recognition_release.lib;pcl_registration_release.lib;pcl_sample_consensus_release.lib;pcl_search_release.lib;pcl_segmentation_release.lib;pcl_stereo_release.lib;pcl_surface_release.lib;pcl_tracking_release.lib;pcl_visualization_release.lib;flann.lib;flann_s.lib;flann_cpp_s.lib;qhull.lib;qhull_p.lib;qhull_r.lib;qhullcpp.lib;qhullstatic.lib;qhullstatic_r.lib;vtkalglib-8.0.lib;vtkChartsCore-8.0.lib;vtkCommonColor-8.0.lib;vtkCommonComputationalGeometry-8.0.lib;vtkCommonCore-8.0.lib;vtkCommonDataModel-8.0.lib;vtkCommonExecutionModel-8.0.lib;vtkCommonMath-8.0.lib;vtkCommonMisc-8.0.lib;vtkCommonSystem-8.0.lib;vtkCommonTransforms-8.0.lib;vtkDICOMParser-8.0.lib;vtkDomainsChemistry-8.0.lib;vtkexoIIc-8.0.lib;vtkexpat-8.0.lib;vtkFiltersAMR-8.0.lib;vtkFiltersCore-8.0.lib;vtkFiltersExtraction-8.0.lib;vtkFiltersFlowPaths-8.0.lib;vtkFiltersGeneral-8.0.lib;vtkFiltersGeneric-8.0.lib;vtkFiltersGeometry-8.0.lib;vtkFiltersHybrid-8.0.lib;vtkFiltersHyperTree-8.0.lib;vtkFiltersImaging-8.0.lib;vtkFiltersModeling-8.0.lib;vtkFiltersParallel-8.0.lib;vtkFiltersParallelImaging-8.0.lib;vtkFiltersProgrammable-8.0.lib;vtkFiltersSelection-8.0.lib;vtkFiltersSMP-8.0.lib;vtkFiltersSources-8.0.lib;vtkFiltersStatistics-8.0.lib;vtkFiltersTexture-8.0.lib;vtkFiltersVerdict-8.0.lib;vtkfreetype-8.0.lib;vtkGeovisCore-8.0.lib;vtkhdf5_hl-8.0.lib;vtkhdf5-8.0.lib;vtkImagingColor-8.0.lib;vtkImagingCore-8.0.lib;vtkImagingFourier-8.0.lib;vtkImagingGeneral-8.0.lib;vtkImagingHybrid-8.0.lib;vtkImagingMath-8.0.lib;vtkImagingMorphological-8.0.lib;vtkImagingSources-8.0.lib;vtkImagingStatistics-8.0.lib;vtkImagingStencil-8.0.lib;vtkInfovisCore-8.0.lib;vtkInfovisLayout-8.0.lib;vtkInteractionImage-8.0.lib;vtkInteractionStyle-8.0.lib;vtkInteractionWidgets-8.0.lib;vtkIOAMR-8.0.lib;vtkIOCore-8.0.lib;vtkIOEnSight-8.0.lib;vtkIOExodus-8.0.lib;vtkIOExport-8.0.lib;vtkIOGeometry-8.0.lib;vtkIOImage-8.0.lib;vtkIOImport-8.0.lib;vtkIOInfovis-8.0.lib;vtkIOLegacy-8.0.lib;vtkIOLSDyna-8.0.lib;vtkIOMINC-8.0.lib;vtkIOMovie-8.0.lib;vtkIONetCDF-8.0.lib;vtkIOParallel-8.0.lib;vtkIOParallelXML-8.0.lib;vtkIOPLY-8.0.lib;vtkIOSQL-8.0.lib;vtkIOVideo-8.0.lib;vtkIOXML-8.0.lib;vtkIOXMLParser-8.0.lib;vtkjpeg-8.0.lib;vtkjsoncpp-8.0.lib;vtklibxml2-8.0.lib;vtkmetaio-8.0.lib;vtkNetCDF-8.0.lib;vtkoggtheora-8.0.lib;vtkParallelCore-8.0.lib;vtkpng-8.0.lib;vtkproj4-8.0.lib;vtkRenderingAnnotation-8.0.lib;vtkRenderingContext2D-8.0.lib;vtkRenderingCore-8.0.lib;vtkRenderingFreeType-8.0.lib;vtkRenderingImage-8.0.lib;vtkRenderingLabel-8.0.lib;vtkRenderingLOD-8.0.lib;vtkRenderingVolume-8.0.lib;vtksqlite-8.0.lib;vtksys-8.0.lib;vtktiff-8.0.lib;vtkverdict-8.0.lib;vtkViewsContext2D-8.0.lib;vtkViewsCore-8.0.lib;vtkViewsInfovis-8.0.lib;vtkzlib-8.0.lib;opengl32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) diff --git a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp index b0e1bdc..f568347 100644 --- a/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp +++ b/Kinect_Stream_APP/Kinect_Stream/PCLManager.cpp @@ -21,11 +21,11 @@ void PCLManager::update(pcl::PointCloud::Ptr inputPoints) passThroughFilter(zeroPointCloud, "y", minHeight, maxHeight); passThroughFilter(zeroPointCloud, "z", minDepth, maxDepth); - //間引く - voxelGridFilter(0.015f, zeroPointCloud); + ////間引く + //voxelGridFilter(0.015f, zeroPointCloud); - //ノイズ除去 - //nanRemovalFilter(zeroPointCloud); + ////ノイズ除去 + ////nanRemovalFilter(zeroPointCloud); statisticalOutlierFilter(zeroPointCloud); //保存 diff --git a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml index 2e5e0b4..bc9df0d 100644 --- a/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml +++ b/Kinect_Stream_APP/Kinect_Stream/Range_Setting.xml @@ -1,12 +1,12 @@ - 2.8 + 1.0 - 0.2 - 2.0 + 0 + 2 0.1 - 3.0 + 3 \ No newline at end of file diff --git a/Kinect_Stream_APP/Kinect_Stream/stdafx.h b/Kinect_Stream_APP/Kinect_Stream/stdafx.h index cf3dcc0..3f171ca 100644 --- a/Kinect_Stream_APP/Kinect_Stream/stdafx.h +++ b/Kinect_Stream_APP/Kinect_Stream/stdafx.h @@ -6,6 +6,13 @@ #pragma once #include "targetver.h" +//Boost +#include +#include +#include +#include +#include +#include //C++ #define _USE_MATH_DEFINES // for C++ @@ -26,16 +33,9 @@ #include "opencv2\core\ocl.hpp" #include "opencv2\objdetect.hpp" -//Kinect -#include -//Boost -#include -#include -#include -#include -#include -#include + + //PCL #include @@ -52,6 +52,9 @@ #include #include +//Kinect +#include + //Common #include "typeDef.h" From 98afe9b7d5955a44d0616b4b58a4df52a5028d60 Mon Sep 17 00:00:00 2001 From: Yohei Kajiwara Date: Fri, 25 Jan 2019 17:48:15 +0900 Subject: [PATCH 10/10] [delete] --- Kinect_Master_App/Kinect_Master_App.sln | 28 - Kinect_Master_App/Kinect_Master_App/App.cpp | 330 ----- Kinect_Master_App/Kinect_Master_App/App.h | 39 - .../Kinect_Master_App/App_Setting.xml | 8 - .../Kinect_Master_App/BoostUdpServer.cpp | 166 --- .../Kinect_Master_App/BoostUdpServer.h | 61 - .../Kinect_Master_App/Kinect_Master_App.cpp | 20 - .../Kinect_Master_App.vcxproj | 190 --- .../Kinect_Master_App.vcxproj.filters | 68 -- .../Kinect_Master_App/PCLManager.cpp | 706 ----------- .../Kinect_Master_App/PCLManager.h | 78 -- .../Kinect_Master_App/ReadMe.txt | 30 - .../Kinect_Master_App/Singleton.h | 34 - .../Kinect_Master_App/XMLFile.xml | 1 - .../Kinect_Master_App/kinect_master.ico | Bin 67646 -> 0 bytes .../Kinect_Master_App/stdafx.cpp | 8 - Kinect_Master_App/Kinect_Master_App/stdafx.h | 52 - .../Kinect_Master_App/targetver.h | 8 - Kinect_Master_App/Kinect_Master_App/typeDef.h | 17 - Kinect_Master_App/Setup/Setup.vdproj | 1061 ----------------- 20 files changed, 2905 deletions(-) delete mode 100644 Kinect_Master_App/Kinect_Master_App.sln delete mode 100644 Kinect_Master_App/Kinect_Master_App/App.cpp delete mode 100644 Kinect_Master_App/Kinect_Master_App/App.h delete mode 100644 Kinect_Master_App/Kinect_Master_App/App_Setting.xml delete mode 100644 Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp delete mode 100644 Kinect_Master_App/Kinect_Master_App/BoostUdpServer.h delete mode 100644 Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.cpp delete mode 100644 Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj delete mode 100644 Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj.filters delete mode 100644 Kinect_Master_App/Kinect_Master_App/PCLManager.cpp delete mode 100644 Kinect_Master_App/Kinect_Master_App/PCLManager.h delete mode 100644 Kinect_Master_App/Kinect_Master_App/ReadMe.txt delete mode 100644 Kinect_Master_App/Kinect_Master_App/Singleton.h delete mode 100644 Kinect_Master_App/Kinect_Master_App/XMLFile.xml delete mode 100644 Kinect_Master_App/Kinect_Master_App/kinect_master.ico delete mode 100644 Kinect_Master_App/Kinect_Master_App/stdafx.cpp delete mode 100644 Kinect_Master_App/Kinect_Master_App/stdafx.h delete mode 100644 Kinect_Master_App/Kinect_Master_App/targetver.h delete mode 100644 Kinect_Master_App/Kinect_Master_App/typeDef.h delete mode 100644 Kinect_Master_App/Setup/Setup.vdproj diff --git a/Kinect_Master_App/Kinect_Master_App.sln b/Kinect_Master_App/Kinect_Master_App.sln deleted file mode 100644 index cdeef02..0000000 --- a/Kinect_Master_App/Kinect_Master_App.sln +++ /dev/null @@ -1,28 +0,0 @@ -サソ -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 15 -VisualStudioVersion = 15.0.26430.6 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Kinect_Master_App", "Kinect_Master_App\Kinect_Master_App.vcxproj", "{37A909D9-C814-47B0-9A85-92227F2C8B59}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|x64 = Debug|x64 - Debug|x86 = Debug|x86 - Release|x64 = Release|x64 - Release|x86 = Release|x86 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Debug|x64.ActiveCfg = Debug|x64 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Debug|x64.Build.0 = Debug|x64 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Debug|x86.ActiveCfg = Debug|Win32 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Debug|x86.Build.0 = Debug|Win32 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Release|x64.ActiveCfg = Release|x64 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Release|x64.Build.0 = Release|x64 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Release|x86.ActiveCfg = Release|Win32 - {37A909D9-C814-47B0-9A85-92227F2C8B59}.Release|x86.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/Kinect_Master_App/Kinect_Master_App/App.cpp b/Kinect_Master_App/Kinect_Master_App/App.cpp deleted file mode 100644 index aeab5ae..0000000 --- a/Kinect_Master_App/Kinect_Master_App/App.cpp +++ /dev/null @@ -1,330 +0,0 @@ -#include "stdafx.h" -#include "PCLManager.h" -#include "BoostUdpServer.h" -#include "App.h" - - -HRESULT App::init() { - HRESULT hr = S_OK; - _running = false; - - if (SUCCEEDED(hr) && loadNeworkSettings()) - { - _running = true; - - } - return hr; -} - -bool App::loadNeworkSettings() -{ - boost::property_tree::ptree pt; - read_xml("App_Setting.xml", pt); - sendIpaddress = pt.get_optional("app_setting.send_to.ip_address").get(); - depthSendtPort = pt.get_optional("app_setting.send_to.depth_port").get(); - positionSendPort = pt.get_optional("app_setting.send_to.position_port").get(); - - if (sendIpaddress != "" && depthSendtPort != 0 && positionSendPort != 0) - { - return true; - } - return false; -} - -void App::run() { - //----------------------------------- - //Viewer - //----------------------------------- - pcl::PointCloud::Ptr c(new pcl::PointCloud()); - viewer.reset(new pcl::visualization::PCLVisualizer("Kinect Master")); - viewer->addPointCloud(c); - viewer->initCameraParameters(); - viewer->setCameraPosition(3.0, 3.0, -3.0, 0, 0, 0); //3D - - - //----------------------------------- - //UDP Server - //----------------------------------- - //受信 - boost::shared_ptr io_service(new boost::asio::io_service); - //ポート別にスレッドを分けて受信 - //ポートごとにサーバー立てて - vector> recieveServers; - for (int i = 0; i < NUM_KINECT; i++) - { - boost::shared_ptr svr(new BoostUdpServer(io_service)); - recieveServers.push_back(svr); - deathCounter[i] = 0; - lastDataSize[i] = 0; - } - - //スレッドで分けて受信してく - //受信 - boost::thread_group receiveThreads; - for (int i = 0; i < recieveServers.size(); i++) - { - receiveThreads.create_thread(boost::bind(&BoostUdpServer::startServer, &*recieveServers[i], io_service, 34011 + i)); - } - - - //----------------------------------- - //PCL - //----------------------------------- - PCLManager pclManager; - vector::Ptr> pointClouds; - - for (int i = 0; i < NUM_KINECT; i++) - { - pcl::PointCloud::Ptr pointCloud(new pcl::PointCloud()); - pointClouds.push_back(pointCloud); - } - - //----------------------------------- - //Mail Loop - //----------------------------------- - while (_running) - { - workBegin(); - - for (int i = 0; i < NUM_KINECT; i++) - { - if (recieveServers[i]->isEnablePointCloud) - { - //kinect毎のクラウド - vector points = recieveServers[i]->getPointCloud(); - copy(points.begin(), points.end(), back_inserter(pointClouds[i]->points)); - cout << "PointCloud[" << i << "]---Size: " << pointClouds[i]->points.size() * 6 << endl; - } - else { - pointClouds[i]->clear(); - } - } - - //有効なデータがあるかどうかチェック - int counter = 0; - for (int i = 0; i < NUM_KINECT; i++) - { - int curDataSize = pointClouds[i]->points.size(); - if (curDataSize > 100 && curDataSize != lastDataSize[i]) { - counter += 1; - lastDataSize[i] = pointClouds[i]->points.size(); - } - else - { - deathCounter[i] += 1; - if (deathCounter[i] > 20) - { - //cout << "-----Points Clear: [" << i << "]" << endl; - recieveServers[i]->clearPoints(); - deathCounter[i] = 0; - } - } - } - - //有効なデータが一つでもあれば処理開始 - if (counter > 0) - { - //----------------------------------- - //解析 - //----------------------------------- - pclManager.update(pointClouds); - - //----------------------------------- - //データ取得 - //----------------------------------- - //マージしたポイントクラウド - pcl::PointCloud::Ptr margedCloud(new pcl::PointCloud()); - margedCloud = pclManager.getMargedPoints(); - //重心の座標 - vector centroids = pclManager.getCentroids(); - - - //----------------------------------- - //データ送信 - //----------------------------------- - //送信スレッドなど立てる - boost::thread_group sendThreads; - vector> sendServers; - for (int i = 0; i < 2; i++) - { - boost::shared_ptr svr(new BoostUdpServer(io_service)); - sendServers.push_back(svr); - } - - - ////----------ポイントクラウドの送信 - //vector pointSendBuf = convertPoint(margedCloud); - //cout << "Point Send Size: " << pointSendBuf.size() << endl; - //sendThreads.create_thread(boost::bind(&BoostUdpServer::send, &*sendServers[0], io_service, pointSendBuf, sendIpaddress.data(), depthSendtPort, 0, 0)); - //margedCloud.reset(); - - - //----------物体の重心位置情報の送信 - vector objPointSendBuf(0); - for (int i = 0; i < centroids.size(); i++) - { - vector buf = convertPoint(centroids[i]); - copy(buf.begin(), buf.end(), back_inserter(objPointSendBuf)); - } - cout << "Object Position Send Size: " << objPointSendBuf.size() << endl; - sendThreads.create_thread(boost::bind(&BoostUdpServer::send, &*sendServers[1], io_service, objPointSendBuf, sendIpaddress.data(), positionSendPort, 0, 0)); - - - - //Visualize - pcl::PointCloud::Ptr showCloud(new pcl::PointCloud()); - vector::Ptr> coloredClouds; - for (int i = 0; i < pointClouds.size(); i++) - { - pcl::PointCloud::Ptr cc(new pcl::PointCloud()); - pcl::copyPointCloud(*pointClouds[i], *cc); - coloredClouds.push_back(cc); - if (i % 2 == 0) - { - for (int j = 0; j < coloredClouds[i]->points.size(); j++) - { - coloredClouds[i]->points[j].r = 255; - coloredClouds[i]->points[j].g = 0; - coloredClouds[i]->points[j].b = 0; - } - } else { - for (int j = 0; j < coloredClouds[i]->points.size(); j++) - { - coloredClouds[i]->points[j].r = 0; - coloredClouds[i]->points[j].g = 255; - coloredClouds[i]->points[j].b = 0; - } - } - - *showCloud += *coloredClouds[i]; - coloredClouds[i]->clear(); - } - viewer->updatePointCloud(showCloud); - viewer->spinOnce(); - - //送信スレッドのジョイン - sendThreads.join_all(); - } - - - for (int i = 0; i < pointClouds.size(); i++) - { - pointClouds[i]->clear(); - } - - Sleep(1); - workEnd(); - } - - //終了処理 - io_service->stop(); - receiveThreads.join_all(); -} - -std::vector App::convertPolygonData(pcl::PolygonMesh & mesh) -{ - //デバッグ用 - std::vector sendPoints; - - //送信用 - std::vector sendBuf(0); - int sendSize = mesh.polygons.size(); - - for (int polygon = 0; polygon < sendSize; polygon++) - { - //座標毎に処理 - for (int vertex = 0; vertex < mesh.polygons[polygon].vertices.size(); vertex++) - { - //座標のインデックスを取得 - int index = mesh.polygons[polygon].vertices[vertex]; - //.dataから該当のデータを取ってくる - //.dataの中は、法線とかの情報も入ってて、その構造は.cloud.fieldsに格納されてる - //PointXYZRGBの場合、.dataが48個で一つの座標の情報に該当 - //Xやらの座標はfloatなので、全部送ると重たいからshortとかに変換してから送る - - //まずインデックスの頭の12バイトが座標系で、4バイト毎にX, Y, Zとなってるので - //4つ区切りで処理して変換用のunion型変数に格納してく - DataConverter dataConverter; - for (int vertexOffset = 0; vertexOffset < 12; vertexOffset += 4) - { - for (int dataSize = 0; dataSize < 4; dataSize++) - { - dataConverter.data[dataSize] = mesh.cloud.data[index * mesh.cloud.point_step + vertexOffset + dataSize]; - } - float fVal = dataConverter.fValue; - sendPoints.push_back(fVal); - short sVal = fVal * 1000; - sendBuf.push_back(sVal); - sendBuf.push_back(sVal >> 8); - } - } - } - - return sendBuf; -} - -vector App::convertPoint(pcl::PointCloud::Ptr cloud) { - - //送信用 - std::vector sendBuf(0); - int sendSize = cloud->points.size(); - - if (cloud->points.size() == 0) - { - return sendBuf; - } - - //デバッグ用 - std::vector sendPoints; - - for (int i = 0; i < cloud->points.size(); i++) - { - PointType p = cloud->points[i]; - //X - short x = p.x * 1000; - sendBuf.push_back(x); - sendBuf.push_back(x >> 8); - sendPoints.push_back(x); - //Y - short y = p.y * 1000; - sendBuf.push_back(y); - sendBuf.push_back(y >> 8); - sendPoints.push_back(y); - //Z - short z = p.z * 1000; - sendBuf.push_back(z); - sendBuf.push_back(z >> 8); - sendPoints.push_back(z); - } - return sendBuf; -} - -vector App::convertPoint(Eigen::Vector4f p) { - //送信用 - std::vector sendBuf(0); - - //X - short x = p.x() * 1000; - sendBuf.push_back(x); - sendBuf.push_back(x >> 8); - //Y - short y = p.y() * 1000; - sendBuf.push_back(y); - sendBuf.push_back(y >> 8); - //Z - short z = p.z() * 1000; - sendBuf.push_back(z); - sendBuf.push_back(z >> 8); - - return sendBuf; -} - -void App::workBegin() { - workBeginTime = boost::posix_time::microsec_clock::local_time(); -} - -void App::workEnd() { - boost::posix_time::ptime curTime = boost::posix_time::microsec_clock::local_time(); - workDuration = curTime - workBeginTime; - cout << "Work Duration: " << workDuration.total_milliseconds() << endl; -} \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/App.h b/Kinect_Master_App/Kinect_Master_App/App.h deleted file mode 100644 index 5be6277..0000000 --- a/Kinect_Master_App/Kinect_Master_App/App.h +++ /dev/null @@ -1,39 +0,0 @@ -#pragma once -class App -{ -public: - App(){} - ~App(){} - - HRESULT init(); - - void run(); - -private: - //UDP SEND - std::vector convertPolygonData(pcl::PolygonMesh &mesh); - vector convertPoint(pcl::PointCloud::Ptr cloud); - vector convertPoint(Eigen::Vector4f p); - - //Network Settings - bool loadNeworkSettings(); - int depthSendtPort = 0; - int positionSendPort = 0; - string sendIpaddress = ""; - - //Visualizer - boost::shared_ptr viewer; - - //Util - void workBegin(); - void workEnd(); - - //Event - bool _running; - int lastDataSize[NUM_KINECT]; - int deathCounter[NUM_KINECT]; - - //FPS測定 - boost::posix_time::ptime workBeginTime; - boost::posix_time::time_duration workDuration; -}; \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/App_Setting.xml b/Kinect_Master_App/Kinect_Master_App/App_Setting.xml deleted file mode 100644 index 3ef171d..0000000 --- a/Kinect_Master_App/Kinect_Master_App/App_Setting.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - 127.0.0.1 - 34100 - 34030 - - diff --git a/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp b/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp deleted file mode 100644 index 3e68c04..0000000 --- a/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.cpp +++ /dev/null @@ -1,166 +0,0 @@ -#include "stdafx.h" -#include "BoostUdpServer.h" - - -void BoostUdpServer::send_handler(const boost::system::error_code & error, std::size_t len) -{ - //std::cout << "--------------------------------Send: " << len << std::endl; -} - -void BoostUdpServer::recv_handler(const boost::system::error_code & error, std::size_t len) -{ - if (!error || error == boost::asio::error::message_size) - { - //最初の4バイトはデータ総数が入ってるので、それをチェック - DataConverter converter; - for (int i = 0; i < 4; i++) - { - converter.data[i] = _receivedBuf[i]; - } - int curDataSize = converter.iValue; - - //頭の4バイトの内容が変わってたら - if (curDataSize != lastReceivedDataSize) - { - //カタマリを保存してる配列に、ためたデータをいれて - pointCloudDataArray.push_back(pointCloudData); - - //ためてたやつはこの区切りポイントでいったんクリア - pointCloudData.clear(); - - //データ取得OKのフラグをたてて - isEnablePointCloud = true; - - //クラス変数として保存してあった前回のヘッダーの内容を更新し - lastReceivedDataSize = curDataSize; - } - - //受信したデータをためる何らかの処理(上記の更新のあとにこれをやらないと意味ないです) - //ここではポイント座標系に変換してから保存する関数をたたいてます - convertToPoints(&_receivedBuf[4], len - 4, pointCloudData); - - startReceive(); - } - else { - cout << error.message() << endl; - } -} - -void BoostUdpServer::startServer(boost::shared_ptr io_service, unsigned short port) -{ - _port = port; - _sock.open(boost::asio::ip::udp::v4()); - _sock.bind(boost::asio::ip::udp::endpoint(boost::asio::ip::udp::v4(), port)); - isEnablePointCloud = false; - startReceive(); - io_service->run(); -} - -void BoostUdpServer::startReceive() -{ - if (!_sock.is_open()) - { - _sock.open(boost::asio::ip::udp::v4()); - startReceive(); - } - else { - - _sock.async_receive_from(boost::asio::buffer(_receivedBuf), _remoteEndpoint, - boost::bind( - &BoostUdpServer::recv_handler, - this, - boost::asio::placeholders::error, - boost::asio::placeholders::bytes_transferred - )); - } -} - - -void BoostUdpServer::send(boost::shared_ptr io_service, std::vector &sendBuf, const char *ipaddr, unsigned short port, short imageWidth, short imageHeight) { - - std::vector> pendingBufGroup; - //データを分割 - int maxDatasize = 54000; - int dataSize = sendBuf.size(); - int numDataGroup = dataSize / maxDatasize + 1; - - //std::cout << ">>>>>>>>>>Send Start: " << numDataGroup << std::endl; - //std::cout << "--------------------------------Count: " << sendCounter << std::endl; - for (int i = 0; i < numDataGroup; i++) - { - std::vector b; - - //頭の4バイトに、データ総数をいれとく - DataConverter converter; - converter.iValue = sendBuf.size(); - for (int i = 0; i < 4; i++) - { - b.push_back(converter.data[i]); - } - - if (imageWidth > 0 && imageHeight > 0) - { - //その後ろに2バイトずつ、ポイントクラウドの縦横幅を入れておく - converter.iValue = 0; - converter.sValue[0] = imageWidth; - converter.sValue[1] = imageHeight; - for (int i = 0; i < 4; i++) - { - b.push_back(converter.data[i]); - } - } - - //中身をぶちこむ - if (dataSize < maxDatasize) - { - std::copy(sendBuf.begin() + maxDatasize * i, sendBuf.end(), std::back_inserter(b)); - } - else { - std::copy(sendBuf.begin() + maxDatasize * i, sendBuf.begin() + maxDatasize * (i + 1), std::back_inserter(b)); - dataSize -= maxDatasize; - } - pendingBufGroup.push_back(b); - } - - //送信 - if (!_sock.is_open()) - { - _sock.open(boost::asio::ip::udp::v4()); - _sock.bind(boost::asio::ip::udp::endpoint()); - } - cout << "Sending Gourp: " << numDataGroup << endl; - for (int i = 0; i < pendingBufGroup.size(); i++) - { - //std::cout << "Send Size: " << pendingBufGroup[i].size() << std::endl; - io_service->post(boost::bind(&BoostUdpServer::sendAsync, this, pendingBufGroup[i], ipaddr, port)); - Sleep(1); - } -} - -void BoostUdpServer::sendAsync(std::vector &sendBuf, const char *ipaddr, unsigned short port) { - _sock.async_send_to(boost::asio::buffer(sendBuf), - boost::asio::ip::udp::endpoint(boost::asio::ip::address::from_string(ipaddr), port), - boost::bind( - &BoostUdpServer::send_handler, - this, - boost::asio::placeholders::error, - boost::asio::placeholders::bytes_transferred - )); -} - -void BoostUdpServer::sendSync(std::vector &sendBuf, const char *ipaddr, unsigned short port) { - size_t sendSize = _sock.send_to(boost::asio::buffer(sendBuf), - boost::asio::ip::udp::endpoint(boost::asio::ip::address::from_string(ipaddr), port)); - //std::cout << "Send Size: " << sendSize << std::endl; -} - -void BoostUdpServer::convertToPoints(unsigned char *buf, size_t len, std::vector &outputPoints) { - for (int i = 0; i < len; i += 6) - { - PointType point; - point.x = (short)(buf[i] + buf[i + 1] * 256) * 0.001; - point.y = (short)(buf[i + 2] + buf[i + 3] * 256) * 0.001; - point.z = (short)(buf[i + 4] + buf[i + 5] * 256) * 0.001; - outputPoints.push_back(point); - } -} \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.h b/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.h deleted file mode 100644 index bfef933..0000000 --- a/Kinect_Master_App/Kinect_Master_App/BoostUdpServer.h +++ /dev/null @@ -1,61 +0,0 @@ -#pragma once -using namespace boost::asio::ip; -class BoostUdpServer{ -public: - BoostUdpServer(boost::shared_ptr io_service) : _sock(*io_service) {} - ~BoostUdpServer() { - _sock.close(); - std::cout << "<< Thread End >>" << std::endl; - } - - //----------------------------------- - //受信 - //----------------------------------- - //受信開始 - void startServer(boost::shared_ptr io_service, unsigned short port); - - //----------------------------------- - //Point Cloud Data - //----------------------------------- - //個別のデータ - std::vector pointCloudData; - //グルーピングしたやつ - std::vector> pointCloudDataArray; - - //受信したポイントクラウドの引き渡し - inline std::vector getPointCloud() { - std::vector returnPoints = pointCloudDataArray.back(); - pointCloudDataArray.clear(); - pointCloudDataArray.push_back(returnPoints); - //isEnablePointCloud = false; - return returnPoints; - } - - //ポイントクラウドのクリア - inline void clearPoints() { - pointCloudDataArray.clear(); - isEnablePointCloud = false; - } - bool isEnablePointCloud; - - //----------------------------------- - //送信 - //----------------------------------- - void send(boost::shared_ptr io_service, std::vector &sendBuf, const char *ipaddr, unsigned short port, short imageWidth, short imageHeight); - - -private: - void startReceive(); - void send_handler(const boost::system::error_code& error, std::size_t len); - void recv_handler(const boost::system::error_code & error, std::size_t len); - void sendAsync(std::vector &sendBuf, const char * ipaddr, unsigned short port); - void sendSync(std::vector& sendBuf, const char * ipaddr, unsigned short port); - void convertToPoints(unsigned char *buf, size_t len, std::vector &outputPoints); - - udp::socket _sock; - udp::endpoint _remoteEndpoint; - boost::array _receivedBuf; - size_t _port; - int lastReceivedDataSize; -}; - diff --git a/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.cpp b/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.cpp deleted file mode 100644 index 59b8a17..0000000 --- a/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.cpp +++ /dev/null @@ -1,20 +0,0 @@ -// Kinect_Master_App.cpp : コンソール アプリケーションのエントリ ポイントを定義します。 -// - -#include "stdafx.h" -#include "App.h" - -int main() -{ - try { - App app; - app.init(); - app.run(); - } - catch (exception &ex) - { - cout << ex.what() << endl; - return -1; - } - return 0; -} \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj b/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj deleted file mode 100644 index fbf9bf5..0000000 --- a/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj +++ /dev/null @@ -1,190 +0,0 @@ -サソ - - - - Debug - Win32 - - - Release - Win32 - - - Debug - x64 - - - Release - x64 - - - - {37A909D9-C814-47B0-9A85-92227F2C8B59} - Win32Proj - Kinect_Master_App - 8.1 - - - - Application - true - v141 - Unicode - - - Application - false - v141 - true - Unicode - - - Application - true - v141 - Unicode - - - Application - false - v141 - true - Unicode - - - - - - - - - - - - - - - - - - - - - true - - - true - - - false - - - false - - - - Use - Level3 - Disabled - WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions) - true - - - Console - true - - - - - Use - Level3 - Disabled - _DEBUG;_CONSOLE;NOMINMAX;%(PreprocessorDefinitions) - true - $(PCL_ROOT)\include\pcl-1.8;$(PCL_ROOT)\3rdParty\Boost\include\boost-1_61;$(PCL_ROOT)\3rdParty\Eigen\eigen3;$(PCL_ROOT)\3rdParty\FLANN\include;$(PCL_ROOT)\3rdParty\Qhull\include\libqhullcpp;$(PCL_ROOT)\3rdParty\VTK\include\vtk-7.0;$(OPENNI2_INCLUDE64) - 4996; - stdafx.h; - - - Console - true - $(PCL_ROOT)\lib;$(PCL_ROOT)\3rdParty\Boost\lib;$(PCL_ROOT)\3rdParty\FLANN\lib;$(PCL_ROOT)\3rdParty\Qhull\lib;$(PCL_ROOT)\3rdParty\VTK\lib;%(AdditionalLibraryDirectories) - pcl_common_debug.lib;pcl_features_debug.lib;pcl_filters_debug.lib;pcl_io_debug.lib;pcl_io_ply_debug.lib;pcl_kdtree_debug.lib;pcl_keypoints_debug.lib;pcl_ml_debug.lib;pcl_octree_debug.lib;pcl_outofcore_debug.lib;pcl_people_debug.lib;pcl_recognition_debug.lib;pcl_registration_debug.lib;pcl_sample_consensus_debug.lib;pcl_search_debug.lib;pcl_segmentation_debug.lib;pcl_stereo_debug.lib;pcl_surface_debug.lib;pcl_tracking_debug.lib;pcl_visualization_debug.lib;flann-gd.lib;flann_s-gd.lib;flann_cpp_s-gd.lib;qhull_d.lib;qhull_p_d.lib;qhull_r_d.lib;qhullcpp_d.lib;qhullstatic_d.lib;qhullstatic_r_d.lib;vtkalglib-7.0-gd.lib;vtkChartsCore-7.0-gd.lib;vtkCommonColor-7.0-gd.lib;vtkCommonComputationalGeometry-7.0-gd.lib;vtkCommonCore-7.0-gd.lib;vtkCommonDataModel-7.0-gd.lib;vtkCommonExecutionModel-7.0-gd.lib;vtkCommonMath-7.0-gd.lib;vtkCommonMisc-7.0-gd.lib;vtkCommonSystem-7.0-gd.lib;vtkCommonTransforms-7.0-gd.lib;vtkDICOMParser-7.0-gd.lib;vtkDomainsChemistry-7.0-gd.lib;vtkexoIIc-7.0-gd.lib;vtkexpat-7.0-gd.lib;vtkFiltersAMR-7.0-gd.lib;vtkFiltersCore-7.0-gd.lib;vtkFiltersExtraction-7.0-gd.lib;vtkFiltersFlowPaths-7.0-gd.lib;vtkFiltersGeneral-7.0-gd.lib;vtkFiltersGeneric-7.0-gd.lib;vtkFiltersGeometry-7.0-gd.lib;vtkFiltersHybrid-7.0-gd.lib;vtkFiltersHyperTree-7.0-gd.lib;vtkFiltersImaging-7.0-gd.lib;vtkFiltersModeling-7.0-gd.lib;vtkFiltersParallel-7.0-gd.lib;vtkFiltersParallelImaging-7.0-gd.lib;vtkFiltersProgrammable-7.0-gd.lib;vtkFiltersSelection-7.0-gd.lib;vtkFiltersSMP-7.0-gd.lib;vtkFiltersSources-7.0-gd.lib;vtkFiltersStatistics-7.0-gd.lib;vtkFiltersTexture-7.0-gd.lib;vtkFiltersVerdict-7.0-gd.lib;vtkfreetype-7.0-gd.lib;vtkGeovisCore-7.0-gd.lib;vtkgl2ps-7.0-gd.lib;vtkhdf5_hl-7.0-gd.lib;vtkhdf5-7.0-gd.lib;vtkImagingColor-7.0-gd.lib;vtkImagingCore-7.0-gd.lib;vtkImagingFourier-7.0-gd.lib;vtkImagingGeneral-7.0-gd.lib;vtkImagingHybrid-7.0-gd.lib;vtkImagingMath-7.0-gd.lib;vtkImagingMorphological-7.0-gd.lib;vtkImagingSources-7.0-gd.lib;vtkImagingStatistics-7.0-gd.lib;vtkImagingStencil-7.0-gd.lib;vtkInfovisCore-7.0-gd.lib;vtkInfovisLayout-7.0-gd.lib;vtkInteractionImage-7.0-gd.lib;vtkInteractionStyle-7.0-gd.lib;vtkInteractionWidgets-7.0-gd.lib;vtkIOAMR-7.0-gd.lib;vtkIOCore-7.0-gd.lib;vtkIOEnSight-7.0-gd.lib;vtkIOExodus-7.0-gd.lib;vtkIOExport-7.0-gd.lib;vtkIOGeometry-7.0-gd.lib;vtkIOImage-7.0-gd.lib;vtkIOImport-7.0-gd.lib;vtkIOInfovis-7.0-gd.lib;vtkIOLegacy-7.0-gd.lib;vtkIOLSDyna-7.0-gd.lib;vtkIOMINC-7.0-gd.lib;vtkIOMovie-7.0-gd.lib;vtkIONetCDF-7.0-gd.lib;vtkIOParallel-7.0-gd.lib;vtkIOParallelXML-7.0-gd.lib;vtkIOPLY-7.0-gd.lib;vtkIOSQL-7.0-gd.lib;vtkIOVideo-7.0-gd.lib;vtkIOXML-7.0-gd.lib;vtkIOXMLParser-7.0-gd.lib;vtkjpeg-7.0-gd.lib;vtkjsoncpp-7.0-gd.lib;vtklibxml2-7.0-gd.lib;vtkmetaio-7.0-gd.lib;vtkNetCDF_cxx-7.0-gd.lib;vtkNetCDF-7.0-gd.lib;vtkoggtheora-7.0-gd.lib;vtkParallelCore-7.0-gd.lib;vtkpng-7.0-gd.lib;vtkproj4-7.0-gd.lib;vtkRenderingAnnotation-7.0-gd.lib;vtkRenderingContext2D-7.0-gd.lib;vtkRenderingContextOpenGL-7.0-gd.lib;vtkRenderingCore-7.0-gd.lib;vtkRenderingFreeType-7.0-gd.lib;vtkRenderingGL2PS-7.0-gd.lib;vtkRenderingImage-7.0-gd.lib;vtkRenderingLabel-7.0-gd.lib;vtkRenderingLIC-7.0-gd.lib;vtkRenderingLOD-7.0-gd.lib;vtkRenderingOpenGL-7.0-gd.lib;vtkRenderingVolume-7.0-gd.lib;vtkRenderingVolumeOpenGL-7.0-gd.lib;vtksqlite-7.0-gd.lib;vtksys-7.0-gd.lib;vtktiff-7.0-gd.lib;vtkverdict-7.0-gd.lib;vtkViewsContext2D-7.0-gd.lib;vtkViewsCore-7.0-gd.lib;vtkViewsInfovis-7.0-gd.lib;vtkzlib-7.0-gd.lib;opengl32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) - - - - - Level3 - Use - MaxSpeed - true - true - WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) - true - - - Console - true - true - true - - - - - Level3 - Use - MaxSpeed - true - true - NDEBUG;_CONSOLE;NOMINMAX;%(PreprocessorDefinitions) - true - $(PCL_ROOT)\include\pcl-1.8;$(PCL_ROOT)\3rdParty\Boost\include\boost-1_61;$(PCL_ROOT)\3rdParty\Eigen\eigen3;$(PCL_ROOT)\3rdParty\FLANN\include;$(PCL_ROOT)\3rdParty\Qhull\include\libqhullcpp;$(PCL_ROOT)\3rdParty\VTK\include\vtk-7.0;$(OPENNI2_INCLUDE64) - 4996; - stdafx.h; - /Zm660 %(AdditionalOptions) - - - Console - true - true - true - $(PCL_ROOT)\lib;$(PCL_ROOT)\3rdParty\Boost\lib;$(PCL_ROOT)\3rdParty\FLANN\lib;$(PCL_ROOT)\3rdParty\Qhull\lib;$(PCL_ROOT)\3rdParty\VTK\lib;$(OPENNI2_LIB64);%(AdditionalLibraryDirectories) - pcl_common_release.lib;pcl_features_release.lib;pcl_filters_release.lib;pcl_io_release.lib;pcl_io_ply_release.lib;pcl_kdtree_release.lib;pcl_keypoints_release.lib;pcl_ml_release.lib;pcl_octree_release.lib;pcl_outofcore_release.lib;pcl_people_release.lib;pcl_recognition_release.lib;pcl_registration_release.lib;pcl_sample_consensus_release.lib;pcl_search_release.lib;pcl_segmentation_release.lib;pcl_stereo_release.lib;pcl_surface_release.lib;pcl_tracking_release.lib;pcl_visualization_release.lib;flann.lib;flann_s.lib;flann_cpp_s.lib;qhull.lib;qhull_p.lib;qhull_r.lib;qhullcpp.lib;qhullstatic.lib;qhullstatic_r.lib;OpenNI2.lib;vtkalglib-7.0.lib;vtkChartsCore-7.0.lib;vtkCommonColor-7.0.lib;vtkCommonComputationalGeometry-7.0.lib;vtkCommonCore-7.0.lib;vtkCommonDataModel-7.0.lib;vtkCommonExecutionModel-7.0.lib;vtkCommonMath-7.0.lib;vtkCommonMisc-7.0.lib;vtkCommonSystem-7.0.lib;vtkCommonTransforms-7.0.lib;vtkDICOMParser-7.0.lib;vtkDomainsChemistry-7.0.lib;vtkexoIIc-7.0.lib;vtkexpat-7.0.lib;vtkFiltersAMR-7.0.lib;vtkFiltersCore-7.0.lib;vtkFiltersExtraction-7.0.lib;vtkFiltersFlowPaths-7.0.lib;vtkFiltersGeneral-7.0.lib;vtkFiltersGeneric-7.0.lib;vtkFiltersGeometry-7.0.lib;vtkFiltersHybrid-7.0.lib;vtkFiltersHyperTree-7.0.lib;vtkFiltersImaging-7.0.lib;vtkFiltersModeling-7.0.lib;vtkFiltersParallel-7.0.lib;vtkFiltersParallelImaging-7.0.lib;vtkFiltersProgrammable-7.0.lib;vtkFiltersSelection-7.0.lib;vtkFiltersSMP-7.0.lib;vtkFiltersSources-7.0.lib;vtkFiltersStatistics-7.0.lib;vtkFiltersTexture-7.0.lib;vtkFiltersVerdict-7.0.lib;vtkfreetype-7.0.lib;vtkGeovisCore-7.0.lib;vtkhdf5_hl-7.0.lib;vtkhdf5-7.0.lib;vtkImagingColor-7.0.lib;vtkImagingCore-7.0.lib;vtkImagingFourier-7.0.lib;vtkImagingGeneral-7.0.lib;vtkImagingHybrid-7.0.lib;vtkImagingMath-7.0.lib;vtkImagingMorphological-7.0.lib;vtkImagingSources-7.0.lib;vtkImagingStatistics-7.0.lib;vtkImagingStencil-7.0.lib;vtkInfovisCore-7.0.lib;vtkInfovisLayout-7.0.lib;vtkInteractionImage-7.0.lib;vtkInteractionStyle-7.0.lib;vtkInteractionWidgets-7.0.lib;vtkIOAMR-7.0.lib;vtkIOCore-7.0.lib;vtkIOEnSight-7.0.lib;vtkIOExodus-7.0.lib;vtkIOExport-7.0.lib;vtkIOGeometry-7.0.lib;vtkIOImage-7.0.lib;vtkIOImport-7.0.lib;vtkIOInfovis-7.0.lib;vtkIOLegacy-7.0.lib;vtkIOLSDyna-7.0.lib;vtkIOMINC-7.0.lib;vtkIOMovie-7.0.lib;vtkIONetCDF-7.0.lib;vtkIOParallel-7.0.lib;vtkIOParallelXML-7.0.lib;vtkIOPLY-7.0.lib;vtkIOSQL-7.0.lib;vtkIOVideo-7.0.lib;vtkIOXML-7.0.lib;vtkIOXMLParser-7.0.lib;vtkjpeg-7.0.lib;vtkjsoncpp-7.0.lib;vtklibxml2-7.0.lib;vtkmetaio-7.0.lib;vtkNetCDF_cxx-7.0.lib;vtkNetCDF-7.0.lib;vtkoggtheora-7.0.lib;vtkParallelCore-7.0.lib;vtkpng-7.0.lib;vtkproj4-7.0.lib;vtkRenderingAnnotation-7.0.lib;vtkRenderingContext2D-7.0.lib;vtkRenderingCore-7.0.lib;vtkRenderingFreeType-7.0.lib;vtkRenderingImage-7.0.lib;vtkRenderingLabel-7.0.lib;vtkRenderingLOD-7.0.lib;vtkRenderingVolume-7.0.lib;vtksqlite-7.0.lib;vtksys-7.0.lib;vtktiff-7.0.lib;vtkverdict-7.0.lib;vtkViewsContext2D-7.0.lib;vtkViewsCore-7.0.lib;vtkViewsInfovis-7.0.lib;vtkzlib-7.0.lib;opengl32.lib;kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(AdditionalDependencies) - - - - - - - - - - - - - - - - - - - - - Create - Create - Create - Create - - - - - Designer - - - - - - - - - \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj.filters b/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj.filters deleted file mode 100644 index c1674c7..0000000 --- a/Kinect_Master_App/Kinect_Master_App/Kinect_Master_App.vcxproj.filters +++ /dev/null @@ -1,68 +0,0 @@ -サソ - - - - {4FC737F1-C7A5-4376-A066-2A32D752A2FF} - cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx - - - {93995380-89BD-4b04-88EB-625FBE52EBFB} - h;hh;hpp;hxx;hm;inl;inc;xsd - - - {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} - rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms - - - - - - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - 繝倥ャ繝繝シ 繝輔ぃ繧、繝ォ - - - - - 繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ - - - 繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ - - - 繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ - - - 繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ - - - 繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ - - - - - - - - 繝ェ繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ - - - \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp b/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp deleted file mode 100644 index cd6c6a4..0000000 --- a/Kinect_Master_App/Kinect_Master_App/PCLManager.cpp +++ /dev/null @@ -1,706 +0,0 @@ -#include "stdafx.h" -#include "BoostUdpServer.h" -#include "PCLManager.h" - - - -//pcl::visualization::CloudViewer clusterViewer("Master: Clusters"); -//pcl::visualization::CloudViewer cHullViewer("Master: Concave Hull"); - -PCLManager::PCLManager() -{ - pcl::PointCloud::Ptr p(new pcl::PointCloud()); - margedCloud = p; -} - -void PCLManager::update(std::vector::Ptr> &outputPoints) -{ - ////----------------------------------- - ////各キネクトデータの位置合わせ - ////----------------------------------- - //int mainKinectID = 0; - ////Kinect 001 - //ICPTransformMatrix[0] << - // 1, 0, 0, 0, - // 0, 1, 0, 0, - // 0, 0, 1, 0, - // 0, 0, 0, 1; - ////Kinect 002 - //ICPTransformMatrix[1] << - // 1, 0, 0, 0, - // 0, 1, 0, 0, - // 0, 0, 1, 0, - // 0, 0, 0, 1; - - - //boost::thread_group registrationThreads; - //vector::Ptr> registrationClouds; - ////for (int i = 0; i < outputPoints.size(); i++) - ////{ - //// statisticalOutlierFilter(outputPoints[i]); - ////} - - //for (int i = 0; i < outputPoints.size(); i++) - //{ - // pcl::PointCloud::Ptr p(new pcl::PointCloud()); - // registrationClouds.push_back(p); - // registrationThreads.create_thread(boost::bind(&PCLManager::registrationAll, this, outputPoints[i], registrationClouds[i], ICPTransformMatrix[i])); - - // ////位置が合わなくなって来たら、これで再度レジストレーションする - // //transformationVector[i] = iterativeClosestPoint(outputPoints[mainKinectID], outputPoints[i]); - // //cout << transformationVector[i] << endl; - // //pcl::PointCloud::Ptr p(new pcl::PointCloud()); - // //registrationClouds.push_back(p); - // //registrationThreads.create_thread(boost::bind(&PCLManager::registrationAll, this, outputPoints[i], registrationClouds[i], transformationVector[i])); - //} - //registrationThreads.join_all(); - - - //----------------------------------- - //マージ - //----------------------------------- - pcl::PointCloud::Ptr calcPoints(new pcl::PointCloud()); - for (int i = 0; i < outputPoints.size(); i++) - { - //pcl::PointIndices::Ptr indices = getPlaneIndices(outputPoints[i]); - //extractIndices(outputPoints[i], indices); - - *calcPoints += *outputPoints[i]; - //registrationClouds[i].reset(); - } - //registrationClouds.clear(); - - //Filter - float voxelVal = 0.02f; - voxelGridFilter(voxelVal, calcPoints); - statisticalOutlierFilter(calcPoints); - - //Copy - margedCloud->clear(); - *margedCloud = *calcPoints; - - //----------------------------------- - //クラスタ分割 - //----------------------------------- - //ポイントクラウドをクラスタに分割 - //voxelGridFilter(0.05f, calcPoints); - euclideanClusterExtraction(calcPoints, eachClouds); - calcPoints.reset(); - - //重心計算 - centroids.clear(); - for (int i = 0; i < eachClouds.size(); i++) - { - //クラスタの重心を計算 - Eigen::Vector4f center = centroid(eachClouds[i]); - centroids.push_back(center); - } - - //分割されたクラスタに色を付けて表示 - //pcl::PointCloud::Ptr clusteredColorCloud(new pcl::PointCloud()); - //vector::Ptr> coloredClouds; - //for (int i = 0; i < eachClouds.size(); i++) - //{ - // pcl::PointCloud::Ptr cc(new pcl::PointCloud()); - // pcl::copyPointCloud(*eachClouds[i], *cc); - // coloredClouds.push_back(cc); - // double red = 255 * (i % 2 * 3 / (double)eachClouds.size()); - // double green = 255 - 255 * ((i % 3) * 3 / (double)eachClouds.size()); - // double blue = 255 - 255 * ((i % 5) * 3 / (double)eachClouds.size()); - // for (int j = 0; j < coloredClouds[i]->points.size(); j++) - // { - // coloredClouds[i]->points[j].r = red; - // coloredClouds[i]->points[j].g = green; - // coloredClouds[i]->points[j].b = blue; - // } - // *clusteredColorCloud += *coloredClouds[i]; - //} - //cout << "Cluster: " << eachClouds.size() << endl; - //clusterViewer.showCloud(clusteredColorCloud); - - std::cout << "----------------------------------\n" << std::endl; -} - -void PCLManager::registrationAll(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputClouds, Eigen::Matrix4f &matrix) { - if (inputCloud->empty()) - { - return; - } - - pcl::PointCloud::Ptr p(new pcl::PointCloud()); - pcl::transformPointCloud(*inputCloud, *p, matrix); - *inputCloud = *p; - p.reset(); - *outputClouds += *inputCloud; -} - -void PCLManager::createPolygon(vector::Ptr> &clouds) { - //各キネクトのデプスに対してポリゴン生成 - polygonMeshs.clear(); - for (int i = 0; i < clouds.size(); i++) - { - voxelGridFilter(0.005f, clouds[i]); - if (clouds[i]->size() > 100) - { - polygonMeshs.push_back(createMeshWithOFM(clouds[i]));; - } - } - cout << "NUM Polygon Mesh: " << polygonMeshs.size() << endl; -} - -void PCLManager::transform(pcl::PointCloud::Ptr cloud, float x, float y, float z, float pitch, float yaw, float roll) -{ - Eigen::Affine3f transform = Eigen::Affine3f::Identity(); - float pitchRad = pitch / 180.0 * M_PI; - float yawRad = yaw / 180.0 * M_PI; - float rollRad = roll / 180.0 * M_PI; - //回転 - transform.rotate(Eigen::AngleAxisf(pitchRad, Eigen::Vector3f::UnitX())); - transform.rotate(Eigen::AngleAxisf(yawRad, Eigen::Vector3f::UnitY())); - transform.rotate(Eigen::AngleAxisf(rollRad, Eigen::Vector3f::UnitZ())); - - //移動 - transform.translation() << x, y, z; - - //実行 - pcl::PointCloud::Ptr p(new pcl::PointCloud()); - pcl::transformPointCloud(*cloud, *p, transform); - *cloud = *p; - p.reset(); -} - -void PCLManager::edgeRmoveFilter(pcl::PointCloud::Ptr cloud) { - //法線 - pcl::PointCloud::Ptr normal = createNormals(cloud); - - //法線の傾きが一定以上だったらスルー - vector removeIndex; - for (int i = 0; i < cloud->points.size(); i++) - { - if (abs(normal->points[i].normal_x / normal->points[i].normal_z) > 0.1) - { - removeIndex.push_back(i); - } - } - - for (int i = 0; i < removeIndex.size(); i++) - { - cloud->erase(cloud->points.begin() + removeIndex[i] - i); - } -} - - -void PCLManager::statisticalOutlierFilter(pcl::PointCloud::Ptr cloud) -{ - pcl::StatisticalOutlierRemoval sor; - sor.setInputCloud(cloud); - sor.setMeanK(10); //近接何ポイントを使うか - sor.setStddevMulThresh(1.0); //この標準偏差以上をフィルターして切る - - pcl::PointCloud::Ptr cloud_filtered(new pcl::PointCloud); - sor.filter(*cloud_filtered); - - pcl::copyPointCloud(*cloud_filtered, *cloud); - cloud_filtered.reset(); -} - -void PCLManager::voxelGridFilter(float leaf, pcl::PointCloud::Ptr cloud) -{ - //VoxelGrid - pcl::VoxelGrid grid; - grid.setLeafSize(leaf, leaf, leaf); //フィルター範囲設定 - grid.setInputCloud(cloud); - pcl::PointCloud::Ptr cloud_filtered(new pcl::PointCloud()); - grid.filter(*cloud_filtered); - pcl::copyPointCloud(*cloud_filtered, *cloud); - cloud_filtered.reset(); -} - -void PCLManager::extractIndices(pcl::PointCloud::Ptr cloud, pcl::PointIndices::Ptr inliners) -{ - pcl::PointCloud::Ptr tmp(new pcl::PointCloud()); - pcl::copyPointCloud(*cloud, *tmp); - - pcl::ExtractIndices extract; - extract.setInputCloud(tmp); - extract.setIndices(inliners); - - extract.setNegative(true); - extract.filter(*cloud); -} - -pcl::PointIndices::Ptr PCLManager::getPlaneIndices(pcl::PointCloud::Ptr cloud) -{ - pcl::ModelCoefficients::Ptr coefficients(new pcl::ModelCoefficients); - pcl::PointIndices::Ptr inliners(new pcl::PointIndices); - - pcl::SACSegmentation seg; - seg.setOptimizeCoefficients(true); - seg.setModelType(pcl::SACMODEL_PLANE); - seg.setMethodType(pcl::SAC_RANSAC); - seg.setDistanceThreshold(0.03); - - seg.setInputCloud(cloud); - seg.segment(*inliners, *coefficients); - - return inliners; -} - -pcl::PointCloud::Ptr PCLManager::createNormals(pcl::PointCloud::Ptr cloud, int KSearh) -{ - // Normal estimation - // Normal estimation* - pcl::NormalEstimation n; - pcl::PointCloud::Ptr normals(new pcl::PointCloud); - pcl::search::KdTree::Ptr tree(new pcl::search::KdTree); - tree->setInputCloud(cloud); - n.setInputCloud(cloud); - n.setSearchMethod(tree); - n.setKSearch(KSearh); - n.compute(*normals); - - //pcl::PointCloud::Ptr cloud_with_normals(new pcl::PointCloud); - //pcl::concatenateFields(*cloud, *normals, *cloud_with_normals); - - return normals; -} - -pcl::PointCloud::Ptr PCLManager::createNormals(pcl::PointCloud::Ptr cloud) -{ - //法線の取得 - //法線格納用のスマートポインタを用意 - pcl::PointCloud::Ptr cloud_with_normals(new pcl::PointCloud); - //スムージング用のモジュールを用意 - pcl::MovingLeastSquares mls; - //kdTreeモジュール - pcl::search::KdTree::Ptr tree(new pcl::search::KdTree); - - mls.setComputeNormals(true); //法線の計算を行うかどうか - mls.setInputCloud(cloud); //入力のポイントクラウド - mls.setPolynomialFit(true); //多項式フィッティングやるかどうか。オフにすると速くはなる。 - mls.setSearchMethod(tree); //探索メソッドの設定 - mls.setSearchRadius(0.06); //平滑化の具合(0.03位が打倒?0.06でだいぶ平らになる)http://www.cc.kyoto-su.ac.jp/~kano/pdf/study/student/2013YamamotoPresen.pdf - //計算 - - mls.process(*cloud_with_normals); - - return cloud_with_normals; -} - -pcl::PolygonMesh PCLManager::createMeshWithOFM(pcl::PointCloud::Ptr cloud) -{ - //RangeImageに一度変換する - float angularResolution = (float)(0.1f * (M_PI / 180.0f)); // 1.0 degree in radians - float maxAngleWidth = (float)(120.0f * (M_PI / 180.0f)); // 360.0 degree in radians - float maxAngleHeight = (float)(60.0f * (M_PI / 180.0f)); // 180.0 degree in radians - Eigen::Affine3f sensorPose = (Eigen::Affine3f)Eigen::Translation3f(0.0f, 0.0f, 0.0f); - pcl::RangeImage::CoordinateFrame coordinate_frame = pcl::RangeImage::CAMERA_FRAME; - float noiseLevel = 0.0; - float minRange = 0.0f; - int borderSize = 0; - - pcl::RangeImage rangeImage; - rangeImage.createFromPointCloud(*cloud, angularResolution, maxAngleWidth, maxAngleHeight, - sensorPose, coordinate_frame, noiseLevel, minRange, borderSize); - //std::cout << rangeImage << std::endl; - - //RangeImageから再度PointCloudにOrganized Point Cloudとして変換 - pcl::PointCloud::Ptr rangedCloud(new pcl::PointCloud()); - rangedCloud->width = rangeImage.width; - rangedCloud->height = rangeImage.height; - rangedCloud->resize(rangeImage.width * rangeImage.height); - for (int i = 0; i < rangeImage.size(); i++) - { - pcl::copyPoint(rangeImage.points[i], rangedCloud->points[i]); - } - - //メッシュ化 - pcl::OrganizedFastMesh ofm; - ofm.setTrianglePixelSize(2); - - ofm.setTriangulationType(pcl::OrganizedFastMesh::TRIANGLE_ADAPTIVE_CUT); - ofm.setInputCloud(rangedCloud); - pcl::PolygonMesh mesh; - ofm.reconstruct(mesh); - - return mesh; -} - -pcl::PolygonMesh PCLManager::createMeshWithGP3(pcl::PointCloud::Ptr cloud) -{ - ////法線の取得 - ////法線格納用のスマートポインタを用意 - //pcl::PointCloud::Ptr cloud_with_normals(new pcl::PointCloud); - ////スムージング用のモジュールを用意 - //pcl::MovingLeastSquares mls; - ////kdTreeモジュール - //pcl::search::KdTree::Ptr tree(new pcl::search::KdTree); - - //mls.setComputeNormals(true); //法線の計算を行うかどうか - //mls.setInputCloud(cloud); //入力のポイントクラウド - //mls.setPolynomialFit(true); //多項式フィッティングやるかどうか。オフにすると速くはなる。 - //mls.setSearchMethod(tree); //探索メソッドの設定 - //mls.setSearchRadius(0.04); //平滑化の具合(0.03位が打倒?0.06でだいぶ平らになる)http://www.cc.kyoto-su.ac.jp/~kano/pdf/study/student/2013YamamotoPresen.pdf - // //計算 - //mls.process(*cloud_with_normals); - - - // Normal estimation* - pcl::NormalEstimation n; - pcl::PointCloud::Ptr normals(new pcl::PointCloud); - pcl::search::KdTree::Ptr tree(new pcl::search::KdTree); - tree->setInputCloud(cloud); - n.setInputCloud(cloud); - n.setSearchMethod(tree); - n.setKSearch(20); - n.compute(*normals); - //* normals should not contain the point normals + surface curvatures - - // Concatenate the XYZ and normal fields* - pcl::PointCloud::Ptr cloud_with_normals(new pcl::PointCloud); - pcl::concatenateFields(*cloud, *normals, *cloud_with_normals); - //* cloud_with_normals = cloud + normals - - // Create search tree* - pcl::search::KdTree::Ptr tree2(new pcl::search::KdTree); - tree2->setInputCloud(cloud_with_normals); - - //メッシュ化 - //Greedy Projection Triangulateアルゴリズムを使用 - pcl::GreedyProjectionTriangulation gp3; - - gp3.setSearchRadius(0.025); //近傍探索に使うスフィアのサイズ - gp3.setMu(2.5); //近傍探索を行うのに使う乗数 - gp3.setMaximumNearestNeighbors(100); //近傍にいくつ見つけるかの最大数設定 - - gp3.setMaximumSurfaceAngle(M_PI); //単位正規偏差がこれ以上だったら無視 - gp3.setMinimumAngle(M_PI / 18); //各ポリゴンの持ちうる表面法線の傾き - gp3.setMaximumAngle(2 * M_PI / 2); //各ポリゴンの持ちうる表面法線の傾き最大値 - gp3.setNormalConsistency(true); //(←要リサーチ) - - //結果の取得 - gp3.setInputCloud(cloud_with_normals); - pcl::search::KdTree::Ptr tree3(new pcl::search::KdTree); - gp3.setSearchMethod(tree3); - pcl::PolygonMesh mesh; - gp3.reconstruct(mesh); - - return mesh; -} - -Eigen::Matrix4f PCLManager::iterativeClosestPoint(pcl::PointCloud::Ptr target, pcl::PointCloud::Ptr source) -{ - pcl::IterativeClosestPoint icp; - icp.setInputTarget(target); - icp.setInputSource(source); - icp.align(*source); - - return icp.getFinalTransformation(); -} - -pcl::PolygonMesh PCLManager::concaveHull(pcl::PointCloud::Ptr cloud) { - // Create a Concave Hull representation of the projected inliers - pcl::PointCloud::Ptr cloud_hull(new pcl::PointCloud); - pcl::ConcaveHull chull; - chull.setInputCloud(cloud); - chull.setAlpha(0.03); - pcl::PointCloud::Ptr voronoi_centers(new pcl::PointCloud); - chull.setVoronoiCenters(voronoi_centers); - chull.setKeepInformation(true); - vector polygons; - chull.reconstruct(*cloud_hull, polygons); - - pcl::PolygonMesh mesh; - - pcl::toROSMsg(*cloud_hull, mesh.cloud); - mesh.polygons = polygons; - - *cloud = *cloud_hull; - - - return mesh; -} - -void PCLManager::createRangeImage(pcl::PointCloud::Ptr cloud, pcl::RangeImage &rangeImage) -{ - //RangeImageに一度変換する - float sensorAngleWidht = 90.0f; - float sensorAngleHeight = 60.0f; - float angularResolution = (float)(0.15f * (M_PI / 180.0f)); // 1.0 degree in radians - float maxAngleWidth = (float)(sensorAngleWidht * (M_PI / 180.0f)); // 360.0 degree in radians - float maxAngleHeight = (float)(sensorAngleHeight * (M_PI / 180.0f)); // 180.0 degree in radians - Eigen::Affine3f sensorPose = (Eigen::Affine3f)Eigen::Translation3f(0.0f, 0.0f, 0.0f); - pcl::RangeImage::CoordinateFrame coordinate_frame = pcl::RangeImage::CAMERA_FRAME; - float noiseLevel = 0.0; - float minRange = 0.0f; - int borderSize = 0; - - rangeImage.createFromPointCloud(*cloud, angularResolution, maxAngleWidth, maxAngleHeight, - sensorPose, coordinate_frame, noiseLevel, minRange, borderSize); - //std::cout << rangeImage << std::endl; -} - -void PCLManager::createOrganizedCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud) -{ - pcl::RangeImage rangeImage; - createRangeImage(inputCloud, rangeImage); - - //RangeImageから再度PointCloudにOrganized Point Cloudとして変換 - pcl::PointCloud::Ptr rangedCloud(new pcl::PointCloud()); - rangedCloud->width = rangeImage.width; - rangedCloud->height = rangeImage.height; - rangedCloud->resize(rangeImage.width * rangeImage.height); - pcl::copyPointCloud(rangeImage, *rangedCloud); - *outputCloud = *rangedCloud; -} - -void PCLManager::euclideanClusterExtraction(pcl::PointCloud::Ptr cloud, vector::Ptr> &outputCloud) { - //Clusterに分割 - pcl::search::KdTree::Ptr tree(new pcl::search::KdTree); - tree->setInputCloud(cloud); - - vector cluster_indices; - pcl::EuclideanClusterExtraction ec; - ec.setClusterTolerance(0.08); // 2cm - ec.setMinClusterSize(600); - ec.setMaxClusterSize(25000); - ec.setSearchMethod(tree); - ec.setInputCloud(cloud); - ec.extract(cluster_indices); - - //分割されたインデックスを元に、クラウドを分割して返す - //Reset - for (int i = 0; i < outputCloud.size(); i++) - { - outputCloud[i].reset(); - } - outputCloud.clear(); - - //Thread - boost::thread_group ths; - for (int i = 0; i < cluster_indices.size(); i++) - { - pcl::PointCloud::Ptr p(new pcl::PointCloud()); - outputCloud.push_back(p); - ths.create_thread(boost::bind(&PCLManager::splitCloud, this, cloud, outputCloud[i], cluster_indices[i])); - } - ths.join_all(); -} - -void PCLManager::splitCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr ouputCloud, pcl::PointIndices &indices) { - for (int j = 0; j < indices.indices.size(); j++) - { - int index = indices.indices[j]; - ouputCloud->push_back(inputCloud->points[index]); - } -} - -void PCLManager::createLineWithCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud) -{ - //探索する近傍点の数 - int K = 10; - - //こいつに格納してく - pcl::PointCloud::Ptr c(new pcl::PointCloud()); - - outputCloud->clear(); - - //kdTree - pcl::KdTreeFLANN kdTree; - kdTree.setInputCloud(inputCloud); - - int count = 0; - for (int i = 0; i < inputCloud->size(); i += 1) - { - //この点から最近傍の2点を取得して格納していく - //探索対象の点 - PointType p = inputCloud->points[i]; - - if (p.z < 2.0) - { - continue; - } - - //結果が格納される配列 - vector indexSearch(K); - vector distanceSearch(K); - - //探索 - if (kdTree.radiusSearch(p, 0.06, indexSearch, distanceSearch, 2)) - { - for (int j = 1; j < indexSearch.size(); j += 1) - { - float distance = sqrtf(distanceSearch[j]); - int index = indexSearch[j]; - //if (distance < 0.05) - //{ - // c->push_back(p); - // c->push_back(inputCloud->points[index]); - //} - c->push_back(p); - c->push_back(inputCloud->points[index]); - } - } - } - - - /*cout << ";;;;;;;;;;;input: " << inputCloud->size() << ", " << c->size() << endl;*/ - //出力にマージ - *outputCloud += *c; -} - - -void PCLManager::createPolygonWithRangeImage(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud) -{ - //RangeImageに一度変換する - float angularResolution = (float)(0.1f * (M_PI / 180.0f)); // 1.0 degree in radians - float maxAngleWidth = (float)(120.0f * (M_PI / 180.0f)); // 360.0 degree in radians - float maxAngleHeight = (float)(60.0f * (M_PI / 180.0f)); // 180.0 degree in radians - Eigen::Affine3f sensorPose = (Eigen::Affine3f)Eigen::Translation3f(0.0f, 0.0f, 0.0f); - pcl::RangeImage::CoordinateFrame coordinate_frame = pcl::RangeImage::CAMERA_FRAME; - float noiseLevel = 0.0; - float minRange = 0.0f; - int borderSize = 0; - - pcl::RangeImage rangeImage; - rangeImage.createFromPointCloud(*inputCloud, angularResolution, maxAngleWidth, maxAngleHeight, - sensorPose, coordinate_frame, noiseLevel, minRange, borderSize); - //std::cout << rangeImage << std::endl; - - //RangeImageから再度PointCloudにOrganized Point Cloudとして変換 - pcl::PointCloud::Ptr rangedCloud(new pcl::PointCloud()); - rangedCloud->width = rangeImage.width; - rangedCloud->height = rangeImage.height; - rangedCloud->resize(rangeImage.width * rangeImage.height); - for (int i = 0; i < rangeImage.size(); i++) - { - pcl::copyPoint(rangeImage.points[i], rangedCloud->points[i]); - } - - outputCloud->clear(); - pcl::PointCloud::Ptr triangleCloud(new pcl::PointCloud()); - for (int y = 1; y < rangedCloud->height - 1; y++) - { - for (int x = 1; x < rangedCloud->width - 1; x++) - { - int index = y * rangedCloud->width + x; - PointType p = rangedCloud->points[index]; - - - //左 - int indexLeft = y * rangedCloud->width + (x - 1); - PointType leftP = rangedCloud->points[indexLeft]; - //上 - int indexTop = (y - 1) * rangedCloud->width + x; - PointType topP = rangedCloud->points[indexTop]; - //右 - int indexRight = y * rangedCloud->width + (x + 1); - PointType rightP = rangedCloud->points[indexRight]; - //下 - int indexBtm = (y + 1) * rangedCloud->width + x; - PointType btmP = rangedCloud->points[indexBtm]; - - //左上ポリゴン - if (p.z > 1 && leftP.z > 1 && topP.z > 1) - { - triangleCloud->points.push_back(p); - triangleCloud->points.push_back(topP); - triangleCloud->points.push_back(leftP); - } - - ////右下ポリゴン - //if (rightP.z > 1 && btmP.z > 1) - //{ - // triangleCloud->points.push_back(p); - // triangleCloud->points.push_back(btmP); - // triangleCloud->points.push_back(rightP); - //} - - ////左下ポリゴン - //if (leftP.z > 1 && btmP.z > 1) - //{ - // triangleCloud->points.push_back(p); - // triangleCloud->points.push_back(leftP); - // triangleCloud->points.push_back(btmP); - //} - - //右上ポリゴン - if (p.z > 1 && rightP.z > 1 && topP.z > 1) - { - triangleCloud->points.push_back(p); - triangleCloud->points.push_back(rightP); - triangleCloud->points.push_back(topP); - } - } - } - - *outputCloud = *triangleCloud; -} - - -void PCLManager::createPolygonWithCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud) -{ - //探索する近傍点の数 - int K = 90; - - //kdTree - pcl::KdTreeFLANN kdTree; - kdTree.setInputCloud(inputCloud); - - - for (int i = 0; i < inputCloud->size(); i += 1) - { - //この点から最近傍の2点を取得して格納していく - //探索対象の点 - PointType p = inputCloud->points[i]; - - //結果が格納される配列 - vector indexSearch(K); - vector distanceSearch(K); - - //探索 - if (kdTree.radiusSearch(p, 0.3, indexSearch, distanceSearch, K)) - { - if (indexSearch.size() >= 3) - { - for (int j = 0; j < indexSearch.size(); j += 3) - { - if (sqrtf(distanceSearch[j]) + sqrtf(distanceSearch[j + 1]) + sqrtf(distanceSearch[j + 2]) < 0.36) - { - outputCloud->push_back(inputCloud->points[indexSearch[j]]); - outputCloud->push_back(inputCloud->points[indexSearch[j + 1]]); - outputCloud->push_back(inputCloud->points[indexSearch[j + 2]]); - } - } - } - } - } -} - -pcl::PointCloud::Ptr PCLManager::projectionToZ(pcl::PointCloud::Ptr cloud, float zValue) { - //与えられたZの値にある平面にクラウドをプロジェクションする - // Create a set of planar coefficients with X=Y=0,Z=1 - pcl::ModelCoefficients::Ptr coefficients(new pcl::ModelCoefficients()); - coefficients->values.resize(4); - coefficients->values[0] = coefficients->values[1] = 0; - coefficients->values[2] = 1.0; - coefficients->values[3] = zValue; - - // Create the filtering object - pcl::PointCloud::Ptr cloud_projected(new pcl::PointCloud()); - pcl::ProjectInliers proj; - proj.setModelType(pcl::SACMODEL_PLANE); - proj.setInputCloud(cloud); - proj.setModelCoefficients(coefficients); - proj.filter(*cloud_projected); - - return cloud_projected; -} - -Eigen::Vector4f PCLManager::centroid(pcl::PointCloud::Ptr cloud) -{ - Eigen::Vector4f xyz_centroid; - pcl::compute3DCentroid(*cloud, xyz_centroid);//重心を計算 - - return xyz_centroid; -} \ No newline at end of file diff --git a/Kinect_Master_App/Kinect_Master_App/PCLManager.h b/Kinect_Master_App/Kinect_Master_App/PCLManager.h deleted file mode 100644 index e790014..0000000 --- a/Kinect_Master_App/Kinect_Master_App/PCLManager.h +++ /dev/null @@ -1,78 +0,0 @@ -#pragma once -class PCLManager -{ -public: - PCLManager(); - void update(std::vector::Ptr> &outputPoints); - void registrationAll(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputClouds, Eigen::Matrix4f &matrix); - void createPolygon(vector::Ptr>& clouds); - - inline pcl::PointCloud::Ptr getMargedPoints() { return margedCloud; } - inline vector::Ptr> getClusteredPoints() { - return eachClouds; - } - inline vector getPlygonMeshs() { return polygonMeshs; } - inline vector getCentroids() { return centroids; } - -private: - //移動・回転 - void transform(pcl::PointCloud::Ptr cloud, float x, float y, float z, float pitch, float yaw, float roll); - - void edgeRmoveFilter(pcl::PointCloud::Ptr cloud); - - //Filter - void statisticalOutlierFilter(pcl::PointCloud::Ptr cloud); - void voxelGridFilter(float leaf, pcl::PointCloud::Ptr cloud); - void extractIndices(pcl::PointCloud::Ptr cloud, pcl::PointIndices::Ptr inliners); - - //Segmentation - pcl::PointIndices::Ptr getPlaneIndices(pcl::PointCloud::Ptr cloud); - - //Create Normal - pcl::PointCloud::Ptr createNormals(pcl::PointCloud::Ptr cloud, int KSearh); - pcl::PointCloud::Ptr createNormals(pcl::PointCloud::Ptr cloud); - - //CreateMesh - pcl::PolygonMesh createMeshWithOFM(pcl::PointCloud::Ptr cloud); - pcl::PolygonMesh createMeshWithGP3(pcl::PointCloud::Ptr cloud); - - //ICP - Eigen::Matrix4f iterativeClosestPoint(pcl::PointCloud::Ptr target, pcl::PointCloud::Ptr source); - Eigen::Matrix4f transformationVector[NUM_KINECT]; //just for debug - Eigen::Matrix4f ICPTransformMatrix[NUM_KINECT]; - - //Concave Hull - pcl::PolygonMesh concaveHull(pcl::PointCloud::Ptr cloud); - - //RangeImage - void createRangeImage(pcl::PointCloud::Ptr cloud, pcl::RangeImage &rangeImage); - void createOrganizedCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud); - - //EuclideanClusterExtraction(クラスタ毎にクラウドを分割) - //マージしたクラウド - pcl::PointCloud::Ptr margedCloud; - //クラスタ分けしたクラウド群 - vector::Ptr> eachClouds; - - //クラスタに分けるやつ - void euclideanClusterExtraction(pcl::PointCloud::Ptr cloud, vector::Ptr> &outputCloud); - void splitCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr ouputCloud, pcl::PointIndices &indices); - - //与えられたクラウドから、ポリゴンを生成するやつ - void createLineWithCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud); - void createPolygonWithCloud(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud); - void createPolygonWithRangeImage(pcl::PointCloud::Ptr inputCloud, pcl::PointCloud::Ptr outputCloud); - - //z平面にプロジェクションするやつ - pcl::PointCloud::Ptr projectionToZ(pcl::PointCloud::Ptr cloud, float zValue); - - //重心を算出するやつ - Eigen::Vector4f centroid(pcl::PointCloud::Ptr cloud); - - //Mesh - vector polygonMeshs; - - //Centroids - vector centroids; - -}; diff --git a/Kinect_Master_App/Kinect_Master_App/ReadMe.txt b/Kinect_Master_App/Kinect_Master_App/ReadMe.txt deleted file mode 100644 index 07becd6..0000000 --- a/Kinect_Master_App/Kinect_Master_App/ReadMe.txt +++ /dev/null @@ -1,30 +0,0 @@ -サソ======================================================================== - 繧ウ繝ウ繧ス繝シ繝ォ 繧「繝励Μ繧ア繝シ繧キ繝ァ繝ウ: Kinect_Master_App 繝励Ο繧ク繧ァ繧ッ繝医ョ讎りヲ -======================================================================== - -縺薙ョ Kinect_Master_App 繧「繝励Μ繧ア繝シ繧キ繝ァ繝ウ縺ッ縲、ppWizard 縺ォ繧医j菴懈舌&繧後∪縺励◆縲 - -縺薙ョ繝輔ぃ繧、繝ォ縺ォ縺ッ縲゜inect_Master_App 繧「繝励Μ繧ア繝シ繧キ繝ァ繝ウ繧呈ァ区舌☆繧句推繝輔ぃ繧、繝ォ縺ョ蜀螳ケ縺ョ讎りヲ√′蜷ォ縺セ繧後※縺縺セ縺吶 - - -Kinect_Master_App.vcxproj - 縺薙l縺ッ縲√い繝励Μ繧ア繝シ繧キ繝ァ繝ウ 繧ヲ繧」繧カ繝シ繝峨r菴ソ逕ィ縺励※逕滓舌&繧後◆ VC++ 繝励Ο繧ク繧ァ繧ッ繝医ョ繝。繧、繝ウ 繝励Ο繧ク繧ァ繧ッ繝 繝輔ぃ繧、繝ォ縺ァ縺吶ゅヵ繧。繧、繝ォ繧堤函謌舌@縺 Visual C++ 縺ョ繝舌シ繧ク繝ァ繝ウ縺ォ髢「縺吶k諠蝣ア縺ィ縲√い繝励Μ繧ア繝シ繧キ繝ァ繝ウ 繧ヲ繧」繧カ繝シ繝峨〒驕ク謚槭&繧後◆繝励Λ繝繝医ヵ繧ゥ繝シ繝縲∵ァ区舌√♀繧医ウ繝励Ο繧ク繧ァ繧ッ繝域ゥ溯ス縺ォ髢「縺吶k諠蝣ア縺悟性縺セ繧後※縺縺セ縺吶 - -Kinect_Master_App.vcxproj.filters - 縺薙l縺ッ縲√い繝励Μ繧ア繝シ繧キ繝ァ繝ウ 繧ヲ繧」繧カ繝シ繝峨〒逕滓舌&繧後◆ VC++ 繝励Ο繧ク繧ァ繧ッ繝医ョ繝輔ぅ繝ォ繧ソ繝シ 繝輔ぃ繧、繝ォ縺ァ縺吶ゅ%縺ョ繝輔ぃ繧、繝ォ縺ォ縺ッ縲√励Ο繧ク繧ァ繧ッ繝亥縺ョ繝輔ぃ繧、繝ォ縺ィ繝輔ぅ繝ォ繧ソ繝シ縺ィ縺ョ髢薙ョ髢「騾」莉倥¢縺ォ髢「縺吶k諠蝣ア縺悟性縺セ繧後※縺縺セ縺吶ゅ%縺ョ髢「騾」莉倥¢縺ッ縲∫音螳壹ョ繝弱シ繝峨〒蜷梧ァ倥ョ諡。蠑オ蟄舌r謖√▽繝輔ぃ繧、繝ォ縺ョ繧ー繝ォ繝シ繝怜喧繧堤、コ縺吶◆繧√↓ IDE 縺ァ菴ソ逕ィ縺輔l縺セ縺 (縺溘→縺医ー縲".cpp" 繝輔ぃ繧、繝ォ縺ッ "繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ" 繝輔ぅ繝ォ繧ソ繝シ縺ォ髢「騾」莉倥¢繧峨l縺ヲ縺縺セ縺)縲 - -Kinect_Master_App.cpp - 縺薙l縺ッ縲√Γ繧、繝ウ縺ョ繧「繝励Μ繧ア繝シ繧キ繝ァ繝ウ 繧ス繝シ繧ケ 繝輔ぃ繧、繝ォ縺ァ縺吶 - -///////////////////////////////////////////////////////////////////////////// -縺昴ョ莉悶ョ讓呎コ悶ヵ繧。繧、繝ォ : - -StdAfx.h, StdAfx.cpp - 縺薙l繧峨ョ繝輔ぃ繧、繝ォ縺ッ縲゜inect_Master_App.pch 縺ィ縺縺蜷榊燕縺ョ繝励Μ繧ウ繝ウ繝代う繝ォ貂医∩繝倥ャ繝繝シ (PCH) 繝輔ぃ繧、繝ォ縺ィ縲ヾtdAfx.obj 縺ィ縺縺蜷榊燕縺ョ繝励Μ繧ウ繝ウ繝代う繝ォ貂医∩縺ョ蝙九ヵ繧。繧、繝ォ繧偵ン繝ォ繝峨☆繧九◆繧√↓菴ソ逕ィ縺輔l縺セ縺吶 - -///////////////////////////////////////////////////////////////////////////// -縺昴ョ莉悶ョ繝。繝「 : - -AppWizard 縺ァ縺ッ "TODO:" 繧ウ繝。繝ウ繝医r菴ソ逕ィ縺励※縲√Θ繝シ繧カ繝シ縺瑚ソス蜉縺セ縺溘ッ繧ォ繧ケ繧ソ繝槭う繧コ縺吶k蠢隕√ョ縺ゅk繧ス繝シ繧ケ 繧ウ繝シ繝峨r遉コ縺励∪縺吶 - -///////////////////////////////////////////////////////////////////////////// diff --git a/Kinect_Master_App/Kinect_Master_App/Singleton.h b/Kinect_Master_App/Kinect_Master_App/Singleton.h deleted file mode 100644 index 45cc929..0000000 --- a/Kinect_Master_App/Kinect_Master_App/Singleton.h +++ /dev/null @@ -1,34 +0,0 @@ -// -// Singleton.h -// PhDanceMasterApp -// -// Created by YOHEI KAJIWARA on 2014/12/24. -// -// - -#ifndef __Ainz_FaceMoverTest__Singleton__ -#define __Ainz_FaceMoverTest__Singleton__ - -#include - -template -class Singleton{ -public: - // 蜚ッ荳縺ョ繧「繧ッ繧サ繧ケ邨瑚キッ - static inline T& GetInstance() - { - static T instance; // 蜚ッ荳縺ョ繧、繝ウ繧ケ繧ソ繝ウ繧ケ - return instance; - } - -protected: - Singleton(){} - virtual ~Singleton() {} - -private: - // 逕滓舌d繧ウ繝斐シ繧堤ヲ∵ュ「縺吶k - Singleton(const Singleton& rhs); - Singleton& operator=(const Singleton& rhs); -}; - -#endif /* defined(__Ainz_FaceMoverTest__Singleton__) */ diff --git a/Kinect_Master_App/Kinect_Master_App/XMLFile.xml b/Kinect_Master_App/Kinect_Master_App/XMLFile.xml deleted file mode 100644 index 1e33fe8..0000000 --- a/Kinect_Master_App/Kinect_Master_App/XMLFile.xml +++ /dev/null @@ -1 +0,0 @@ - diff --git a/Kinect_Master_App/Kinect_Master_App/kinect_master.ico b/Kinect_Master_App/Kinect_Master_App/kinect_master.ico deleted file mode 100644 index e03708a6020caac6c5b8c86d77b384a8d9990e3b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 67646 zcmeHQ3y>AnnZDh9@4W6jba=xsAgPs^!MCnTd;nrF5sR2*X5^u$$U_k1p#p&rP$NXM zz6hwPBq+vgQLY%HTSjXmYqYY6T2^gBjG?kC$;OacqlhI0l*oSHx&7Zc_e}S_eeb+) zcTfFuy8r+D|M?&1oIdCDx!tjtg}?RdWB5NZ)=*}}2F7Bs1^`e*Dm+isMd~E_A9*11 zK;(hQ1Ca+J4@4e_JP>&x@<8N)Zuh|WOD~NDfpHTj#*QC99{Xx@Gj+59@t|N?R^YrM zvk)HPwQbueEi1!iERb!w{fa3>|6JQGqy+j)&Lvei#NT54Yy0<4AT}4lMQdZ0^=+gX z09wX1=^40ObXT6vqn}H8S#TQ>|Jfy_rGv^VDq@#Rnv`LOVV`cVsw^C+AGX-UQB>FEp{Ip|sbvo3W-Z=m+tUoHLE1{X2}m<2d6i+x{(ld^`}? zcCdUw1V4Wl=S(-*j>Gc@(f2Za2>rw!#DeiCtPZsA zI}V`CX8;dsOgpc4@=$H^S(zPwTrhG zj&DRwM&zV*a8a%kF=7bXlAx4iQ_Ma6Tf1}<& z-tQ6LDY&m!0;-#9UUfk34dSN+`qcQ{n>JZj&z>Fs=7tT{H}1UCzUGD-oF{hdux?nez*&Rq zy5Ymi(I@;6vH!FamoV)J5*IKq}mC|GC^y!Sf z=$oq!2t9P;zc+sKo7mKrmRLh$quq4ssqt}_T#`8D^wZ;KpL=fN!tvwdCpR?2ktR+* z>#X=`XPlw@)X>xvKmURY690Jq`Ej1p&!>Xt%yZ63TsUrA;^f9gg{!Tttwej>ihDq( z#UJ%(FWUc?Q3q`5b`f+t?~7lIH=c4z{GtgH5~HCHt`oq=M?;T`VGsI(_!(!PotS`r zfclQT@WRBoW5+5U_6-eV#>CG#@4UoilP5bTj~>mc6`BM7jG>L52!CFRdwL7bTS`ky zTXFwvPL!0i0^fpry28a1iDvk|74#O;F%N77PczP2u-4KF-ez340(Is@wud49 zT#NhwZ~$QT{k#rq{MW$tPti8^19oG4^q&|D??So@*Spj?#zyMg2M2zYPtT*{lq_8) z1eB&IHMfUUo&|!bZ0qjJg=dw*FfK$!DCr(;`$(-Gle<+hvAziux5HX z=2H!LZc1pv9IzpoOg3VE*92&&NG6*wuWCfvSXN%n^U=x5$|msex&i#eF`w{^2EXD_ zGRXt^3MV|tMSxvcg0g#*$7$_o>_?Qsd7?0 z)V&dN!;2CBUjp94eK3sUKeqovXiMK6F=|xlzdZAdy=CiG`+@I$&*mB%p7~izSFUtc z-+sHjbN6nGxL4kK%i{IoTW(SG1xuDV_dWcuT8mq-bg9BEzV%jT)w*@|yB~aD&AsWS z__Hs)WZiMkJ@(DF-R67>ne!p%{zo3Mw?FrsqW|H*0qfQ^Yn)Z<*W16_zn?hg7jM34 zZM^?}`$ov89ycvt?(q7Fr=PawEn4J!4%{u^p?>=h9a1tMf9fe~!+rPJqQ_0kmN~cI zeYgF>tFJ2h8}GcM%2~d8wS#!a@QkPqb^qUS8rt}y?>mh6Zy7miRK>!jOVzU=tm`?l ze$I2Ql>xZ6r_R0T%uirm$rq3(Ez>Bc#H*a~sd99lj50lWJaot2fH?Y(VT^y++dq7; zd1zf-a{9H`I(*je#(}BwEmFbpTF(9Gh4APyRb6w-DRI+WGRY%r{*q?pLHr%uH|i1l zu*YAu|GN76@@dyx>F>itE#K(dH)Y{``5>R z7~jiYAU{8we$@T!$I~n8KwvULvtH+TZvUUl_d?fwtDgsn4f6-( z@u~w}ILZ^<{OD=juol7oe>nR8P>=u6|EuvI=Ksm%U;n!8j{kG{QRsRMO&qVY(Mi+k z>DU0zbJ9$iI*(tBg~yMs%HjAA>zZMn|0gi+;q!mSe>3*>R&Y&3oBxX+B}PHw8HC4_ zBl0CR>84D*4g}>fWjZsjyUxMh~GMP{EN}7u&gN{9`Hl6|0;oisb|9-$6 z_#$6_itm%)?Y6puvUr>Yco?t^@K^!B{n>8;j-dT-89rh}l5--T`M=Z$)pr`c_lk{) z%kX`GIufKDFPUCAPu;I>GGHqpA75@m{vQCE0o@sY8|8fs@Cm@{ zd3HXyqa6PY9y+xAt5c`ae*)633TbO5kC#m1JY%EPFXqwp$i)-59Ikb#@t@-`{`vUJ z%=;PmHv+n?0-z|y|4IP&Gg6=T06zsh3HaB5@D%dx0UW^`Sgrrzxtz@Zz5MKj>yp^y zs24%>V4keHasG#A!yNxH{@fqP{RBb%N8h~-;GR_W9d`kGGXBq__$I($z>t7Yj}D8! z&zAMS&% zIRDRU{10EV|Ggd1o8sR;&-ioy?;6;Udj2zVWF_`;1R4M7^}^5hx#~!^cv8L>-3uq> zWaIIy19+E70{wp-);{xI|Ao)ufIEsL{;L1S?>8&HhB2`_|MzO2UO3&i`O*uGXTIey ze>wj4PFXZ`;Ssx0CXS>+A?X^qmz|?8e;@EfE_WUQ0{hvh^f3^OH{a@v{CrbRX`MxXK zbRl)1Lp<|uzS*v-sv2I%{+}X?e`@@P{XhIoJ=&f=zU$6@z0i2-bv3Z=YX1+$f0+M= zef+2Tf2{wR&wnKLk}^JW9>mYmm*m6KZFS(| zX;XUa@{MPqbHmQA1D<-!y#9Iz_y1vh{)2diIsS)W|CZtP^_ADno5%e>W;@Tf4luv) zc=}!&-}%w=t!peVuX@A&zr4IW8vkMalFxte{J)&@e=Rl=Lp`2?GwTSirO%L5@-h{< zCQkBt#oG&KmgA*|7p`47_&rg<`+th8|34(pfA~xsv66V1J`3V|oriMFcn6A&R+pH+ zOL)}tp8|jXQ*`m??|-oWJIC`MiG?2HE{RQd)SIjDTbIhV=RaY-|EuvI_J5RfP0Yjh zI?gNJUbx=EW9mU&6^`S7?*EDA|EcFc-2Zd^{P{ti|9HjQ3upS?ycg(nzk80!W0s@S zDbJ+yS}%v!3Maq+iJt%9`M$5 zy}k}a&wteW9~pny|JfD4|1P9W7s8{rd9(g{)D z#Kz-Zpzhf@<^^UQ(0SVRVO;;g?|%#W{dbYYKmGe}KL3G_`R*t64kx7QeeUi%m55XC zc+%*C%f+M93*nJ+bva(TWuudp=27E6{rBJD-v9H+3AME+Vh>Oy)`2VW9gj+k2df7T z8k7W7VQx?bToSZu>=UiTw>A{L-+%#0Tvy?HAXPZ8M7}f+_|rUiw}|2)9lYeJrc8dz z1HAlZNaX;d9P)@B_{K;Q-}*?E1KlVGJV}1 zBf32X-Je8Wz7IHz@lT-M&!X)Bz7PLH`0K-r6gc=Ng$qJw9+St#rDf}Kgcby+>*4Zc z=q9rCeEPXRowmOLSrdZ(eggT6VgEnP<#(E{#rH8*p^Xq$;+?3gfMdFnICTy>(pBgW z+USXdq9e}=@~3%Re!Ooz#iPsg;YpX-#ukau* z@?8n}RUwSO`mQhEuZr&{Ieho)_Gh29u{Tz|a~0omQtxp+!uPM@U8*}@f8DzGp@-~6 zco!>qmf(G^|Gas#z3bP%w)h^{qrk1b>n>--+O;<6e9!BS7hbS_v}1?8$bDZd%fa`f z>|ee6u6mCv-`%?Lfd_27|J6PS9?E|H<(DnI=hdc6%DHXrTIY`Me8=9kXOAl95ODH7 zS<)$c>-O#T6F>QhO+AU@`()Q`*kJQLv6S=r+izRne(*ti$%++<&U_ES-oG9_YEhqk zAAT4#{J3QnNBhTkI0jH-W_&9*J$A;q8YdG6P~&w!`UIilTYH=r=sf)X9&s!K__R!u zN2AC6$^kx8kCbkdnVYA*9%&xVH6erF{|fy3-C~G8?3M4oanA2GulK^~b8IiV7cLi% zNv8}GXU^rb(Mii!5AuYn{nK6m>%I6pm(K#NtGV(dUZ%`KV`It@oja=>>J_T?&&m#) z3Axt%=o|5~UI%hLoAaXwsRJxWFEblYN6L|UmDl$li>Uvn-Hg8;WATaL%(hlY9ng6s zu0hI?yprbPG3i0;4f#UV|GVv<@u!aj=m!}O$T@v4bwqGX$s>J7XYhz@iJ8dERgRbL zCXbg);>0$V71sWrbwKrhZYt->Ck9UPG9_Kc5W=I=gWz<2;ni_+E@=>%+2jb#ltcNU zYyY~zUiRxa{apBR;e;-!+vg~DFI-3IelorEmAp*lT=L~gi{bvC%f^WA?|~@({=NwV zC5nF-qU>*D6n}r;gn<&pKMYa!w=s&pzi+}oiQ*rIDEr$O#oymIVW33u4?~pwZH(gY z@0&1CqWFg)%KkP+@%Q&l7${Nv!w_YE8>9I9`z8#ODE?uHvcHW{{QZ3s21*qFFhtqk z#wh;&z6k>b@pk~-_5GhXd|C}SL4z8UKNIjVfZzXn4lv3ipU%^h=Sk>h1A-jDPp0y=tdPx2*z{{?*R0mp$8 z@S^t?-1E?LI3UO|8JYG0dW-IUdWhd8)${!u^dAi9=)w434A=wspbx{7(4F5K4{}UG zre6X2vc21(|DYho2FOFd%>pb0Ea-zkz1gNK0YQ!t$aD>$uiIM@#MmfL=m$E- z0G9*4(g%Thb4*tT2yzTSrU`()ZZE&D+Zo4L2>B)8_k9?)LiZtnAO~arDxfdh`vd6D zdfd^2*TPso|E}rLk@in} z9s`*6)&NI)KLhlny&R{oe(HTuSH_?ISOoAIUoHmz0HCM*!S={@xdm`o)1xEtKL|N1 z0p`Ky1akp@1N4-=yyq?iaQ$Dehg})}V<>AKpd6qd^v5>N zx--@LeJQsi@uxkn0WJpU$Jw~}1)!(xW%;HKT^)bc`JDjX2RL845%2;)?{mfXy&>&L z{HgyDz<&Ttdx`H2_L(|#b^KW#+u2_MoGWoIsP{jnK0STi(fE7W>($Tnw4G9ZXU2a5 zV!IE(ai0ksb1?1%lh&KAxlS=05ai&x?|%cl^zSS7a=!rQs-1D13?bhFa7?|qj{?WY zLH9$9LEbw7ebrv-&9xZrVd{*7W4t(k`Dd5P2Z-K;(hQ1Ca+J4@4e_JP>&x@<8N)$ODlFA`e6!C;|`Q zJJnr&q}*i1YTS~zDE$cXg!?Xx!oJ znl^tQqrB)^+*{K-{c(J~tDvi2TYC(qZ?60%z1{VJC2MBv-TU_8M^ojs^;gj~+fSxH zQn9Mxreqw)U1t`4-6lPCmXcezymtKKiK#il-DOH&{+t2V^-QS$KBhHCQajmjeO>CB Tzr5%S`;-{SPo<`{MSuPOlt}5$ diff --git a/Kinect_Master_App/Kinect_Master_App/stdafx.cpp b/Kinect_Master_App/Kinect_Master_App/stdafx.cpp deleted file mode 100644 index c2967fd..0000000 --- a/Kinect_Master_App/Kinect_Master_App/stdafx.cpp +++ /dev/null @@ -1,8 +0,0 @@ -// stdafx.cpp : 標準インクルード Kinect_Master_App.pch のみを -// 含むソース ファイルは、プリコンパイル済みヘッダーになります。 -// stdafx.obj にはプリコンパイル済み型情報が含まれます。 - -#include "stdafx.h" - -// TODO: このファイルではなく、STDAFX.H で必要な -// 追加ヘッダーを参照してください。 diff --git a/Kinect_Master_App/Kinect_Master_App/stdafx.h b/Kinect_Master_App/Kinect_Master_App/stdafx.h deleted file mode 100644 index ec2413c..0000000 --- a/Kinect_Master_App/Kinect_Master_App/stdafx.h +++ /dev/null @@ -1,52 +0,0 @@ -// stdafx.h : 標準のシステム インクルード ファイルのインクルード ファイル、または -// 参照回数が多く、かつあまり変更されない、プロジェクト専用のインクルード ファイル -// を記述します。 -// - -#pragma once - -#include "targetver.h" -//C++ -//#define _USE_MATH_DEFINES // for C++ -//#include -//#include -//#include -//#include -//#include -//#include -//#include -//#include -//#include -#include - -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "typeDef.h" - -// TODO: プログラムに必要な追加ヘッダーをここで参照してください diff --git a/Kinect_Master_App/Kinect_Master_App/targetver.h b/Kinect_Master_App/Kinect_Master_App/targetver.h deleted file mode 100644 index 10b7ccd..0000000 --- a/Kinect_Master_App/Kinect_Master_App/targetver.h +++ /dev/null @@ -1,8 +0,0 @@ -#pragma once - -// SDKDDKVer.h をインクルードすると、利用できる最も上位の Windows プラットフォームが定義されます。 - -// 以前の Windows プラットフォーム用にアプリケーションをビルドする場合は、WinSDKVer.h をインクルードし、 -// SDKDDKVer.h をインクルードする前に、サポート対象とするプラットフォームを示すように _WIN32_WINNT マクロを設定します。 - -#include diff --git a/Kinect_Master_App/Kinect_Master_App/typeDef.h b/Kinect_Master_App/Kinect_Master_App/typeDef.h deleted file mode 100644 index 812bf76..0000000 --- a/Kinect_Master_App/Kinect_Master_App/typeDef.h +++ /dev/null @@ -1,17 +0,0 @@ -#pragma once - -using namespace std; -using namespace std::chrono; - -//Kinect -#define NUM_KINECT 4 - -union DataConverter { - unsigned char data[4]; - short sValue[2]; - float fValue; - int iValue; -}; - -typedef pcl::PointXYZ PointType; -typedef pcl::PointNormal PointNormalType; diff --git a/Kinect_Master_App/Setup/Setup.vdproj b/Kinect_Master_App/Setup/Setup.vdproj deleted file mode 100644 index ef754d1..0000000 --- a/Kinect_Master_App/Setup/Setup.vdproj +++ /dev/null @@ -1,1061 +0,0 @@ -サソ"DeployProject" -{ -"VSVersion" = "3:800" -"ProjectType" = "8:{978C614F-708E-4E1A-B201-565925725DBA}" -"IsWebType" = "8:FALSE" -"ProjectName" = "8:Setup" -"LanguageId" = "3:1033" -"CodePage" = "3:1252" -"UILanguageId" = "3:1033" -"SccProjectName" = "8:" -"SccLocalPath" = "8:" -"SccAuxPath" = "8:" -"SccProvider" = "8:" - "Hierarchy" - { - "Entry" - { - "MsmKey" = "8:_1F68935E8524484792677C77057E802B" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_23C6D90EF9B44FD79FDE3B161644D590" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_3DB20EB9CAA74955B77FC8C035552831" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_4DE7D7A12FF4499482F1001A0E6A5C38" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_649E806B15714482A0FE9CF53E4E8DB8" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_67CC69E12BB64619844D46096C1A4206" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_7497D8290CFC4B7086F77DBDE82E7764" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_87AF0F8C21EE44EC940C0D6D73A7FD74" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_93DE62CA59C04502A0D9C02E1FAEDEE2" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_9AF8C4E4CE1749CF8FB342A929C985DB" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_A2A1CB3B98F64806A3CD1263D0318D28" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_A36823C4359149DF90119715B56400D1" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_B133EB77F3EB44D3B0C78C891CE64522" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_BC2A9CF2501945149CA4424A9D1EB902" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - "Entry" - { - "MsmKey" = "8:_E801C69C60644F069479862584A20DF4" - "OwnerKey" = "8:_UNDEFINED" - "MsmSig" = "8:_UNDEFINED" - } - } - "Configurations" - { - "Debug" - { - "DisplayName" = "8:Debug" - "IsDebugOnly" = "11:TRUE" - "IsReleaseOnly" = "11:FALSE" - "OutputFilename" = "8:Debug\\Setup.msi" - "PackageFilesAs" = "3:2" - "PackageFileSize" = "3:-2147483648" - "CabType" = "3:1" - "Compression" = "3:2" - "SignOutput" = "11:FALSE" - "CertificateFile" = "8:" - "PrivateKeyFile" = "8:" - "TimeStampServer" = "8:" - "InstallerBootstrapper" = "3:2" - } - "Release" - { - "DisplayName" = "8:Release" - "IsDebugOnly" = "11:FALSE" - "IsReleaseOnly" = "11:TRUE" - "OutputFilename" = "8:Release\\Kinect Master Setup.msi" - "PackageFilesAs" = "3:2" - "PackageFileSize" = "3:-2147483648" - "CabType" = "3:1" - "Compression" = "3:2" - "SignOutput" = "11:FALSE" - "CertificateFile" = "8:" - "PrivateKeyFile" = "8:" - "TimeStampServer" = "8:" - "InstallerBootstrapper" = "3:2" - } - } - "Deployable" - { - "CustomAction" - { - } - "DefaultFeature" - { - "Name" = "8:DefaultFeature" - "Title" = "8:" - "Description" = "8:" - } - "ExternalPersistence" - { - "LaunchCondition" - { - } - } - "File" - { - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_1F68935E8524484792677C77057E802B" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_ml_release.dll" - "TargetName" = "8:pcl_ml_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_23C6D90EF9B44FD79FDE3B161644D590" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_segmentation_release.dll" - "TargetName" = "8:pcl_segmentation_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_3DB20EB9CAA74955B77FC8C035552831" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_sample_consensus_release.dll" - "TargetName" = "8:pcl_sample_consensus_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_649E806B15714482A0FE9CF53E4E8DB8" - { - "SourcePath" = "8:..\\Kinect_Master_App\\App_Setting.xml" - "TargetName" = "8:App_Setting.xml" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_67CC69E12BB64619844D46096C1A4206" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_kdtree_release.dll" - "TargetName" = "8:pcl_kdtree_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_7497D8290CFC4B7086F77DBDE82E7764" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_visualization_release.dll" - "TargetName" = "8:pcl_visualization_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_87AF0F8C21EE44EC940C0D6D73A7FD74" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_io_ply_release.dll" - "TargetName" = "8:pcl_io_ply_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_93DE62CA59C04502A0D9C02E1FAEDEE2" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_features_release.dll" - "TargetName" = "8:pcl_features_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_9AF8C4E4CE1749CF8FB342A929C985DB" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_filters_release.dll" - "TargetName" = "8:pcl_filters_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_A2A1CB3B98F64806A3CD1263D0318D28" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_common_release.dll" - "TargetName" = "8:pcl_common_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_A36823C4359149DF90119715B56400D1" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_search_release.dll" - "TargetName" = "8:pcl_search_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_B133EB77F3EB44D3B0C78C891CE64522" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_octree_release.dll" - "TargetName" = "8:pcl_octree_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_BC2A9CF2501945149CA4424A9D1EB902" - { - "SourcePath" = "8:C:\\Program Files\\PCL 1.8.0\\bin\\pcl_io_release.dll" - "TargetName" = "8:pcl_io_release.dll" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - "{1FB2D0AE-D3B9-43D4-B9DD-F88EC61E35DE}:_E801C69C60644F069479862584A20DF4" - { - "SourcePath" = "8:..\\Kinect_Master_App\\kinect_master.ico" - "TargetName" = "8:kinect_master.ico" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - } - } - "FileType" - { - } - "Folder" - { - "{3C67513D-01DD-4637-8A68-80971EB9504F}:_3655CAEC822D4753B4613E7354390B76" - { - "DefaultLocation" = "8:[ProgramFiles64Folder][Manufacturer]\\[ProductName]" - "Name" = "8:#1925" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:TARGETDIR" - "Folders" - { - } - } - "{1525181F-901A-416C-8A58-119130FE478E}:_7B7A5C34542C4752B9F1FB4867578B27" - { - "Name" = "8:#1919" - "AlwaysCreate" = "11:FALSE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:ProgramMenuFolder" - "Folders" - { - } - } - "{1525181F-901A-416C-8A58-119130FE478E}:_E787B3294B4F45F2A6D65444236D22DD" - { - "Name" = "8:#1916" - "AlwaysCreate" = "11:TRUE" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Property" = "8:DesktopFolder" - "Folders" - { - } - } - } - "LaunchCondition" - { - } - "Locator" - { - } - "MsiBootstrapper" - { - "LangId" = "3:1033" - "RequiresElevation" = "11:FALSE" - } - "Product" - { - "Name" = "8:Microsoft Visual Studio" - "ProductName" = "8:Kinect Master App" - "ProductCode" = "8:{229E0596-9221-47C8-963E-3C8CB57D1604}" - "PackageCode" = "8:{EB7870FD-230B-4C26-9541-EF249F9D85DF}" - "UpgradeCode" = "8:{DF6BC90D-C914-454F-AA3E-B6F30B24D321}" - "AspNetVersion" = "8:4.0.30319.0" - "RestartWWWService" = "11:FALSE" - "RemovePreviousVersions" = "11:FALSE" - "DetectNewerInstalledVersion" = "11:TRUE" - "InstallAllUsers" = "11:TRUE" - "ProductVersion" = "8:1.0.0" - "Manufacturer" = "8:Shiseido" - "ARPHELPTELEPHONE" = "8:" - "ARPHELPLINK" = "8:" - "Title" = "8:Setup" - "Subject" = "8:" - "ARPCONTACT" = "8:Birdman" - "Keywords" = "8:" - "ARPCOMMENTS" = "8:" - "ARPURLINFOABOUT" = "8:" - "ARPPRODUCTICON" = "8:" - "ARPIconIndex" = "3:0" - "SearchPath" = "8:" - "UseSystemSearchPath" = "11:TRUE" - "TargetPlatform" = "3:1" - "PreBuildEvent" = "8:" - "PostBuildEvent" = "8:" - "RunPostBuildEvent" = "3:0" - } - "Registry" - { - "HKLM" - { - "Keys" - { - "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_3174E90A210944BD9E01B583D88CC77D" - { - "Name" = "8:Software" - "Condition" = "8:" - "AlwaysCreate" = "11:FALSE" - "DeleteAtUninstall" = "11:FALSE" - "Transitive" = "11:FALSE" - "Keys" - { - "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_B7787BB6A6354F048071FF76FF00EEFD" - { - "Name" = "8:[Manufacturer]" - "Condition" = "8:" - "AlwaysCreate" = "11:FALSE" - "DeleteAtUninstall" = "11:FALSE" - "Transitive" = "11:FALSE" - "Keys" - { - } - "Values" - { - } - } - } - "Values" - { - } - } - } - } - "HKCU" - { - "Keys" - { - "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_7D68E40757FD4109865BB71C35B72526" - { - "Name" = "8:Software" - "Condition" = "8:" - "AlwaysCreate" = "11:FALSE" - "DeleteAtUninstall" = "11:FALSE" - "Transitive" = "11:FALSE" - "Keys" - { - "{60EA8692-D2D5-43EB-80DC-7906BF13D6EF}:_060CD4C4392D4F09BBDA6384EF985B62" - { - "Name" = "8:[Manufacturer]" - "Condition" = "8:" - "AlwaysCreate" = "11:FALSE" - "DeleteAtUninstall" = "11:FALSE" - "Transitive" = "11:FALSE" - "Keys" - { - } - "Values" - { - } - } - } - "Values" - { - } - } - } - } - "HKCR" - { - "Keys" - { - } - } - "HKU" - { - "Keys" - { - } - } - "HKPU" - { - "Keys" - { - } - } - } - "Sequences" - { - } - "Shortcut" - { - "{970C0BB2-C7D0-45D7-ABFA-7EC378858BC0}:_0439CD0D1F604ED1B544FFDF3D3F6555" - { - "Name" = "8:Kinect_Master_App" - "Arguments" = "8:" - "Description" = "8:" - "ShowCmd" = "3:1" - "IconIndex" = "3:0" - "Transitive" = "11:FALSE" - "Target" = "8:_4DE7D7A12FF4499482F1001A0E6A5C38" - "Folder" = "8:_E787B3294B4F45F2A6D65444236D22DD" - "WorkingFolder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Icon" = "8:_E801C69C60644F069479862584A20DF4" - "Feature" = "8:" - } - } - "UserInterface" - { - "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_22AFC404A8914BC095B0B300F4399D3F" - { - "Name" = "8:#1901" - "Sequence" = "3:2" - "Attributes" = "3:2" - "Dialogs" - { - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_7DB081B8BCC64F5AAE2F28E49B9806FA" - { - "Sequence" = "3:100" - "DisplayName" = "8:騾イ陦檎憾豕" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdAdminProgressDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - "ShowProgress" - { - "Name" = "8:ShowProgress" - "DisplayName" = "8:#1009" - "Description" = "8:#1109" - "Type" = "3:5" - "ContextData" = "8:1;True=1;False=0" - "Attributes" = "3:0" - "Setting" = "3:0" - "Value" = "3:1" - "DefaultValue" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - } - } - "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_3E6DE26E578348319EC88934B76CDDEE" - { - "Name" = "8:#1902" - "Sequence" = "3:1" - "Attributes" = "3:3" - "Dialogs" - { - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_C548233869BB4C5FB439D532176767A6" - { - "Sequence" = "3:100" - "DisplayName" = "8:螳御コ" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdFinishedDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - "UpdateText" - { - "Name" = "8:UpdateText" - "DisplayName" = "8:#1058" - "Description" = "8:#1158" - "Type" = "3:15" - "ContextData" = "8:" - "Attributes" = "3:0" - "Setting" = "3:1" - "Value" = "8:#1258" - "DefaultValue" = "8:#1258" - "UsePlugInResources" = "11:TRUE" - } - } - } - } - } - "{2479F3F5-0309-486D-8047-8187E2CE5BA0}:_7912B05A21E9490B98D5C2345EAE335A" - { - "UseDynamicProperties" = "11:FALSE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdUserInterface.wim" - } - "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_98F7B80BEE6D4A1D88C1C04414B3ADBA" - { - "Name" = "8:#1900" - "Sequence" = "3:2" - "Attributes" = "3:1" - "Dialogs" - { - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_58612212A8FD4C04928AB56883DE147D" - { - "Sequence" = "3:200" - "DisplayName" = "8:繧、繝ウ繧ケ繝医シ繝ォ 繝輔か繝ォ繝繝シ" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdAdminFolderDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_98F93A7C070E461DA3811E403F85D513" - { - "Sequence" = "3:300" - "DisplayName" = "8:繧、繝ウ繧ケ繝医シ繝ォ縺ョ遒コ隱" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdAdminConfirmDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_D43E240A6C8A418C8FA709E5C6D3F013" - { - "Sequence" = "3:100" - "DisplayName" = "8:繧医≧縺薙◎" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdAdminWelcomeDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - "CopyrightWarning" - { - "Name" = "8:CopyrightWarning" - "DisplayName" = "8:#1002" - "Description" = "8:#1102" - "Type" = "3:3" - "ContextData" = "8:" - "Attributes" = "3:0" - "Setting" = "3:1" - "Value" = "8:#1202" - "DefaultValue" = "8:#1202" - "UsePlugInResources" = "11:TRUE" - } - "Welcome" - { - "Name" = "8:Welcome" - "DisplayName" = "8:#1003" - "Description" = "8:#1103" - "Type" = "3:3" - "ContextData" = "8:" - "Attributes" = "3:0" - "Setting" = "3:1" - "Value" = "8:#1203" - "DefaultValue" = "8:#1203" - "UsePlugInResources" = "11:TRUE" - } - } - } - } - } - "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_C29352808311445682C0CF9E3065C5E3" - { - "Name" = "8:#1902" - "Sequence" = "3:2" - "Attributes" = "3:3" - "Dialogs" - { - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_325FDC7AB7794C0EA016F96E11D18B60" - { - "Sequence" = "3:100" - "DisplayName" = "8:螳御コ" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdAdminFinishedDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - } - } - "{2479F3F5-0309-486D-8047-8187E2CE5BA0}:_D7F832E5131C49CF8398326288398140" - { - "UseDynamicProperties" = "11:FALSE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdBasicDialogs.wim" - } - "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_D9929878FA45427FA51335D4635EE9EB" - { - "Name" = "8:#1901" - "Sequence" = "3:1" - "Attributes" = "3:2" - "Dialogs" - { - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_2D33355FB53D40DFBADBBCBDD219ED1E" - { - "Sequence" = "3:100" - "DisplayName" = "8:騾イ陦檎憾豕" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdProgressDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - "ShowProgress" - { - "Name" = "8:ShowProgress" - "DisplayName" = "8:#1009" - "Description" = "8:#1109" - "Type" = "3:5" - "ContextData" = "8:1;True=1;False=0" - "Attributes" = "3:0" - "Setting" = "3:0" - "Value" = "3:1" - "DefaultValue" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - } - } - "{DF760B10-853B-4699-99F2-AFF7185B4A62}:_E261F25BD0A74320A01B4D0929FD3AC7" - { - "Name" = "8:#1900" - "Sequence" = "3:1" - "Attributes" = "3:1" - "Dialogs" - { - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_063A2D39A2914D39813B7FEB70CB1645" - { - "Sequence" = "3:200" - "DisplayName" = "8:繧、繝ウ繧ケ繝医シ繝ォ 繝輔か繝ォ繝繝シ" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdFolderDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - "InstallAllUsersVisible" - { - "Name" = "8:InstallAllUsersVisible" - "DisplayName" = "8:#1059" - "Description" = "8:#1159" - "Type" = "3:5" - "ContextData" = "8:1;True=1;False=0" - "Attributes" = "3:0" - "Setting" = "3:0" - "Value" = "3:1" - "DefaultValue" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_0B5E665B0F104F0AAFCC1AE923F2AEBF" - { - "Sequence" = "3:300" - "DisplayName" = "8:繧、繝ウ繧ケ繝医シ繝ォ縺ョ遒コ隱" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdConfirmDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - } - } - "{688940B3-5CA9-4162-8DEE-2993FA9D8CBC}:_BCFD9B719A574643B51B567D15776A2C" - { - "Sequence" = "3:100" - "DisplayName" = "8:繧医≧縺薙◎" - "UseDynamicProperties" = "11:TRUE" - "IsDependency" = "11:FALSE" - "SourcePath" = "8:\\VsdWelcomeDlg.wid" - "Properties" - { - "BannerBitmap" - { - "Name" = "8:BannerBitmap" - "DisplayName" = "8:#1001" - "Description" = "8:#1101" - "Type" = "3:8" - "ContextData" = "8:Bitmap" - "Attributes" = "3:4" - "Setting" = "3:1" - "UsePlugInResources" = "11:TRUE" - } - "CopyrightWarning" - { - "Name" = "8:CopyrightWarning" - "DisplayName" = "8:#1002" - "Description" = "8:#1102" - "Type" = "3:3" - "ContextData" = "8:" - "Attributes" = "3:0" - "Setting" = "3:1" - "Value" = "8:#1202" - "DefaultValue" = "8:#1202" - "UsePlugInResources" = "11:TRUE" - } - "Welcome" - { - "Name" = "8:Welcome" - "DisplayName" = "8:#1003" - "Description" = "8:#1103" - "Type" = "3:3" - "ContextData" = "8:" - "Attributes" = "3:0" - "Setting" = "3:1" - "Value" = "8:#1203" - "DefaultValue" = "8:#1203" - "UsePlugInResources" = "11:TRUE" - } - } - } - } - } - } - "MergeModule" - { - } - "ProjectOutput" - { - "{5259A561-127C-4D43-A0A1-72F10C7B3BF8}:_4DE7D7A12FF4499482F1001A0E6A5C38" - { - "SourcePath" = "8:..\\x64\\Release\\Kinect_Master_App.exe" - "TargetName" = "8:" - "Tag" = "8:" - "Folder" = "8:_3655CAEC822D4753B4613E7354390B76" - "Condition" = "8:" - "Transitive" = "11:FALSE" - "Vital" = "11:TRUE" - "ReadOnly" = "11:FALSE" - "Hidden" = "11:FALSE" - "System" = "11:FALSE" - "Permanent" = "11:FALSE" - "SharedLegacy" = "11:FALSE" - "PackageAs" = "3:1" - "Register" = "3:1" - "Exclude" = "11:FALSE" - "IsDependency" = "11:FALSE" - "IsolateTo" = "8:" - "ProjectOutputGroupRegister" = "3:1" - "OutputConfiguration" = "8:" - "OutputGroupCanonicalName" = "8:Built" - "OutputProjectGuid" = "8:{37A909D9-C814-47B0-9A85-92227F2C8B59}" - "ShowKeyOutput" = "11:TRUE" - "ExcludeFilters" - { - } - } - } - } -}