Fixing bug in tiling logic, which gave wrong overall extent