start porting functions to emgu