| CARVIEW |
Development
Edit
This library is designed to simplify ffmpeg for use in media player applications written in pure C. It is thread safe, very fast, and has a pluggable architecture for output renderers for both audio and video streams.
This library does NOT remote control mplayer, or other engines, it is stand alone with libavcodec and libavformat making it very easy to tightly implement a media player into your application.
Usage is very simple:
mp_t *mp;
mp = mp_new();
mp_load(mp, "filename.avi");
if (mp_num_streams(mp, CODEC_TYPE_AUDIO) > 0) mp_setup_stream(mp, 0, PLAYER_AUDIO_ALSA, NULL);
if (mp_num_streams(mp, CODEC_TYPE_VIDEO) > 0) mp_setup_stream(mp, 0, PLAYER_VIDEO_XV , NULL);
mp_open(mp);
mp_play(mp);
mp_wait(mp);
mp_close(mp);
mp_free(mp);Currently four renderers are supported, ALSA, XV, DirectFB and OpenGL via GTK+, though it is not hard to implement your own renderer.
Renderers are very simple to implement, for audio all you have to do is define the functions: new, free, open, close, getdelay, write, pause, resume and call the macro: DEFINE_AUDIO_RENDERER(PLAYER_AUDIO_FOOBAR, new, free, open, close, getdelay, write, pause, resume)
It is very similar for Video.
Example console output
I: Found card: HDA NVidia
I: Opened codec "mp2" for stream 1
I: Using renderer "PLAYER_AUDIO_ALSA" for stream 1
I: Found 24bit TrueColor
I: Opened codec "mpeg2video" for stream 0
I: Using renderer "PLAYER_VIDEO_XV" for stream 0
I: Waiting for streams to be primed
I: Waiting for stream 0 to become ready
I: Aspect Ratio: 1.333333
I: Frame Size: 720x480
I: Display Size: 640x480
I: Telling the renderer to initialize it's buffers
W: Hardware can not pause
I: Opened audio device (rate = 48000, channels = 2)
I: Signal stream 1 primed
I: Signal stream 0 primed
I: Stream 0 is primed
I: Syncing clock to audio stream 1
I: Waiting for stream 1 to become ready
I: Stream 1 is primed
I: All streams primed and ready to go
I: Stream 0 started
I: Stream 1 started
I: Finished demuxing
I: Waiting for the video queue to be emptied
I: Telling the renderer to free it's buffers
I: Demuxer finished
I: Joining stream 0
I: Joining stream 1
Journal Entries
No entries yet. Link your entries with 'libmediaplayer' to include this project.
Ohloh Analysis Summary
Updated 04 Feb 2010 19:35 UTC
Ratings & Reviews
Community Rating
Based on 0 user ratings.
Your Rating
Click to rate this project.
Links
0 links submitted so far. Submit your own links.
Where in the world?
Related Projects by Tags
iav, mediacorelib, MLT - Media Lovin' Toolkit, pspmt, stream-360
Project Cost |
|
|---|---|
| This calculator estimates how much it would cost to hire a team to write this project from scratch. More » | |
| Include | |
| Codebase | 2,459 |
| Effort (est.) | 1 Person Years |
| Avg. Salary | $ year |
| $ 27,989 | |
Recent Posts
-
Using Filezilla to transfer site from weebly to bluehost
by
kentbayne
I am trying to transfer my web site from Weebly to Bluehost using Filezilla but I am having troub... -
LTSP enlistments stuck
by
Robin Luckey
Hi Wim, I deleted the enlistment to https://code.launchpad.net/~ltsp-upstream/ltsp/ldm-trunk, si... -
Cacophony Project
by
Robin Luckey
Hi Vadtec, Sorry for the late response. I rescheduled the update, and everything seems to have g...
Recent Reviews
-
Freeciv
by
Vadim Mikhnevych
A Great game. Respect to Sid, who made the original Civilization, and to all the guys who support... -
Transifex
by
VladimirMelo
Transifex is developed by Dimitris Glezos, Christos Trochalakis (both from Greece) and the brazil... -
Lobo - Continuous Tuning
by
J. Chris Folsom
This project is officially eight kinds of awesome. "Just What I Needed" - RicK Ocasek
Copyright © 2010 Geeknet, Inc., All Rights Reserved.