Fix setting castShadow property on threejs objects.
Add resetViewport event to fix blank screen issue when shadows are enabled.

Refs #2567