Skip to content

Commit

Permalink
Fixed compilation without RGBD module.
Browse files Browse the repository at this point in the history
  • Loading branch information
emgucv committed Jan 21, 2022
1 parent fdda95a commit 2d4cf5c
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 6 deletions.
32 changes: 26 additions & 6 deletions Emgu.CV.Extern/rgbd/rgbd_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
#include "rgbd_c.h"

cv::rgbd::Odometry* cveOdometryCreate(
cv::String* odometryType,
cv::Algorithm** algorithm,
cv::Ptr<cv::rgbd::Odometry>** sharedPtr
cv::String* odometryType,
cv::Algorithm** algorithm,
cv::Ptr<cv::rgbd::Odometry>** sharedPtr
)
{
#ifdef HAVE_OPENCV_RGBD
Expand Down Expand Up @@ -72,9 +72,9 @@ cv::rgbd::RgbdNormals* cveRgbdNormalsCreate(
cv::Ptr<cv::rgbd::RgbdNormals> odometry = cv::rgbd::RgbdNormals::create(
rows,
cols,
depth,
*K,
window_size,
depth,
*K,
window_size,
method);
*sharedPtr = new cv::Ptr<cv::rgbd::RgbdNormals>(odometry);
*algorithm = dynamic_cast<cv::Algorithm*>((*sharedPtr)->get());
Expand Down Expand Up @@ -256,4 +256,24 @@ void cveLinemodMatchRelease(cv::linemod::Match** match)
throw_no_rgbd();
#endif

}

cv::linemod::Modality* cveLinemodModalityCreate(cv::String* modalityType, cv::Ptr<cv::linemod::Modality>** sharedPtr)
{
#ifdef HAVE_OPENCV_RGBD
//TODO: Implement this.
#else
throw_no_rgbd();
#endif

}
void cveLinemodModalityRelease(cv::Ptr<cv::linemod::Modality>** sharedPtr)
{
#ifdef HAVE_OPENCV_RGBD
delete* sharedPtr;
*sharedPtr = 0;
#else
throw_no_rgbd();
#endif

}
7 changes: 7 additions & 0 deletions Emgu.CV.Extern/rgbd/rgbd_c.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@ namespace cv
class Odometry {};
class RgbdNormals {};
}

namespace linemod
{
class Detector {};
class Modality {};
struct Match {};
}
}

#endif
Expand Down

0 comments on commit 2d4cf5c

Please sign in to comment.