Add rotation and flip support
Restructure project