|
Name |
|
Date |
Size |
#Lines |
LOC |
| .. | | 03-May-2022 | - |
| audio/ | H | 18-Jun-2001 | - | 5,525 | 4,635 |
| video/ | H | 03-May-2022 | - | 13,302 | 8,576 |
| CHANGES | H A D | 18-Jun-2001 | 15 KiB | 324 | 309 |
| COPYING | H A D | 26-Aug-1999 | 24.7 KiB | 482 | 399 |
| MPEG.cpp | H A D | 18-Jun-2001 | 10.7 KiB | 507 | 404 |
| MPEG.h | H A D | 27-Apr-2001 | 4.3 KiB | 136 | 73 |
| MPEGaction.h | H A D | 04-Apr-2001 | 3.9 KiB | 140 | 96 |
| MPEGaudio.h | H A D | 03-May-2022 | 9.9 KiB | 379 | 242 |
| MPEGerror.h | H A D | 26-Aug-1999 | 1.5 KiB | 63 | 30 |
| MPEGfilter.c | H A D | 24-Sep-2000 | 11.7 KiB | 382 | 243 |
| MPEGfilter.h | H A D | 05-Sep-2000 | 2.2 KiB | 68 | 27 |
| MPEGlist.cpp | H A D | 06-Jun-2000 | 878 | 61 | 48 |
| MPEGlist.h | H A D | 18-May-2000 | 831 | 46 | 24 |
| MPEGring.cpp | H A D | 27-Apr-2001 | 6.5 KiB | 260 | 163 |
| MPEGring.h | H A D | 18-May-2000 | 2.7 KiB | 95 | 36 |
| MPEGstream.cpp | H A D | 24-May-2001 | 6.9 KiB | 349 | 226 |
| MPEGstream.h | H A D | 27-Apr-2001 | 2.9 KiB | 117 | 51 |
| MPEGsystem.cpp | H A D | 27-Apr-2001 | 36.1 KiB | 1,459 | 1,088 |
| MPEGsystem.h | H A D | 27-Apr-2001 | 3.1 KiB | 118 | 61 |
| MPEGvideo.h | H A D | 04-Apr-2001 | 3.5 KiB | 110 | 58 |
| Makefile.am | H A D | 04-Apr-2001 | 1.7 KiB | 93 | 65 |
| Makefile.in | H A D | 18-Jun-2001 | 21.8 KiB | 695 | 551 |
| README | H A D | 16-Apr-2001 | 2.5 KiB | 75 | 46 |
| README.SDL_mixer | H A D | 05-Oct-2000 | 1.2 KiB | 39 | 28 |
| TODO | H A D | 24-Apr-2000 | 221 | 6 | 4 |
| acinclude.m4 | H A D | 19-Apr-2001 | 21.3 KiB | 626 | 583 |
| aclocal.m4 | H A D | 24-Apr-2001 | 31.5 KiB | 907 | 840 |
| autogen.sh | H A D | 30-May-2000 | 109 | 9 | 4 |
| config.guess | H A D | 17-Jan-2001 | 38.6 KiB | 1,403 | 1,214 |
| config.sub | H A D | 17-Jan-2001 | 26.8 KiB | 1,356 | 1,217 |
| configure | H A D | 03-May-2022 | 127.5 KiB | 4,244 | 3,496 |
| configure.in | H A D | 24-Apr-2001 | 7.6 KiB | 299 | 265 |
| glmovie-tile.c | H A D | 10-Nov-2000 | 9 KiB | 264 | 158 |
| glmovie.c | H A D | 04-Oct-2000 | 2.9 KiB | 119 | 89 |
| glmovie.h | H A D | 21-Oct-1999 | 409 | 24 | 18 |
| gtv.1 | H A D | 03-Jan-2000 | 1 KiB | 30 | 25 |
| gtv.c | H A D | 03-May-2022 | 44 KiB | 1,319 | 1,051 |
| gtv.h | H A D | 11-May-2000 | 341 | 27 | 18 |
| install-sh | H A D | 21-Oct-1999 | 5.5 KiB | 252 | 153 |
| ltconfig | H A D | 22-May-2001 | 98.6 KiB | 3,168 | 2,452 |
| ltmain.sh | H A D | 22-May-2001 | 108.7 KiB | 4,043 | 3,036 |
| missing | H A D | 21-Oct-1999 | 6.1 KiB | 191 | 154 |
| mkinstalldirs | H A D | 21-Oct-1999 | 726 | 41 | 23 |
| plaympeg.1 | H A D | 03-Feb-2000 | 1.6 KiB | 57 | 51 |
| plaympeg.c | H A D | 27-Apr-2001 | 24.2 KiB | 894 | 720 |
| smpeg-config.in | H A D | 11-Dec-2000 | 1.2 KiB | 62 | 55 |
| smpeg.cpp | H A D | 04-Apr-2001 | 8.8 KiB | 339 | 212 |
| smpeg.h | H A D | 04-Apr-2001 | 7.3 KiB | 208 | 82 |
| smpeg.m4 | H A D | 03-May-2022 | 6.2 KiB | 194 | 181 |
| smpeg.spec.in | H A D | 14-Jun-2000 | 2.2 KiB | 91 | 73 |
README
1
2 SDL MPEG Player Library (SMPEG)
3
4 Version 0.4.4
5 September 28, 2000
6
7
8Written by Karl Robillard and Sam Lantinga, Loki Software, Inc.
9Streaming MPEG support contributed by Vivien Chappelier.
10
11SMPEG is a free MPEG1 video player library with sound support. Video playback
12is based on the ubiquitous Berkeley MPEG player, mpeg_play v2.2. Audio is
13played through a slightly modified mpegsound library, part of Splay v0.8.2.
14SMPEG supports MPEG audio (MP3), MPEG-1 video, and MPEG system streams.
15
16This library is distributed under the GNU Library Public License (LGPL)
17version 2.
18
19plaympeg, gtv, and glmovie are simple video players provided to test the
20library. The C library interface is 'documented' in smpeg.h, and the C++
21library interface is spread out over the MPEG*.h files.
22
23This is a work in progress. Only 16 or 32 bit color depth is supported.
24The player will dynamically conver to other color depths, but playback
25will be much faster if your display is already set to 16 bit color depth.
26Currently it has only been tested on Linux.
27
28
29Requirements:
30
31 * Simple DirectMedia Layer v1.2.0 or newer
32 http://www.libsdl.org/
33
34To make:
35
36 Type 'make all'. This should build libsmpeg.a and plaympeg
37
38Usage:
39
40 plaympeg [--noaudio] [--novideo] [--double|-2] [--loop|-l] file ...
41
42
43Known Issues:
44
45 The MPEG decoding is a fairly slow and mathematically intensive
46 process. It could use even further optimization.
47
48 There isn't any synchronization between the audio and video threads,
49 and system stream timestamps are ignored. The video is synchronized
50 with audio by using video framerate and elapsed time. They are
51 are synchronized well enough for short clips, but long movies, or
52 movies with visual audio cues (like speech) don't look very good.
53
54Reporting bugs:
55
56 Please report any bugs and/or fixes to smpeg@lokigames.com.
57
58
59Looking at the code:
60
61 The functions that should be optimized to improve performance are:
62 Color16DitherImageMod() (Uses 5ms CPU, called few times)
63 Twox2Color16DitherImageMod() (Uses 10ms CPU, called few times)
64 j_rev_dct() (Uses 0.01ms CPU, but called many times)
65 ParseReconBlock() (Uses 0.01ms CPU, but called many times)
66
67 To improve framerate scheduling, look at timeSync() in video/gdith.cpp
68
69Links:
70
71 Berkeley MPEG player http://bmrc.berkeley.edu/frame/research/mpeg
72 Splay http://my.netian.com/~polarb
73 SDL http://www.libsdl.org/
74
75
README.SDL_mixer
1
2There is no longer explicit support for the SDL_mixer library.
3
4You can have the SDL mixer library mix audio from a movie by hooking into
5the SDL mixer music hooks:
6
7#include "smpeg.h"
8#include "SDL_mixer.h"
9
10 .. set up the mixer audio ...
11
12 /* Note the last parameter is zero! */
13 mpeg = SMPEG_new("file.mpg", &info, 0);
14
15 /* Play the movie, using SDL_mixer for audio */
16 SMPEG_enableaudio(mpeg, 0);
17 if ( play_audio ) {
18 SDL_AudioSpec audiofmt;
19 Uint16 format;
20 int freq, channels;
21
22 /* Tell SMPEG what the audio format is */
23 Mix_QuerySpec(&freq, &format, &channels);
24 audiofmt.format = format;
25 audiofmt.freq = freq;
26 audiofmt.channels = channels;
27 SMPEG_actualSpec(mpeg, &audiofmt);
28
29 /* Hook in the MPEG music mixer */
30 Mix_HookMusic(SMPEG_playAudioSDL, mpeg);
31 SMPEG_enableaudio(mpeg, 1);
32 }
33 SMPEG_play(mpeg);
34
35 /* Stop the movie and unhook SMPEG from the mixer */
36 SMPEG_stop(mpeg);
37 Mix_HookMusic(NULL, NULL);
38
39