public void testToString() {
String actual = tc2.toString();
- String expected = "{ type: 2, maxCount: 4, epsilon: 0.001}";
+ String expected = "{ type: 2, maxCount: 4, epsilon: " + EPS + "}";
assertEquals(expected, actual);
}
@Override
protected void setUp() throws Exception {
+ super.setUp();
extractor = DescriptorExtractor.create(DescriptorExtractor.BRIEF);
matSize = 100;
-
- super.setUp();
}
public void testComputeListOfMatListOfListOfKeyPointListOfMat() {
}
protected void setUp() throws Exception {
+ super.setUp();
matcher = DescriptorMatcher.create(DescriptorMatcher.BRUTEFORCE);
matSize = 100;
new DMatch(3, 1, 0, 0.48435235f),
new DMatch(4, 0, 0, 1.0836693f)
};
-
- super.setUp();
}
public void testAdd() {
}
protected void setUp() throws Exception {
+ super.setUp();
matcher = DescriptorMatcher.create(DescriptorMatcher.BRUTEFORCE_HAMMING);
matSize = 100;
new DMatch(1, 2, 0, 42),
new DMatch(2, 1, 0, 40),
new DMatch(3, 3, 0, 53) };
- super.setUp();
}
public void testAdd() {
}
protected void setUp() throws Exception {
+ super.setUp();
matcher = DescriptorMatcher.create(DescriptorMatcher.BRUTEFORCE_HAMMINGLUT);
matSize = 100;
new DMatch(1, 2, 0, 42),
new DMatch(2, 1, 0, 40),
new DMatch(3, 3, 0, 53) };
- super.setUp();
}
public void testAdd() {
}
protected void setUp() throws Exception {
+ super.setUp();
matcher = DescriptorMatcher.create(DescriptorMatcher.BRUTEFORCE_L1);
matSize = 100;
new DMatch(3, 1, 0, 2.6545324f),
new DMatch(4, 0, 0, 6.1294870f)
};
- super.setUp();
}
public void testAdd() {
}
protected void setUp() throws Exception {
+ super.setUp();
matcher = DescriptorMatcher.create(DescriptorMatcher.BRUTEFORCE_SL2);
matSize = 100;
new DMatch(3, 1, 0, 0.23459719f),
new DMatch(4, 0, 0, 1.174339f)
};
-
- super.setUp();
}
public void testAdd() {
@Override
protected void setUp() throws Exception {
+ super.setUp();
detector = FeatureDetector.create(FeatureDetector.FAST);
-
truth = new KeyPoint[] { new KeyPoint(32, 27, 7, -1, 254, 0, -1), new KeyPoint(27, 32, 7, -1, 254, 0, -1), new KeyPoint(73, 68, 7, -1, 254, 0, -1),
new KeyPoint(68, 73, 7, -1, 254, 0, -1) };
-
- super.setUp();
}
public void testCreate() {
}
protected void setUp() throws Exception {
+ super.setUp();
matcher = DescriptorMatcher.create(DescriptorMatcher.FLANNBASED);
matSize = 100;
-
truth = new DMatch[] {
new DMatch(0, 0, 0, 1.049694f),
new DMatch(1, 0, 0, 1.0984558f),
new DMatch(3, 1, 0, 0.48435235f),
new DMatch(4, 0, 0, 1.0836693f)
};
-
- super.setUp();
}
public void testAdd() {
@Override
protected void setUp() throws Exception {
+ super.setUp();
extractor = DescriptorExtractor.create(DescriptorExtractor.ORB);
matSize = 100;
-
- super.setUp();
}
public void testComputeListOfMatListOfListOfKeyPointListOfMat() {
@Override
protected void setUp() throws Exception {
+ super.setUp();
extractor = DescriptorExtractor.create(DescriptorExtractor.SIFT);
keypoint = new KeyPoint(55.775577545166016f, 44.224422454833984f, 16, 9.754629f, 8617.863f, 1, -1);
matSize = 100;
);
}
};
-
- super.setUp();
}
public void testComputeListOfMatListOfListOfKeyPointListOfMat() {
}
protected void setUp() throws Exception {
+ super.setUp();
detector = FeatureDetector.create(FeatureDetector.STAR);
-
matSize = 200;
-
truth = new KeyPoint[] {
- /*
- new KeyPoint(95, 80, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(105, 80, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(80, 95, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(120, 95, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(100, 100, 8, -1, -219.90825f, 0, -1),
- new KeyPoint(80, 105, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(120, 105, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(95, 120, 22, -1, 31.595734f, 0, -1),
- new KeyPoint(105, 120, 22, -1, 31.595734f, 0, -1)
- */
new KeyPoint( 95, 80, 22, -1, 31.5957f, 0, -1),
new KeyPoint(105, 80, 22, -1, 31.5957f, 0, -1),
new KeyPoint( 80, 95, 22, -1, 31.5957f, 0, -1),
new KeyPoint( 95, 120, 22, -1, 31.5957f, 0, -1),
new KeyPoint(105, 120, 22, -1, 31.5957f, 0, -1)
};
-
- super.setUp();
}
public void testCreate() {
@Override
protected void setUp() throws Exception {
+ super.setUp();
extractor = DescriptorExtractor.create(DescriptorExtractor.SURF);
matSize = 100;
-
- super.setUp();
}
public void testComputeListOfMatListOfListOfKeyPointListOfMat() {
@Override
protected void setUp() throws Exception {
+ super.setUp();
detector = FeatureDetector.create(FeatureDetector.SURF);
-
matSize = 100;
-
truth = new KeyPoint[] {
new KeyPoint(55.775578f, 55.775578f, 16, 80.245735f, 8617.8633f, 0, -1),
new KeyPoint(44.224422f, 55.775578f, 16, 170.24574f, 8617.8633f, 0, -1),
new KeyPoint(44.224422f, 44.224422f, 16, 260.24573f, 8617.8633f, 0, -1),
new KeyPoint(55.775578f, 44.224422f, 16, 350.24573f, 8617.8633f, 0, -1)
};
-
- super.setUp();
}
public void testCreate() {
# Create a script for running the Java tests and place it in build/bin.
if(WIN32)
- file(WRITE "${CMAKE_BINARY_DIR}/bin/opencv_test_java.cmd" "cd ${opencv_test_java_bin_dir}\nset path=${EXECUTABLE_OUTPUT_PATH};%path%\nant -DjavaLibraryPath=${EXECUTABLE_OUTPUT_PATH}/Release buildAndTest")
- file(WRITE "${CMAKE_BINARY_DIR}/bin/opencv_test_java_D.cmd" "cd ${opencv_test_java_bin_dir}\nset path=${EXECUTABLE_OUTPUT_PATH};%path%\nant -DjavaLibraryPath=${EXECUTABLE_OUTPUT_PATH}/Debug buildAndTest")
+ file(WRITE "${CMAKE_BINARY_DIR}/bin/opencv_test_java.cmd" "cd ${opencv_test_java_bin_dir}\nset PATH=${EXECUTABLE_OUTPUT_PATH}/Release;%PATH%\nant -DjavaLibraryPath=${EXECUTABLE_OUTPUT_PATH}/Release buildAndTest")
+ file(WRITE "${CMAKE_BINARY_DIR}/bin/opencv_test_java_D.cmd" "cd ${opencv_test_java_bin_dir}\nset PATH=${EXECUTABLE_OUTPUT_PATH}/Debug;%PATH%\nant -DjavaLibraryPath=${EXECUTABLE_OUTPUT_PATH}/Debug buildAndTest")
else()
file(WRITE "${CMAKE_BINARY_DIR}/bin/opencv_test_java.sh" "cd ${opencv_test_java_bin_dir};\nant -DjavaLibraryPath=${LIBRARY_OUTPUT_PATH} buildAndTest;\ncd -")
endif()
</jar>
</target>
- <!-- <target name="run" > -->
- <!-- <java fork="true" classname="org.opencv.test.OpenCVTestRunner"> -->
- <!-- <sysproperty key="java.library.path" path="${javaLibraryPath}"/> -->
- <!-- <classpath refid="master-classpath"/> -->
- <!-- <classpath> -->
- <!-- <fileset dir="build/jar"> -->
- <!-- <include name="*.jar"/> -->
- <!-- </fileset> -->
- <!-- </classpath> -->
- <!-- </java> -->
- <!-- </target> -->
-
<target name="test">
<mkdir dir="testResults"/>
- <junit printsummary="yes" haltonfailure="false">
+ <junit printsummary="false" haltonfailure="false" haltonerror="false" showoutput="false" logfailedtests="true" maxmemory="256m">
<sysproperty key="java.library.path" path="${javaLibraryPath}"/>
<classpath refid="master-classpath"/>
<classpath>