title: Bad argument error while drawing border
body: <p>I am trying to draw border along with the image , I got good help from <a href="http://docs.opencv.org/doc/tutorials/imgproc/imgtrans/copyMakeBorder/copyMakeBorder.html" rel="nofollow noreferrer">opencv documentation</a> and also syntax from <a href="http://docs.opencv.org/modules/imgproc/doc/filtering.html?highlight=copymakeborder#copymakeborder" rel="nofollow noreferrer">here</a> and it work fine , i tried it in with this value </p>
  
  <pre><code>copyMakeBorder( src, dst, top, bottom, left, right, bordertype , Scalar(0,255,0) );
  </code></pre>
  
  <p>it works but when i try to use <a href="http://docs.opencv.org/modules/imgproc/doc/filtering.html?highlight=copymakeborder#int%20borderInterpolate%28int%20p,%20int%20len,%20int%20borderType%29" rel="nofollow noreferrer">borderinterpolation</a> to make borders constant like</p>
  
  <pre><code>int borderInterpolate = (50, 100, BORDER_TRANSPARENT);
  copyMakeBorder( src, dst, top, bottom, left, right, borderInterpolate , Scalar(0,255,0) );
  </code></pre>
  
  <p>it show me runtime error of </p>
  
  <pre><code>Bad argument (Unknown/Unsupportive border type)
  </code></pre>
  
  <p>and how to achieve this 3rd result also given in the documentation</p>
  
  <p><img src="https://i.stack.imgur.com/NclV5.jpg" alt="enter image description here"></p>