protected void createSamplePoints ( int numSamples ) { for ( int y = 0 ; y < numSamples ; y ++ ) { float regionY = ( y / ( numSamples - 1.0f ) - 0.5f ) ; for ( int x = 0 ; x < numSamples ; x ++ ) { float regionX = ( x / ( numSamples - 1.0f ) - 0.5f ) ; samplePts . add ( new Point2D_F32 ( regionX , regionY ) ) ; } } }
create the list of points in square coordinates that it will sample . values will range from - 0 . 5 to 0 . 5 along each axis .