diff --git a/interfaces/api/pointCloud/IPCProjectOntoImage.h b/interfaces/api/pointCloud/IPCProjectOntoImage.h index 2fb984b8..44376c9c 100644 --- a/interfaces/api/pointCloud/IPCProjectOntoImage.h +++ b/interfaces/api/pointCloud/IPCProjectOntoImage.h @@ -52,6 +52,17 @@ class XPCF_IGNORE IPCProjectOntoImage : virtual public org::bcom::xpcf::ICompone const SolAR::datastructure::Transform3Df& pose, SRef& image) const = 0; + /// @brief Project a list of cloud points onto an image plane + /// @param[in] points the list of cloud points + /// @param[in] cameraParameters the camera parameters + /// @param[in] pose the camera pose + /// @param[out] image output image created from the point cloud + /// @return FrameworkReturnCode::_SUCCESS (pointcloud projected onto image successfully) otherwise FrameworkReturnCode::_ERROR_ (failure) + virtual FrameworkReturnCode project(const std::vector>& points, + SRef cameraParameters, + const SolAR::datastructure::Transform3Df& pose, + SRef& image) const = 0; + }; } } diff --git a/interfaces/api/pointCloud/IPCSemanticFrom2D.h b/interfaces/api/pointCloud/IPCSemanticFrom2D.h index 37cbafd3..66b93a7f 100644 --- a/interfaces/api/pointCloud/IPCSemanticFrom2D.h +++ b/interfaces/api/pointCloud/IPCSemanticFrom2D.h @@ -29,6 +29,16 @@ namespace SolAR { namespace api { namespace pointCloud { +/** + * @struct SemanticId + * @brief struct used to represent semantic Id of a cloud point + */ +struct SemanticId { + SemanticId(int16_t i, float conf) : id(i), confidence(conf) {} + int16_t id; + float confidence; +}; + /** * @class IPCSemanticFrom2D * @brief Estimate semantic Ids of cloud points from 2D information. @@ -53,6 +63,19 @@ class XPCF_IGNORE IPCSemanticFrom2D : virtual public org::bcom::xpcf::IComponent SRef keyframeCollection, SRef cameraParametersCollection, SRef maskCollection) const = 0; + + /// @brief Estimate point cloud semantic Ids from a keyframe collection and a mask collection + /// @param[in] points list of cloud points + /// @param[in] keyframeCollection input list of keyframes + /// @param[in] cameraParametersCollection input list of camera parameters + /// @param[in] maskCollection input list of masks + /// @param[out] semanticIds the estimated possible semantic ids for each input cloud point + /// @return FrameworkReturnCode::_SUCCESS (semantic id estimated successfully) otherwise FrameworkReturnCode::_ERROR_ (failure) + virtual FrameworkReturnCode estimate(const std::vector>& points, + SRef keyframeCollection, + SRef cameraParametersCollection, + SRef maskCollection, + std::vector>& semanticIds) const = 0; }; }