Currently, nvdspreprocess does not support setting polygon roi.
Can you share the reason? Maybe there is another workaround. if you want to do roi-filtering or Overcrowding Detection, nvdsanalytic 1 plugin already supports polygon setting.
If you plan to use nvdsanalytics, please refer to /opt/nvidia/deepstream/deepstream/sources/apps/sample_apps/deepstream-nvdsanalytics-test/deepstream_nvdsanalytics_meta.cpp, The ROI will be attached to NvDsAnalyticsFrameMeta.
The parse_nvdsanalytics_meta_data function in /opt/nvidia/deepstream/deepstream/sources/apps/sample_apps/deepstream-nvdsanalytics-test/deepstream_nvdsanalytics_meta.cpp.
The user meta data type is NVDS_USER_FRAME_META_NVDSANALYTICS
Sorry, It looks like some information is missing from NvDsAnalyticsFrameMeta, This is a issues.
Other options can be considered.
1.Parse config_nvdsanalytics.txt when you need to get ROI
2.nvdsanalytics is opensource, add the ROI coordinate to framemata in function attach_framemeta_analytics_metadata.
There is no update from you for a period, assuming this is not an issue anymore. Hence we are closing this topic. If need further support, please open a new one. Thanks