video window position calculation fixed