Fixed some rendering speed bottlenecks

Fixed some rendering speed bottlenecks: e.g. using GetType within
RenderObject was causing unnecessary slowdowns.