Finish up
This commit is contained in:
parent
5efbdcbd6a
commit
0c466644ce
23 changed files with 958 additions and 154 deletions
|
|
@ -41,6 +41,17 @@ std::vector<cam::Camera::Description> Cameras::getCameras()
|
|||
return desc;
|
||||
}
|
||||
|
||||
std::shared_ptr<Camera> Cameras::getCamera(size_t id)
|
||||
{
|
||||
std::vector<cam::Camera::Description> desc = getCameras();
|
||||
for(size_t i = 0; i < desc.size(); ++i)
|
||||
{
|
||||
if(desc[i].getHash() == id)
|
||||
return cameras_[i];
|
||||
}
|
||||
return std::shared_ptr<Camera>(nullptr);
|
||||
}
|
||||
|
||||
bool Cameras::addCamera(const cam::Camera::Description& desc)
|
||||
{
|
||||
cameras_.push_back(std::shared_ptr<Camera>(new Camera(desc)));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue