virtual inline bool popDepthMetaData( xn::DepthMetaData& depthMetaData ) { cv::Ptr<xn::DepthMetaData> depthPtr; bool isPop = depthQueue.try_pop(depthPtr); if( isPop ) depthMetaData.CopyFrom(*depthPtr); return isPop; }
virtual inline bool popDepthMetaData( xn::DepthMetaData& depthMetaData ) { if( depthQueue.empty() ) return false; depthMetaData.CopyFrom(*depthQueue.front()); depthQueue.pop(); return true; }
/** * @brief Gets a copy of the Color cv::Mat. * @details Gets a copy of the Color cv::Mat, if the Image Generator * (_image_generator) is active. * * @param[out] depth * Copy of the Image cv::Mat. * * @retval true if the cv::Mat was successfully copied. * @retval false if the generator is not active or some other error occurred. */ bool NIKinect::get_depth_meta_data(xn::DepthMetaData& depth){ if(this->_flags[NIKinect::DEPTH_G]){ depth.CopyFrom(this->_depth_md); return true; } else{ return false; } }