title: double pointer and how to modify the pointer in the function
body: <p>in this example from opencv, why didn't we create a simple variable img (instead of a pointer) and then use a simple pointer in the parameter of the function <code>cvReleaseImage</code> (whereas here, we will use a double pointer in the parameter because we're passing the address of the pointer : <code>&amp;img</code>) :</p>
  
  <pre><code>IplImage* img = NULL; 
  img = cvLoadImage(argv[1], CV_LOAD_IMAGE_UNCHANGED);
  cvReleaseImage (&amp;img);
  </code></pre>
  
  <p>?</p>
  
  <p>Also, when we use a simple pointer in a function, we can change the pointed value by adding another <code>*</code> to the pointer :</p>
  
  <p>for example :</p>
  
  <pre><code>function random(int* pointer, int* pointer2){
      *pointer = *pointer2 / 2;
  }
  </code></pre>
  
  <p>so with a double pointer, should we do this? :</p>
  
  <pre><code>function random(int** doublepointer, int* pointer2){
      **doublepointer = *pointer2 / 2;
  }
  </code></pre>
  
  <p>Thanks for your help</p>