setupViewport method