Made rendering more efficient