Well the photo is proof that it can be done!
But it is wrong! For starters it needs to be 3' of more above the roof in most cases (depends on size of pipe and slope). Then we can talk about the basement window and the window above the vent termination.