title: Convert GLfloat [] array to GLfloat * array
body: <p>Is there a quicker way to convert the following data into a c style pointer array?</p>
  
  <pre><code>GLfloat verticalLines [] = {
  0.59, 0.66, 0.0,    
  0.59, -0.14, 0.0
  }
  </code></pre>
  
  <p>My current approach is to manually iterate over the data using the method below:</p>
  
  <pre><code>-(GLfloat *)updateLineVertices{
  
  int totalVertices = 6;
  GLfloat *lineVertices =  (GLfloat *)malloc(sizeof(GLfloat) * (totalVertices));
  
  for (int i = 0; i&lt;totalVertices; i++) {
      lineVertices[i] = verticalLines[i];
  }
  
  return lineVertices;
  }
  </code></pre>
  
  <p>Some additional info.
  Ultimately I will need the data in a format which can be easily manipulated, for example:</p>
  
  <pre><code>-(void)scaleLineAnimation{
  GLfloat *lineVertices = [self updateLineVertices];
  for (int i = 0; i&lt;totalVertices; i+=3) {
       lineVertices[i+1] += 0.5; //scale y axis
  }
  }
  </code></pre>