Enabled depth buffering implemented rendering using an index buffer instead of a vertex buffer.