ERROR from src_bin_muxer: Output width not set

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU)
GPU
• DeepStream Version
5.0
• JetPack Version (valid for Jetson only)
• TensorRT Version
7.0
• NVIDIA GPU Driver Version (valid for GPU only)
440
• Issue Type( questions, new requirements, bugs)
question

I have already read the posted issue with this similar topic, and found no help.
I followed this https://github.com/NVIDIA-AI-IOT/deepstream-occupancy-analytics, and try to convert Makefile to CMakelist, everything worked quite well.
Then I followed this repo: https://github.com/DanaHan/Yolov5-in-Deepstream-5.0
it also worked with deepstream-app command. But it failed when I used CMakelist.

ERROINFO:
** ERROR: main:655: Failed to set pipeline to PAUSED
Quitting
ERROR from src_bin_muxer: Output width not set
Debug info: gstnvstreammux.c(2283): gst_nvstreammux_change_state (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstNvStreamMux:src_bin_muxer
App run failed

What possibilities could cause this error?

This error happens when the pipeline is wrong. E.g. the nvstreammux is not connected with src or sink, the properties of the plugins is set to wrong value, …

solved by fix custom plugin