Package org.gstreamer.event

Examples of org.gstreamer.event.NewSegmentEvent


    }
    @Test public void createLatencyEvent() throws Exception {
        new LatencyEvent(ClockTime.ZERO);
    }
    @Test public void createSegmentEvent() throws Exception {
        new NewSegmentEvent(false, 1.0, Format.TIME, 0L, 0L, 0L);
    }
View Full Code Here


        final ClockTime MAGIC = ClockTime.valueOf(0xdeadbeef, TimeUnit.NANOSECONDS);
        LatencyEvent ev = new LatencyEvent(MAGIC);
        assertEquals("Incorrect latency returned", MAGIC, ev.getLatency());
    }
    @Test public void NewSegment_isUpdate() {
        NewSegmentEvent ev = new NewSegmentEvent(false, 1.0, Format.TIME, 0L, 0L, 0L);
        assertFalse("Segment should not be an update", ev.isUpdate());
        ev = new NewSegmentEvent(true, 1.0, Format.TIME, 0L, 0L, 0L);
        assertTrue("Segment should be an update", ev.isUpdate());
    }
View Full Code Here

        ev = new NewSegmentEvent(true, 1.0, Format.TIME, 0L, 0L, 0L);
        assertTrue("Segment should be an update", ev.isUpdate());
    }
    @Test public void NewSegment_getRate() {
        final double RATE = (double) 0xdeadbeef;
        NewSegmentEvent ev = new NewSegmentEvent(false, RATE, Format.TIME, 0L, 0L, 0L);
        assertEquals("Incorrect rate returned from getRate", RATE, ev.getRate(), 0.0);
    }
View Full Code Here

        NewSegmentEvent ev = new NewSegmentEvent(false, RATE, Format.TIME, 0L, 0L, 0L);
        assertEquals("Incorrect rate returned from getRate", RATE, ev.getRate(), 0.0);
    }
    @Test public void NewSegment_getStart() {
        final long START = 0xdeadbeefL;
        NewSegmentEvent ev = new NewSegmentEvent(false, 0.1, Format.TIME, START, -1L, 0L);
        assertEquals("Incorrect rate returned from getRate", START, ev.getStart());
    }
View Full Code Here

        NewSegmentEvent ev = new NewSegmentEvent(false, 0.1, Format.TIME, START, -1L, 0L);
        assertEquals("Incorrect rate returned from getRate", START, ev.getStart());
    }
    @Test public void NewSegment_getStop() {
        final long STOP = 0xdeadbeefL;
        NewSegmentEvent ev = new NewSegmentEvent(false, 1.0, Format.TIME, 0L, STOP, 0L);
        assertEquals("Incorrect rate returned from getRate", STOP, ev.getEnd());
    }
View Full Code Here

TOP

Related Classes of org.gstreamer.event.NewSegmentEvent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.