Dealing with video (DVDs, .avi .mkv) in Java

前端 未结 7 1154
旧巷少年郎
旧巷少年郎 2020-12-02 11:28

After looking around for a decent library for playing videos in Java, I\'ve come unstuck. Everyone around is screaming not to use JMF because it\'s outdated, old and require

7条回答
  •  一个人的身影
    2020-12-02 11:56

    I'm currently using the OpenImaj Library http://openimaj.org/tutorial which has a

    XuggleVideo and XuggleAudio class
    

    I'd suggest you use that and implement your own threading mechanisms to play them. I'm currently working on a media player with hopes of getting it play the 'popular' video formats well since the

    VideoDisplay class
    

    in the library does a good Job but the playback is kinda choppy and the library was implemented with swing in mind and attaching the

    ImageComponent 
    

    to a swing node doesn't seem to work for some reason in JavaFx but I'm able to get them images from a video displaying for now and i hope i get some luck with this.

提交回复
热议问题