Hi guys,
these days i did some research on github on how to play a video inside a demo with jme. I reworked some code and created a little project to discuss it with you. The project uses JavaFX libraries to play the videos. I would like to know if there is a more efficient way to play a video with jme or if what I have found can be improved.
Let me know what you think.
Nice, I have read before that java Reflection may be an expensive solution, another solution to use jfx player without real jme-jfx context, in case you are using lwjgl2, try the following :
1- build jme context on a Swing/AWT canvas.
2- create a JFrame with a Full screen JComponent or JPanel.
3- using JFXPanel concrete class from javafx.embed.swing.JFXPanel you can manage to create jfx scene & attach a jfx Video Player widget on it & destroy whenever needed.
-then :
Synchronize the add of the JFXPanel & the Jme-swing canvas in order to get a splash screen with sound (jfx vid) before game shows up (Notice that game already starts on jme-canvas in foreground without showing up).