gstreamer
Loading...
Searching...
No Matches
frameHeader.cc
Go to the documentation of this file.
1// gstreamer
4
5// Implementation summary:
6// Append the frame header block to the JSON object currently being assembled.
7
8bool GstreamerJsonFactory::publishFrameHeaderImpl(const GFrameHeader* gframeHeader) {
9 if (!is_building_frame) {
10 log->error(
12 "publishFrameHeaderImpl called without an active frame in GstreamerJsonFactory");
13 return false;
14 }
15 if (!gframeHeader) {
16 log->error(
18 "gframeHeader is null in GstreamerJsonFactory::publishFrameHeaderImpl");
19 return false;
20 }
21
22 current_frame << "\"header\": {"
23 << "\"frame_id\": " << gframeHeader->getFrameID()
24 << "}";
25
26 current_frame_has_header = true;
27 return true;
28}
std::shared_ptr< GLogger > log
long int getFrameID() const
Shared constants and error codes for the gstreamer module.
JSON streamer plugin declarations.
constexpr int ERR_PUBLISH_ERROR
Publish sequence encountered invalid state or invalid input data.