ArMemToImage.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <memory>
4 #include <vector>
5 
6 #include <Eigen/Core>
7 
11 
14 
15 namespace visionx::armem_images
16 {
17 
19  {
20  public:
21  ArMemToImage();
22 
23  void addImagesRGB(const armarx::armem::MemoryID& entityID,
24  const std::vector<size_t>& imageIndices) override;
25  void addImagesDepth(const armarx::armem::MemoryID& entityID,
26  const std::vector<size_t>& imageIndices) override;
27 
28  armarx::armem::MemoryID getMemoryID() const override;
29  Eigen::Vector2i getImageDimensions() const;
30 
31  std::string summarizeStructure() const override;
32  std::string printFormats() const;
33 
34 
35  void fetchUpdates(const armarx::armem::MemoryID& entityID,
36  const std::vector<armarx::armem::MemoryID>& updatedSnapshotIDs);
37 
39 
40 
41  private:
42  template <class AronImageT>
43  void addImages(const armarx::armem::MemoryID& entityID,
44  const std::vector<size_t>& imageIndices);
45 
46  void updateAronImages(const armarx::armem::wm::Memory& memory);
47 
48 
49  public:
51 
52  std::vector<std::unique_ptr<ImageBase>> images;
54  bool updated;
55  };
56 
57 } // namespace visionx::armem_images
visionx::armem_images::ArMemToImage::ArMemToImage
ArMemToImage()
Definition: ArMemToImage.cpp:18
visionx::armem_images::ArMemToImage::timestamp
armarx::armem::Time timestamp
Definition: ArMemToImage.h:53
armarx::armem::client::Reader
Reads data from a memory server.
Definition: Reader.h:24
Reader.h
visionx::armem_images::ArMemToImage::memoryReader
armarx::armem::client::Reader memoryReader
Definition: ArMemToImage.h:50
ImageAdapter.h
MemoryID.h
Image.h
visionx::armem_images::ArMemToImage::getMemoryID
armarx::armem::MemoryID getMemoryID() const override
Definition: ArMemToImage.cpp:53
armarx::armem::client::QueryResult
Result of a QueryInput.
Definition: Query.h:50
visionx::armem_images::ArMemToImage::updated
bool updated
Definition: ArMemToImage.h:54
visionx::armem_images
Definition: ImageReader.cpp:29
armarx::armem::MemoryID
A memory ID.
Definition: MemoryID.h:47
visionx::armem_images::ArMemToImage::addImagesRGB
void addImagesRGB(const armarx::armem::MemoryID &entityID, const std::vector< size_t > &imageIndices) override
Definition: ArMemToImage.cpp:41
armarx::armem::wm::Memory
Client-side working memory.
Definition: memory_definitions.h:133
visionx::armem_images::ArMemToImage::summarizeStructure
std::string summarizeStructure() const override
Definition: ArMemToImage.cpp:103
visionx::armem_images::ArMemToImage::printFormats
std::string printFormats() const
Definition: ArMemToImage.cpp:149
memory_definitions.h
visionx::armem_images::ArMemToImage::fetchLatest
armarx::armem::client::QueryResult fetchLatest()
Definition: ArMemToImage.cpp:114
armarx::core::time::DateTime
Represents a point in time.
Definition: DateTime.h:24
visionx::armem_images::ArMemToImage::addImagesDepth
void addImagesDepth(const armarx::armem::MemoryID &entityID, const std::vector< size_t > &imageIndices) override
Definition: ArMemToImage.cpp:47
visionx::armem_images::ArMemToImage::getImageDimensions
Eigen::Vector2i getImageDimensions() const
Definition: ArMemToImage.cpp:65
visionx::armem_images::detail::ImageAdapter
Definition: ImageAdapter.h:13
visionx::armem_images::ArMemToImage::fetchUpdates
void fetchUpdates(const armarx::armem::MemoryID &entityID, const std::vector< armarx::armem::MemoryID > &updatedSnapshotIDs)
Definition: ArMemToImage.cpp:78
visionx::armem_images::ArMemToImage
Definition: ArMemToImage.h:18
visionx::armem_images::ArMemToImage::images
std::vector< std::unique_ptr< ImageBase > > images
Definition: ArMemToImage.h:52