use of com.xenoage.zong.musiclayout.spacer.beam.Slant in project Zong by Xenoage.
the class SingleStaffBeamSlanterTest method computeCloseTest.
@Test
public void computeCloseTest() {
Examples.test(Example.all, "close", 9, (suite, example) -> {
float expectedSlant = example.getSlantIs();
Slant slant = testee.computeClose(example.getStems(), example.getStemDir());
assertSlantContains(expectedSlant, slant, example.name);
});
}
use of com.xenoage.zong.musiclayout.spacer.beam.Slant in project Zong by Xenoage.
the class SlantTest method slantDirTest.
@Test
public void slantDirTest() {
Slant slant = slantIs(1, 2, Ascending);
assertEquals(1, slant.getMinIs(), df);
assertEquals(2, slant.getMaxIs(), df);
assertEquals(1, slant.getFlattestIs(), df);
slant = slantIs(1, 2, Descending);
assertEquals(-2, slant.getMinIs(), df);
assertEquals(-1, slant.getMaxIs(), df);
assertEquals(-1, slant.getFlattestIs(), df);
}
Aggregations