setIndex( index ) {

		if ( Array.isArray( index ) ) {

			this.index = new ( arrayNeedsUint32( index ) ? Uint32BufferAttribute : Uint16BufferAttribute )( index, 1 );

		} else {

			this.index = index;

		}

		return this;

	}
Sets the given index to this geometry.

@param {Array<number>|BufferAttribute} index - The index to set.
@return {BufferGeometry} A reference to this instance.