當前位置: 首頁>>代碼示例>>Java>>正文


Java Surf.getFreeOrientedInterestPoints方法代碼示例

本文整理匯總了Java中com.stromberglabs.jopensurf.Surf.getFreeOrientedInterestPoints方法的典型用法代碼示例。如果您正苦於以下問題:Java Surf.getFreeOrientedInterestPoints方法的具體用法?Java Surf.getFreeOrientedInterestPoints怎麽用?Java Surf.getFreeOrientedInterestPoints使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在com.stromberglabs.jopensurf.Surf的用法示例。


在下文中一共展示了Surf.getFreeOrientedInterestPoints方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: createDescriptorFields

import com.stromberglabs.jopensurf.Surf; //導入方法依賴的package包/類
@Override
public Field[] createDescriptorFields(BufferedImage image) {
    Field[] result = null;
    Surf s = new Surf(image);
    List<SURFInterestPoint> interestPoints = s.getFreeOrientedInterestPoints();
    result = new Field[interestPoints.size()];
    int count = 0;
    for (Iterator<SURFInterestPoint> sipi = interestPoints.iterator(); sipi.hasNext(); ) {
        SURFInterestPoint sip = sipi.next();
        SurfFeature sf = new SurfFeature(sip);
        result[count] = (new StoredField(DocumentBuilder.FIELD_NAME_SURF, sf.getByteArrayRepresentation()));
        count++;
    }
    return result;
}
 
開發者ID:fish2000,項目名稱:lire,代碼行數:16,代碼來源:SurfDocumentBuilder.java

示例2: createDocument

import com.stromberglabs.jopensurf.Surf; //導入方法依賴的package包/類
public Document createDocument(BufferedImage image, String identifier) {
    Document doc = null;
    Surf s = new Surf(image);
    List<SURFInterestPoint> interestPoints = s.getFreeOrientedInterestPoints();
    doc = new Document();
    for (Iterator<SURFInterestPoint> sipi = interestPoints.iterator(); sipi.hasNext(); ) {
        SURFInterestPoint sip = sipi.next();
        SurfFeature sf = new SurfFeature(sip);
        doc.add(new StoredField(DocumentBuilder.FIELD_NAME_SURF, sf.getByteArrayRepresentation()));
    }
    if (identifier != null)
        doc.add(new StringField(DocumentBuilder.FIELD_NAME_IDENTIFIER, identifier, Field.Store.YES));
    return doc;
}
 
開發者ID:fish2000,項目名稱:lire,代碼行數:15,代碼來源:SurfDocumentBuilder.java

示例3: testExtract

import com.stromberglabs.jopensurf.Surf; //導入方法依賴的package包/類
public void testExtract() throws IOException {
        Surf sm = new Surf(ImageIO.read(new FileInputStream("wang-1000/0.jpg")));
//        Surf sm = new SurfMser(ImageIO.read(new FileInputStream("wang-1000/0.jpg")));
        List<SURFInterestPoint> pts = sm.getFreeOrientedInterestPoints();
        for (Iterator<SURFInterestPoint> surfInterestPointIterator = pts.iterator(); surfInterestPointIterator.hasNext(); ) {
            SURFInterestPoint pt = surfInterestPointIterator.next();
            System.out.println(pt.getX() + ", " + pt.getY());
        }
    }
 
開發者ID:fish2000,項目名稱:lire,代碼行數:10,代碼來源:SurfMserTest.java


注:本文中的com.stromberglabs.jopensurf.Surf.getFreeOrientedInterestPoints方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。