|
nx_server_plugin_sdk
1.0
Server Plugin SDK
|
#include <data.h>
Public Member Functions | |
| Motion (const char *jsonData) noexcept(false) | |
| Motion (const nx::kit::Json &json) noexcept(false) | |
| template<typename T > | |
| Motion (const T &)=delete | |
| bool | operator== (const Motion &) const |
| nx::kit::Json | to_json () const |
Static Public Member Functions | |
| static ValueOrError< Motion > | fromJson (const char *jsonStr) noexcept |
| static ValueOrError< Motion > | fromJson (const nx::kit::Json &json) noexcept |
Public Attributes | |
| int | channel = 0 |
| std::chrono::milliseconds | startTimestamp |
| std::chrono::milliseconds | duration {} |
| std::string | deviceId |
| std::string | dataBase64 |
The Motion object passed to the plugin when bookmark is saved. And the same object should be returned to the Server when queried back if it matches the filter. Plugin should keep motion as is, without any changes.
| std::string nx::sdk::cloud_storage::Motion::dataBase64 |
Binary motion mask data. Encoded in base64.
This mask covers the frame as a 44x32 cells grid. Every non zero bit in the mask means that motion was detected in that cell. So, the bit mask size is 44 * 32 = 1408 bits = 176 bytes before encoding to base64. The mask is rotated by 90 degree. The very first bit of the mask is the top-left corner bit. The next bit is for 1st column, 2nd row, etc.
1.8.14