title: OpenCV VideoCapture Not Opening
body: <p>I'm trying to use OpenCV's cv2 python bindings on an Amazon server running Ubuntu 14.04 and I can't seem to get VideoCapture to work properly.</p>
  
  <p>I tried opening the default capture as follows:</p>
  
  <pre><code>import cv2
  cap = cv2.VideoCapture(0)
  cap.isOpened() #Returns false
  </code></pre>
  
  <p>I tested this on my local machine and it was true as expected, so there is something wrong with my open CV configuration. I've tried a variety of things:</p>
  
  <ul>
  <li>Using an actual filepath that I confirmed points to an .mp4 file</li>
  <li>Using -1 and 1 in place of 0 on the second line</li>
  <li>Installing ffmpeg (from a ppa as it isn't available by default on Ubuntu 14.04) and rebuilding OpenCV</li>
  <li>Removing my OpenCV directory entirely and rebuilding using the script <a href="https://help.ubuntu.com/community/OpenCV" rel="noreferrer">here</a></li>
  <li>Verifying and reinstalling various other libraries including x264, gstreamer, and gtk</li>
  </ul>
  
  <p>I'm kind of out of ideas at this point. Any ideas of what could be going wrong?</p>
  
  <p>Edit: OpenCV version is 2.4.9.</p>