void computeSegmentEnergy ( GrowQueue_I32 corners ) { if ( energySegment . length < corners . size ( ) ) { energySegment = new double [ corners . size ( ) ] ; } for ( int i = 0 , j = corners . size ( ) - 1 ; i < corners . size ( ) ; j = i , i ++ ) { energySegment [ j ] = computeSegmentEnergy ( corners , j , i ) ; } }
Computes the energy of each segment individually