Most consise viewport logic. Add viewport example file.