Linux: Coding a video player for a game?

Started by
8 comments, last by BlackShark33 7 years, 7 months ago

I will soon need to code a video player for the Linux port of our commercial game.

We don't need anything fancy just MP4 (and sound). I can't figure out what would be legal to use. We don't have the budget for 3rd party commercial libraries and it is a Linux port after all.

Do you have any recommendations?

Advertisement

Use ffmpeg

... or I suppose you could spend several work-years trying to build your own MP4 decoder that kinda works okay on your specific files with bugs you can work around.

Hello,

Have you taken a look at libVLC, it's the api part of VLC media player. It's realeased under LGPL so if you don't modify the lib youdon't have to redistribute anything. The principle of usage is simple : VLC render frame in a buffer and notify you when it's ready to read it. The api is C based.

Regards

Use ffmpeg

... or I suppose you could spend several work-years trying to build your own MP4 decoder that kinda works okay on your specific files with bugs you can work around.

Haha! Not interested in doing that! :D 5 days per platform max. We've done three and we have four more to go. :rolleyes:

What video player library you are using on the other platforms?

I found this tutorial to be very helpful if you're going to use libav (which I recommend). ffmpeg uses libav.

http://dranger.com/ffmpeg/tutorial01.html

"I would try to find halo source code by bungie best fps engine ever created, u see why call of duty loses speed due to its detail." -- GettingNifty

ffmpeg uses libav.

Nope. libav is a fork of ffmpeg, and ffmpeg doesn't use libav.

Unless by ffmpeg you mean libav's video converter that had same name as identical tool from original ffmpeg project.

What video player library you are using on the other platforms?

Media Foundation and the respective proprietary AV APIs.

Take a look at https://en.wikipedia.org/wiki/OpenH264 http://www.openh264.org/faq.html

It's used by FireFox. https://blog.mozilla.org/blog/2013/10/30/video-interoperability-on-the-web-gets-a-boost-from-ciscos-h-264-codec/

The license is confusing, but here's how I think it works:

The important part is that you do not compile and link the patented code. You do not ship the shared library binary. Your app downloads the library and Cisco volunteers to pay the patent license fee for that user on your behalf.

The code is open source. But, that does not grant you license to use the patents. It's only open source so that anyone can contribute to the source.

Some good suggestions here, might I recommend LibTheoraPlayer?

https://github.com/AprilAndFriends/theoraplayer

I've had some amazing luck integrating the predecessor of this, https://sourceforge.net/projects/libtheoraplayer/ (same project as above, older repository).

Some more documents about it on its' website, http://libtheoraplayer.cateia.com/wiki/index.php/Main_Page (not sure how up to date it is) but it was enough to get started. If I remember correctly, this was free to use for any purpose & runs on Linux.

-Jawshttp://uploading.com/files/eff2c24d/TGEpre.zip/

This topic is closed to new replies.

Advertisement