Package org.gstreamer.message

Examples of org.gstreamer.message.StateChangedMessage


            }
           
        };
        pipe.getBus().connect(stateChanged);
        gst.gst_element_post_message(pipe.pipe,
                new StateChangedMessage(pipe.pipe, State.READY, State.PLAYING, State.VOID_PENDING));
        pipe.run();
        pipe.getBus().disconnect(stateChanged);
        assertTrue("STATE_CHANGED signal not received", signalFired.get());
        pipe.dispose();
    }
View Full Code Here


        Message msg = GstMessageAPI.GSTMESSAGE_API.gst_message_new_state_changed(src, State.READY, State.PLAYING, State.VOID_PENDING);
        assertTrue("gst_message_new_state_changed did not return an instance of StateChangedMessage", msg instanceof StateChangedMessage);
    }
    @Test public void constructStateChanged() {
        Element src = ElementFactory.make("fakesrc", "src");
        new StateChangedMessage(src, State.READY, State.PLAYING, State.VOID_PENDING);
    }
View Full Code Here

        Element src = ElementFactory.make("fakesrc", "src");
        new StateChangedMessage(src, State.READY, State.PLAYING, State.VOID_PENDING);
    }
    @Test public void StateChanged_get() {
        Element src = ElementFactory.make("fakesrc", "src");
        StateChangedMessage msg = (StateChangedMessage) GstMessageAPI.GSTMESSAGE_API.gst_message_new_state_changed(src, State.READY, State.PLAYING, State.VOID_PENDING);
        assertEquals("Wrong old state", State.READY, msg.getOldState());
        assertEquals("Wrong new state", State.PLAYING, msg.getNewState());
        assertEquals("Wrong pending state", State.VOID_PENDING, msg.getPendingState());
    }
View Full Code Here

                signalMessage.set(msg);
                pipe.quit();
            }
        });
        GstElementAPI.GSTELEMENT_API.gst_element_post_message(pipe.src,
                new StateChangedMessage(pipe.src, State.READY, State.PLAYING, State.VOID_PENDING));
        pipe.run();
        Message msg = signalMessage.get();
        assertNotNull("No message available on bus", msg);
        assertEquals("Wrong message type", MessageType.STATE_CHANGED, msg.getType());
        StateChangedMessage smsg = (StateChangedMessage) msg;
        assertEquals("Wrong old state", State.READY, smsg.getOldState());
        assertEquals("Wrong new state", State.PLAYING, smsg.getNewState());
        assertEquals("Wrong pending state", State.VOID_PENDING, smsg.getPendingState());
        pipe.dispose();
    }
View Full Code Here

TOP

Related Classes of org.gstreamer.message.StateChangedMessage

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.