added vertex indexing.