I have problem with showing video in JavaFx Media:
public void showVideo(File videoFile) {
scrollPane.setHvalue(scrollPane.getHmin());
scrollPane.setVvalue(scrollPane.getVmin());
Media media = new Media("http://download.oracle.com/otndocs/products/javafx/oow2010-2.flv");
final MediaPlayer mediaPlayer = new MediaPlayer(media);
final MediaView mediaContent = new MediaView(mediaPlayer);
HBox menuBox = new HBox();
menuBox.setAlignment(Pos.CENTER);
menuBox.getChildren().addAll(playButton, stopButton);
VBox videoBox = new VBox();
videoBox.setAlignment(Pos.CENTER);
videoBox.getChildren().addAll(mediaContent, menuBox);
playButtonListener(mediaPlayer);
stopButtonListener(mediaPlayer);
mediaPlayer.setOnEndOfMedia(new Runnable() {
@Override public void run() {
playButton.setGraphic(WindowUtil.createIcon(IconsConstants.ICON_PLAYER_REPEAT));
mediaPlayer.stop();
playButtonListener(mediaPlayer);
}
});
scrollPane.setContent(videoBox);
}
I know that the code isn't wrong because in my coworker system it shows. I try to show flv file. I saw question: JavaFX video not playing
I have windows 10 N with K-Lite standart codec and jdk-8u65-windows-x64 Java and I installed feature pack for windows 10 like in link above. And I don't know what can be the problem.