private static VideoComponent createComponenet(final Composite parent) { Pipeline pipe = new Pipeline("SWT Overlay Test"); Element src = ElementFactory.make("videotestsrc", "videotest"); //FileSrc src = new FileSrc("/tmp/pipe"); // Element src = ElementFactory.make("tcpclientsrc", "videotest"); // src.set("port", 6666); // Element depay = ElementFactory.make("gdpdepay", "gdpdepay"); // Element caps = ElementFactory.make("capsfilter", "caps"); // caps.setCaps(new Caps("video/x-raw-yuv,format=YUY2,width=320,height=240,framerate=30/1")); VideoComponent component = new VideoComponent(parent, SWT.NONE); component.getElement().setName("video"); component.setKeepAspect(true); component.setLayoutData(new GridData(GridData.FILL_BOTH)); Element sink = component.getElement(); component.setData(pipe); components.add(component); // pipe.addMany(src, depay, caps, sink); // Element.linkMany(src, depay, caps, sink); pipe.addMany(src, sink); Element.linkMany(src, sink); return component; }