libcamera: request: Make metadata_ a class instance
The metadata_ member variable is a pointer, for no specific reason. Make it an instance and simplify the class constructor and destructor. Suggested-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com> Reviewed-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com> Reviewed-by: Daniel Scally <dan.scally@ideasonboard.com>
This commit is contained in:
@@ -36,7 +36,7 @@ public:
|
||||
Camera *camera() const { return camera_; }
|
||||
bool hasPendingBuffers() const;
|
||||
|
||||
ControlList &metadata() { return *metadata_; }
|
||||
ControlList &metadata() { return metadata_; }
|
||||
|
||||
bool completeBuffer(FrameBuffer *buffer);
|
||||
void complete();
|
||||
@@ -63,7 +63,7 @@ private:
|
||||
std::unordered_set<FrameBuffer *> pending_;
|
||||
std::map<FrameBuffer *, EventNotifier> notifiers_;
|
||||
std::unique_ptr<Timer> timer_;
|
||||
ControlList *metadata_;
|
||||
ControlList metadata_;
|
||||
};
|
||||
|
||||
} /* namespace libcamera */
|
||||
|
||||
Reference in New Issue
Block a user