The problem has been solved. It was caused by I tried to play the video before the frame set the whole panel visible and also the URL of the video file should be set correctly in vlcj 2.1.0.
I change the URL to the correct format and move the playMedia to frame class and call it after the initialization of the Frame.
I found these two discussions very helpful: 1. Trying to embed vlcj media player in a WindowsCanvas inside a JPanel