OSVR-Core
EdgeHoleBlobExtractor.h
Go to the documentation of this file.
1 
11 // Copyright 2016 Sensics, Inc.
12 //
13 // Licensed under the Apache License, Version 2.0 (the "License");
14 // you may not use this file except in compliance with the License.
15 // You may obtain a copy of the License at
16 //
17 // http://www.apache.org/licenses/LICENSE-2.0
18 //
19 // Unless required by applicable law or agreed to in writing, software
20 // distributed under the License is distributed on an "AS IS" BASIS,
21 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22 // See the License for the specific language governing permissions and
23 // limitations under the License.
24 
25 #ifndef INCLUDED_EdgeHoleBlobExtractor_h_GUID_31496B1F_52D8_4BBC_A7FA_3F81E68C2A47
26 #define INCLUDED_EdgeHoleBlobExtractor_h_GUID_31496B1F_52D8_4BBC_A7FA_3F81E68C2A47
27 
28 // Internal Includes
29 #include "BlobParams.h"
31 #include "GenericBlobExtractor.h"
32 #include "LedMeasurement.h"
33 
34 // Library/third-party includes
35 // - none
36 
37 // Standard includes
38 // - none
39 
40 namespace osvr {
41 namespace vbtracker {
43  public:
44  EdgeHoleBlobExtractor(BlobParams const &blobParams,
45  EdgeHoleParams const &extParams);
46  ~EdgeHoleBlobExtractor() override = default;
47 
48  protected:
49  cv::Mat generateDebugThresholdImage_() const override;
50  cv::Mat generateDebugBlobImage_() const override;
51  LedMeasurementVec extractBlobs_() override;
52 
53  private:
54  BlobParams m_params;
55  EdgeHoleBasedLedExtractor m_extractor;
56  };
57 
59  BlobExtractorPtr makeEdgeHoleBlobExtractor(BlobParams const &blobParams,
60  EdgeHoleParams const &extParams);
61 
64  inline BlobExtractorPtr makeBlobExtractor(BlobParams const &blobParams,
65  EdgeHoleParams const &extParams) {
66  return makeEdgeHoleBlobExtractor(blobParams, extParams);
67  }
68 } // namespace vbtracker
69 } // namespace osvr
70 #endif // INCLUDED_EdgeHoleBlobExtractor_h_GUID_31496B1F_52D8_4BBC_A7FA_3F81E68C2A47
Definition: EdgeHoleBasedLedExtractor.h:70
The main namespace for all C++ elements of the framework, internal and external.
Definition: namespace_osvr.dox:3
Definition: BlobParams.h:93
BlobExtractorPtr makeBlobExtractor(BlobParams const &blobParams, EdgeHoleParams const &extParams)
If passing an EdgeHoleParams object, then call the EdgeHoldBlobExtractor factory. ...
Definition: EdgeHoleBlobExtractor.h:64
Blob detection configuration parameters.
Definition: BlobParams.h:40
BlobExtractorPtr makeEdgeHoleBlobExtractor(BlobParams const &blobParams, EdgeHoleParams const &extParams)
Factory for EdgeHoleBlobExtractor objects.
Definition: EdgeHoleBlobExtractor.cpp:56
This is an interface/base class for blob extractors that have the ability to provide graphical debug ...
Definition: GenericBlobExtractor.h:43
Definition: EdgeHoleBlobExtractor.h:42
Header.