Add payload generation library to nvmsgconv
This commit is contained in:
parent
e81b19d491
commit
0a4f85859d
@ -56,6 +56,7 @@
|
||||
},
|
||||
"msgconv": {
|
||||
"msgconv_config_file": "../data/nvmsgconv_configs/msgconv_config.txt",
|
||||
"payload_generation_library": "../data/nvmsgconv_configs/libnvds_msgconv.so",
|
||||
"msgconv_frame_interval": 30
|
||||
},
|
||||
"msgbroker": {
|
||||
|
||||
BIN
data/nvmsgconv_configs/libnvds_msgconv.so
Executable file
BIN
data/nvmsgconv_configs/libnvds_msgconv.so
Executable file
Binary file not shown.
@ -5,10 +5,14 @@ NvMessageConverter::NvMessageConverter() {
|
||||
|
||||
msgconv_config_file = config["msgconv"]["msgconv_config_file"];
|
||||
frame_interval = config["msgconv"]["msgconv_frame_interval"];
|
||||
payload_generation_library =
|
||||
config["msgconv"]["payload_generation_library"];
|
||||
}
|
||||
|
||||
bool NvMessageConverter::create_message_converter() {
|
||||
msgconv = gst_element_factory_make("nvmsgconv", "nvmsg-converter");
|
||||
g_object_set(G_OBJECT(msgconv), "msg2p-lib", payload_generation_library,
|
||||
NULL);
|
||||
g_object_set(G_OBJECT(msgconv), "config", msgconv_config_file, NULL);
|
||||
g_object_set(G_OBJECT(msgconv), "payload-type", 0,
|
||||
NULL); // 0 = DeepStream schema, 1 = minimal schema
|
||||
|
||||
@ -9,6 +9,7 @@ class NvMessageConverter {
|
||||
private:
|
||||
public:
|
||||
gint frame_interval;
|
||||
std::string payload_generation_library;
|
||||
GstElement *msgconv = NULL;
|
||||
std::string msgconv_config_file;
|
||||
NvMessageConverter();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user