title: Error capturing video using C++, Opencv and GStreamer
body: <p>I have recently compiled Opencv 4.2.0 with Gstreamer 1.15.1 on 32-bit Windows platform. When I try to capture a Video using Gstreamer backend the video capture fails. Here is the code and output:  </p>
  
  <pre><code>void main()
  {
      VideoCapture cap("video/x-raw,format=YUV2,width=640,height=480,framerate=30/1 ! appsink", CAP_GSTREAMER);
     //VideoCapture cap(0,CAP_GSTREAMER);
      if (!cap.isOpened())
      {
          cout &lt;&lt; "VideoCapture not opened" &lt;&lt; endl;
          exit(-1);
      }
  
      Mat frame;
  
      while (true) {
  
          cap.read(frame);
  
          if (frame.empty())
              break;
  
          imshow("output", frame);
          if (waitKey(1) == 's')
              break;
      }
      destroyWindow("output");
  }
  </code></pre>
  
  <p>Here is the output :</p>
  
  <pre><code>(testNewOpencv.exe:7392): GStreamer-CRITICAL **: 20:08:16.574: gst_element_make_
  from_uri: assertion 'gst_uri_is_valid (uri)' failed
  [ WARN:0] global \modules\videoio\src\cap_gstreamer.cpp (713) cv::GStreamerCapture::open OpenCV | GStreamer warning: Error opening bin: no element "video"
  [ WARN:0] global \modules\videoio\src\cap_gstreamer.cpp (480) cv::GStreamerCapture::isPipelinePlaying OpenCV | GStreamer warning: GStreamer: pipeline have not been created
  VideoCapture not opened
  </code></pre>
  
  <p>Any suggestions on resolving the issue?</p>