bukka.wh
bukka.wh

Reputation: 913

Android and ffmpeg. Play video (with sound)

I have compiled ffmpeg library add it to my project and now I want to play video (with full list of options - stop, pause, forward, backward etc). I have read roman10 ffmpeg tutorial. And I also find out tutorial which describes how play video with ffmpeg and SDL framework. The difference (if I have correctly understood) is that in roman's tutorial each frame of video turns into a Bitmap and is then passed to Java code where it shows on SurfaceView. And in the second tutorial, the video is playing with the help of the SDL framework without passing it back to Java code.

I want to ask some questions:

  1. Which way is better: return Bitmap back to Java and show it on SurfaceView or play it with SDL?
  2. How can I play the sound of my video (can I do it with ffmpeg or do I need some additional libraries)?

Upvotes: 0

Views: 5698

Answers (1)

Zeeshan Saiyed
Zeeshan Saiyed

Reputation: 466

this might help you

https://github.com/vanevery/JavaCV-0.5-Stream-Test

https://github.com/vanevery/JavaCV_0.3_stream_test

It's a player based on ffmpeg streaming.

Upvotes: 2

Related Questions