optimization for render