Split capture.cpp on win
Add flip to win version