2011-07-13 57 views

回答

9

我做到了simply.Just下載EyeOpen圖書館使用問題here。 然後用它在你的C#類,並寫:

use eyeopen.imaging.processing 

ComparableImage cc; 

ComparableImage pc; 

int sim; 

void compare(object sender, EventArgs e){ 
    pc = new ComparableImage(new FileInfo(files)); 
    cc = new ComparableImage(new FileInfo(file)); 

    pc.CalculateSimilarity(cc); 
    sim = pc.CalculateSimilarity(cc); 

    int sim2 = sim*100 

    Messagebox.show(sim2 + "% similar"); 

} 
+0

這是一個恥辱,公開API只暴露了一個帶'FileInfo'參數的構造函數。儘管如此,源碼可用。 – nawfal

+0

輝煌,謝謝! int應該是一個double。 – BjarkeCK