{"action":"closed","issue":{"url":"https://api.github.com/repos/caprica/vlcj/issues/520","repository_url":"https://api.github.com/repos/caprica/vlcj","labels_url":"https://api.github.com/repos/caprica/vlcj/issues/520/labels{/name}","comments_url":"https://api.github.com/repos/caprica/vlcj/issues/520/comments","events_url":"https://api.github.com/repos/caprica/vlcj/issues/520/events","html_url":"https://github.com/caprica/vlcj/issues/520","id":188961655,"number":520,"title":"how to add \"EmbeddedMediaPlayerComponent\" object  to JPanal","user":{"login":"akash19ku","id":23183107,"avatar_url":"https://avatars.githubusercontent.com/u/23183107?v=3","gravatar_id":"","url":"https://api.github.com/users/akash19ku","html_url":"https://github.com/akash19ku","followers_url":"https://api.github.com/users/akash19ku/followers","following_url":"https://api.github.com/users/akash19ku/following{/other_user}","gists_url":"https://api.github.com/users/akash19ku/gists{/gist_id}","starred_url":"https://api.github.com/users/akash19ku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/akash19ku/subscriptions","organizations_url":"https://api.github.com/users/akash19ku/orgs","repos_url":"https://api.github.com/users/akash19ku/repos","events_url":"https://api.github.com/users/akash19ku/events{/privacy}","received_events_url":"https://api.github.com/users/akash19ku/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-13T09:47:38Z","updated_at":"2016-11-13T11:36:44Z","closed_at":"2016-11-13T11:36:44Z","body":"i am creating a javafx project in which i want to l do live streaming of IPCamera through  Rtsp protocol. using vlcj.\r\nwhen i am using normal java project with jframe its working fine\r\nwhen i am trying javafx project its note working so i am using swingnode component to integrate jcomponent inside my fxml project\r\n\r\nbut how to attach EmbeddedMediaPlayerComponent with JPanal .\r\n \r\nHere is my code- \r\n\r\n\r\npackage javafxapplication3;\r\n\r\nimport javafx.application.Application;\r\nimport javafx.embed.swing.SwingNode;\r\nimport javafx.scene.Scene;\r\nimport javafx.scene.layout.StackPane;\r\nimport javafx.stage.Stage;\r\nimport javax.swing.JButton;\r\nimport javax.swing.JFrame;\r\nimport javax.swing.JPanel;\r\nimport javax.swing.SwingUtilities;\r\nimport uk.co.caprica.vlcj.component.EmbeddedMediaPlayerComponent;\r\nimport uk.co.caprica.vlcj.discovery.NativeDiscovery;\r\nimport uk.co.caprica.vlcj.mrl.RtspMrl;\r\n\r\n public class SwingFx extends Application {\r\n\r\n         @Override\r\n         public void start(Stage stage) {\r\n             final SwingNode swingNode = new SwingNode();\r\n             createAndSetSwingContent(swingNode);\r\n\r\n             StackPane pane = new StackPane();\r\n             pane.getChildren().add(swingNode);\r\n\r\n             stage.setScene(new Scene(pane, 100, 50));\r\n             stage.show();\r\n         }\r\n\r\n         private void createAndSetSwingContent(final SwingNode swingNode) {\r\n             SwingUtilities.invokeLater(new Runnable() {\r\n                 @Override\r\n                 public void run() {\r\n                     \r\n                     \r\n                     \r\n        \r\n       EmbeddedMediaPlayerComponent mediaPlayerComponent = new EmbeddedMediaPlayerComponent();\r\n    //    frame.setContentPane(mediaPlayerComponent);\r\n    //    frame.setVisible(true); String address;\r\n       JPanel p = new JPanel();\r\n       p.add(mediaPlayerComponent);\r\n        String address = new RtspMrl().host(\"@192.162.27.223\").value();\r\n        System.out.println(address);\r\n        mediaPlayerComponent.getMediaPlayer().playMedia(address);\r\n                     \r\n                     \r\n                     swingNode.setContent(p);\r\n                 }\r\n             });\r\n         }\r\n \r\n         public static void main(String[] args) {\r\n             new NativeDiscovery().discover();\r\n             launch(args);\r\n         }\r\n     }\r\n\r\n[SwingFx.txt](https://github.com/caprica/vlcj/files/587671/SwingFx.txt)"}}
{"actor":{"display_login":"caprica"}}