MPlayer-cvslog
Threads by month
- ----- 2026 -----
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2003 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2002 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2001 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
February 2008
- 15 participants
- 170 discussions
Author: compn
Date: Sat Jun 9 00:59:04 2007
New Revision: 23524
Log:
add mmes fourcc for mpeg2 in avi files
Modified:
trunk/etc/codecs.conf
Modified: trunk/etc/codecs.conf
==============================================================================
--- trunk/etc/codecs.conf (original)
+++ trunk/etc/codecs.conf Sat Jun 9 00:59:04 2007
@@ -58,6 +58,7 @@ videocodec mpeg12
fourcc MPEG
fourcc hdv3 ; HDV 1080i50
fourcc mx5p ; MPEG IMX 625/50 (50 Mb/s)
+ fourcc MMES,mmes ; matrox mpeg2 in avi
driver libmpeg2
; dll "libmpeg2"
out YV12,I420,IYUV
@@ -85,6 +86,7 @@ videocodec ffmpeg2
fourcc MPEG
fourcc hdv3 ; HDV 1080i50
fourcc mx5p ; MPEG IMX 625/50 (50 Mb/s)
+ fourcc MMES,mmes ; matrox mpeg2 in avi
driver ffmpeg
dll "mpeg2video"
out YV12,I420,IYUV
@@ -104,6 +106,7 @@ videocodec ffmpeg12
fourcc MPEG
fourcc hdv3 ; HDV 1080i50
fourcc mx5p ; MPEG IMX 625/50 (50 Mb/s)
+ fourcc MMES,mmes ; matrox mpeg2 in avi
driver ffmpeg
dll "mpegvideo"
out YV12,I420,IYUV
@@ -122,6 +125,7 @@ videocodec ffmpeg12mc
fourcc MPEG
fourcc hdv3 ; HDV 1080i50
fourcc mx5p ; MPEG IMX 625/50 (50 Mb/s)
+ fourcc MMES,mmes ; matrox mpeg2 in avi
driver ffmpeg
dll "mpegvideo_xvmc"
out IDCT_MPEG2
4
5
Author: diego
Date: Thu May 17 23:48:56 2007
New Revision: 23335
Log:
Remove awk test. awk is a basic Unix tool, any implementation is sufficient.
Modified:
trunk/configure
trunk/vidix/Makefile
Modified: trunk/configure
==============================================================================
--- trunk/configure (original)
+++ trunk/configure Thu May 17 23:48:56 2007
@@ -7179,28 +7179,7 @@ if test "$_vidix_internal" = auto ; then
beos && _vidix_internal=no
darwin && _vidix_internal=no
fi
-
-# checking for a working awk, I'm using mawk first, because it's fastest - atmos
-_awk=awk
if test "$_vidix_internal" = yes ; then
-_awk_verc_fail=yes
-echocheck "awk"
-for _awk in mawk gawk nawk; do
- if ( $_awk 'BEGIN{testme();}function testme(){print"";}' ) >> "$TMPLOG" 2>&1; then
- _awk_verc_fail=no
- break
- fi
-done
-test "$_awk_verc_fail" = yes && _awk=no
-echores "$_awk"
-if test "$_awk_verc_fail" = yes; then
-echo "VIDIX needs awk, but no working implementation was found!"
-echo "Try the GNU version, which can be downloaded from:"
-echo "ftp://ftp.gnu.org/gnu/gawk/"
-echo "If you don't need VIDIX, you can use configure --disable-vidix instead."
-die "no awk"
-fi
-fi
if test "$_vidix_internal" = yes; then
_res_comment="internal"
@@ -7544,7 +7523,6 @@ libdir = \$(LIBDIR)
#AR = ar
CC = $_cc
HOST_CC = $_host_cc
-AWK = $_awk
RANLIB = $_ranlib
LDCONFIG = $_ldconfig
INSTALL = $_install
Modified: trunk/vidix/Makefile
==============================================================================
--- trunk/vidix/Makefile (original)
+++ trunk/vidix/Makefile Thu May 17 23:48:56 2007
@@ -47,7 +47,7 @@ rage128_vid.o: radeon_vid.c
$(CC) -c $(CFLAGS) -DRAGE128 -o $@ $<
pci_names.c pci_dev_ids.c: pci.db
- LC_ALL=C $(AWK) -f pci_db2c.awk $<
+ LC_ALL=C awk -f pci_db2c.awk $<
clean::
rm -f pci_*.c pci_*.h
5
8
Author: reimar
Date: Sat Jul 7 00:07:35 2007
New Revision: 23727
Log:
Fix CSS format strings, they could print more than two digits for
"negative" numbers.
Modified:
trunk/libdvdcss/libdvdcss.c
Modified: trunk/libdvdcss/libdvdcss.c
==============================================================================
--- trunk/libdvdcss/libdvdcss.c (original)
+++ trunk/libdvdcss/libdvdcss.c Sat Jul 7 00:07:35 2007
@@ -472,7 +472,7 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open (
{
char psz_tmp[16 + 1];
sprintf( psz_tmp,
- "%.2x%.2x%.2x%.2x%.2x%.2x%.2x%.2x",
+ "%.2"PRIx8"%.2"PRIx8"%.2"PRIx8"%.2"PRIx8"%.2"PRIx8"%.2"PRIx8"%.2"PRIx8"%.2"PRIx8"",
psz_serial[0], psz_serial[1], psz_serial[2],
psz_serial[3], psz_serial[4], psz_serial[5],
psz_serial[6], psz_serial[7] );
@@ -488,7 +488,7 @@ LIBDVDCSS_EXPORT dvdcss_t dvdcss_open (
psz_key[0] = '-';
for( i = 0; i < KEY_SIZE; i++ )
{
- sprintf( &psz_key[1+i*2], "%.2x", dvdcss->css.p_disc_key[i] );
+ sprintf( &psz_key[1+i*2], "%.2"PRIx8, dvdcss->css.p_disc_key[i] );
}
psz_key[1 + KEY_SIZE * 2] = '\0';
}
4
12
Author: diego
Date: Fri Feb 22 10:09:46 2008
New Revision: 26061
Log:
Add MPLAYER_ prefix to multiple inclusion guards.
Modified:
trunk/access_mpcontext.h
trunk/asxparser.h
trunk/cfg-mencoder.h
trunk/cfg-mplayer.h
trunk/codec-cfg.h
trunk/command.h
trunk/cpudetect.h
trunk/cputable.h
trunk/drivers/generic_math.h
trunk/drivers/mga_vid.h
trunk/drivers/radeon.h
trunk/drivers/radeon_vid.h
trunk/drivers/tdfx_vid.h
trunk/edl.h
trunk/fmt-conversion.h
trunk/get_path.h
trunk/gui/app.h
trunk/gui/bitmap.h
trunk/gui/cfg.h
trunk/gui/interface.h
trunk/gui/mplayer/gmplayer.h
trunk/gui/mplayer/gtk/about.h
trunk/gui/mplayer/gtk/eq.h
trunk/gui/mplayer/gtk/fs.h
trunk/gui/mplayer/gtk/gtk_common.h
trunk/gui/mplayer/gtk/mb.h
trunk/gui/mplayer/gtk/menu.h
trunk/gui/mplayer/gtk/opts.h
trunk/gui/mplayer/gtk/pl.h
trunk/gui/mplayer/gtk/sb.h
trunk/gui/mplayer/gtk/url.h
trunk/gui/mplayer/gui_common.h
trunk/gui/mplayer/play.h
trunk/gui/mplayer/widgets.h
trunk/gui/skin/cut.h
trunk/gui/skin/font.h
trunk/gui/skin/skin.h
trunk/gui/win32/dialogs.h
trunk/gui/win32/gui.h
trunk/gui/win32/playlist.h
trunk/gui/win32/skinload.h
trunk/gui/win32/wincfg.h
trunk/gui/wm/ws.h
trunk/gui/wm/wskeys.h
trunk/gui/wm/wsmkeys.h
trunk/gui/wm/wsxdnd.h
trunk/input/ar.h
trunk/input/input.h
trunk/input/joystick.h
trunk/input/lirc.h
trunk/input/mouse.h
trunk/libaf/af.h
trunk/libaf/af_format.h
trunk/libaf/af_hrtf.h
trunk/libaf/af_mp.h
trunk/libaf/control.h
trunk/libaf/dsp.h
trunk/libaf/equalizer.h
trunk/libaf/filter.h
trunk/libaf/reorder_ch.h
trunk/libaf/window.h
trunk/libao2/audio_out.h
trunk/libao2/audio_out_internal.h
trunk/libmenu/menu.h
trunk/libmenu/menu_list.h
trunk/libmpcodecs/ad.h
trunk/libmpcodecs/ad_internal.h
trunk/libmpcodecs/ae.h
trunk/libmpcodecs/ae_faac.h
trunk/libmpcodecs/ae_lame.h
trunk/libmpcodecs/ae_lavc.h
trunk/libmpcodecs/ae_pcm.h
trunk/libmpcodecs/ae_toolame.h
trunk/libmpcodecs/ae_twolame.h
trunk/libmpcodecs/cmmx.h
trunk/libmpcodecs/dec_audio.h
trunk/libmpcodecs/dec_video.h
trunk/libmpcodecs/img_format.h
trunk/libmpcodecs/mp_image.h
trunk/libmpcodecs/mpc_info.h
trunk/libmpcodecs/native/alaw.h
trunk/libmpcodecs/native/mmx.h
trunk/libmpcodecs/native/xa_gsm.h
trunk/libmpcodecs/native/xa_gsm_int.h
trunk/libmpcodecs/pullup.h
trunk/libmpcodecs/vd.h
trunk/libmpcodecs/vd_internal.h
trunk/libmpcodecs/vf.h
trunk/libmpcodecs/vf_scale.h
trunk/libmpcodecs/vfcap.h
trunk/libmpcodecs/vqf.h
trunk/libmpdemux/asf.h
trunk/libmpdemux/aviheader.h
trunk/libmpdemux/demux_avs.h
trunk/libmpdemux/demux_rtp.h
trunk/libmpdemux/demux_rtp_internal.h
trunk/libmpdemux/demux_xmms_plugin.h
trunk/libmpdemux/demuxer.h
trunk/libmpdemux/ebml.h
trunk/libmpdemux/genres.h
trunk/libmpdemux/matroska.h
trunk/libmpdemux/mf.h
trunk/libmpdemux/mp3_hdr.h
trunk/libmpdemux/mpeg_hdr.h
trunk/libmpdemux/mpeg_packetizer.h
trunk/libmpdemux/ms_hdr.h
trunk/libmpdemux/muxer.h
trunk/libmpdemux/nuppelvideo.h
trunk/libmpdemux/parse_es.h
trunk/libmpdemux/parse_mp4.h
trunk/libmpdemux/qtpalette.h
trunk/libmpdemux/stheader.h
trunk/libmpdemux/yuv4mpeg.h
trunk/libmpdemux/yuv4mpeg_intern.h
trunk/libvo/aspect.h
trunk/libvo/fastmemcpy.h
trunk/libvo/font_load.h
trunk/libvo/geometry.h
trunk/libvo/gl_common.h
trunk/libvo/gtf.h
trunk/libvo/jpeg_enc.h
trunk/libvo/osd_font.h
trunk/libvo/spuenc.h
trunk/libvo/vesa_lvo.h
trunk/libvo/video_out.h
trunk/libvo/video_out_internal.h
trunk/libvo/videodev_mjpeg.h
trunk/libvo/vo_quartz.h
trunk/libvo/vosub_vidix.h
trunk/libvo/w32_common.h
trunk/libvo/wskeys.h
trunk/libvo/x11_common.h
trunk/m_config.h
trunk/m_option.h
trunk/m_property.h
trunk/m_struct.h
trunk/mangle.h
trunk/metadata.h
trunk/mp_core.h
trunk/mp_fifo.h
trunk/mp_msg.h
trunk/mp_osd.h
trunk/mpbswap.h
trunk/mpcommon.h
trunk/mplayer.h
trunk/osdep/getch2.h
trunk/osdep/glob.h
trunk/osdep/keycodes.h
trunk/osdep/mmap_anon.h
trunk/osdep/shmem.h
trunk/parser-cfg.h
trunk/parser-mecmd.h
trunk/parser-mpcmd.h
trunk/playtree.h
trunk/playtreeparser.h
trunk/stream/audio_in.h
trunk/stream/cache2.h
trunk/stream/cdd.h
trunk/stream/cookies.h
trunk/stream/dvbin.h
trunk/stream/frequencies.h
trunk/stream/http.h
trunk/stream/librtsp/rtsp.h
trunk/stream/librtsp/rtsp_rtp.h
trunk/stream/librtsp/rtsp_session.h
trunk/stream/netstream.h
trunk/stream/network.h
trunk/stream/pnm.h
trunk/stream/pvr.h
trunk/stream/realrtsp/asmrp.h
trunk/stream/realrtsp/real.h
trunk/stream/realrtsp/rmff.h
trunk/stream/realrtsp/sdpplin.h
trunk/stream/realrtsp/xbuffer.h
trunk/stream/rtp.h
trunk/stream/stream.h
trunk/stream/stream_dvd.h
trunk/stream/stream_dvd_common.h
trunk/stream/stream_radio.h
trunk/stream/tcp.h
trunk/stream/tv.h
trunk/stream/tvi_def.h
trunk/stream/tvi_dshow.h
trunk/stream/udp.h
trunk/stream/url.h
trunk/stream/vcd_read.h
trunk/stream/vcd_read_darwin.h
trunk/stream/vcd_read_fbsd.h
trunk/stream/vcd_read_win32.h
trunk/sub_cc.h
trunk/subopt-helper.h
trunk/unrar_exec.h
trunk/xvid_vbr.h
trunk/xvmc_render.h
Modified: trunk/access_mpcontext.h
==============================================================================
--- trunk/access_mpcontext.h (original)
+++ trunk/access_mpcontext.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef ACCESS_MPCONTEXT_H
-#define ACCESS_MPCONTEXT_H
+#ifndef MPLAYER_ACCESS_MPCONTEXT_H
+#define MPLAYER_ACCESS_MPCONTEXT_H
struct MPContext;
const void *mpctx_get_video_out(struct MPContext *mpctx);
@@ -10,4 +10,4 @@ void *mpctx_get_mixer(struct MPContext *
int mpctx_get_global_sub_size(struct MPContext *mpctx);
int mpctx_get_osd_function(struct MPContext *mpctx);
-#endif /* ACCESS_MPCONTEXT_H */
+#endif /* MPLAYER_ACCESS_MPCONTEXT_H */
Modified: trunk/asxparser.h
==============================================================================
--- trunk/asxparser.h (original)
+++ trunk/asxparser.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef ASXPARSER_H
-#define ASXPARSER_H
+#ifndef MPLAYER_ASXPARSER_H
+#define MPLAYER_ASXPARSER_H
typedef struct ASX_Parser_t ASX_Parser_t;
@@ -49,4 +49,4 @@ typedef void (*ASX_FreeFunc)(void* arg);
void
asx_list_free(void* list_ptr,ASX_FreeFunc free_func);
-#endif /* ASXPARSER_H */
+#endif /* MPLAYER_ASXPARSER_H */
Modified: trunk/cfg-mencoder.h
==============================================================================
--- trunk/cfg-mencoder.h (original)
+++ trunk/cfg-mencoder.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef CFG_MENCODER_H
-#define CFG_MENCODER_H
+#ifndef MPLAYER_CFG_MENCODER_H
+#define MPLAYER_CFG_MENCODER_H
/*
* config for cfgparser
@@ -268,4 +268,4 @@ const m_option_t mencoder_opts[]={
{NULL, NULL, 0, 0, 0, 0, NULL}
};
-#endif /* CFG_MENCODER.H */
+#endif /* MPLAYER_CFG_MENCODER_H */
Modified: trunk/cfg-mplayer.h
==============================================================================
--- trunk/cfg-mplayer.h (original)
+++ trunk/cfg-mplayer.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef CFG_MPLAYER_H
-#define CFG_MPLAYER_H
+#ifndef MPLAYER_CFG_MPLAYER_H
+#define MPLAYER_CFG_MPLAYER_H
/*
* config for cfgparser
@@ -368,5 +368,5 @@ const m_option_t mplayer_opts[]={
{NULL, NULL, 0, 0, 0, 0, NULL}
};
-#endif /* CFG_MPLAYER_H */
+#endif /* MPLAYER_CFG_MPLAYER_H */
Modified: trunk/codec-cfg.h
==============================================================================
--- trunk/codec-cfg.h (original)
+++ trunk/codec-cfg.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef CODEC_CFG_H
-#define CODEC_CFG_H
+#ifndef MPLAYER_CODEC_CFG_H
+#define MPLAYER_CODEC_CFG_H
#define CODEC_CFG_MIN 20070407
@@ -73,4 +73,4 @@ void stringset_free(stringset_t *set);
void stringset_add(stringset_t *set, const char *str);
int stringset_test(stringset_t *set, const char *str);
-#endif /* CODEC_CFG_H */
+#endif /* MPLAYER_CODEC_CFG_H */
Modified: trunk/command.h
==============================================================================
--- trunk/command.h (original)
+++ trunk/command.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef COMMAND_H
-#define COMMAND_H
+#ifndef MPLAYER_COMMAND_H
+#define MPLAYER_COMMAND_H
int run_command(struct MPContext *mpctx, mp_cmd_t *cmd);
char *property_expand_string(struct MPContext *mpctx, char *str);
void property_print_help(void);
-#endif /* COMMAND_H */
+#endif /* MPLAYER_COMMAND_H */
Modified: trunk/cpudetect.h
==============================================================================
--- trunk/cpudetect.h (original)
+++ trunk/cpudetect.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef CPUDETECT_H
-#define CPUDETECT_H
+#ifndef MPLAYER_CPUDETECT_H
+#define MPLAYER_CPUDETECT_H
#define CPUTYPE_I386 3
#define CPUTYPE_I486 4
@@ -57,4 +57,4 @@ void GetCpuCaps(CpuCaps *caps);
/* returned value is malloc()'ed so free() it after use */
char *GetCpuFriendlyName(unsigned int regs[], unsigned int regs2[]);
-#endif /* CPUDETECT_H */
+#endif /* MPLAYER_CPUDETECT_H */
Modified: trunk/cputable.h
==============================================================================
--- trunk/cputable.h (original)
+++ trunk/cputable.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* Family F codenames owe much thanks to Neil Phillips, author of x86test.
*/
-#ifndef CPUTABLE_H
-#define CPUTABLE_H
+#ifndef MPLAYER_CPUTABLE_H
+#define MPLAYER_CPUTABLE_H
#define MAX_VENDORS 8 /* Number of CPU Vendors */
@@ -529,4 +529,4 @@ static const struct {
{"GenuineTMx86","Transmeta"}
};
-#endif /* CPUTABLE_H */
+#endif /* MPLAYER_CPUTABLE_H */
Modified: trunk/drivers/generic_math.h
==============================================================================
--- trunk/drivers/generic_math.h (original)
+++ trunk/drivers/generic_math.h Fri Feb 22 10:09:46 2008
@@ -19,8 +19,8 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef GENERIC_MATH_H
-#define GENERIC_MATH_H
+#ifndef MPLAYER_GENERIC_MATH_H
+#define MPLAYER_GENERIC_MATH_H
typedef struct gen_sincos
{
@@ -269,4 +269,4 @@ static double inline gen_cos(double x)
#undef cos
#define cos(x) gen_cos(x)
-#endif /* GENERIC_MATH_H */
+#endif /* MPLAYER_GENERIC_MATH_H */
Modified: trunk/drivers/mga_vid.h
==============================================================================
--- trunk/drivers/mga_vid.h (original)
+++ trunk/drivers/mga_vid.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef MGA_VID_H
-#define MGA_VID_H
+#ifndef MPLAYER_MGA_VID_H
+#define MPLAYER_MGA_VID_H
typedef struct mga_vid_config_s
{
@@ -65,4 +65,4 @@ uint32_t num_frames;
#define MGA_VID_VERSION 0x0201
-#endif /* MGA_VID_H */
+#endif /* MPLAYER_MGA_VID_H */
Modified: trunk/drivers/radeon.h
==============================================================================
--- trunk/drivers/radeon.h (original)
+++ trunk/drivers/radeon.h Fri Feb 22 10:09:46 2008
@@ -20,8 +20,8 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef RADEON_H
-#define RADEON_H
+#ifndef MPLAYER_RADEON_H
+#define MPLAYER_RADEON_H
/* radeon PCI ids */
@@ -2055,4 +2055,4 @@
/* End of field default values. */
-#endif /* RADEON_H */
+#endif /* MPLAYER_RADEON_H */
Modified: trunk/drivers/radeon_vid.h
==============================================================================
--- trunk/drivers/radeon_vid.h (original)
+++ trunk/drivers/radeon_vid.h Fri Feb 22 10:09:46 2008
@@ -22,8 +22,8 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef RADEON_VID_H
-#define RADEON_VID_H
+#ifndef MPLAYER_RADEON_VID_H
+#define MPLAYER_RADEON_VID_H
typedef struct mga_vid_config_s
{
@@ -123,4 +123,4 @@ uint32_t num_frames;
#define MGA_VID_VERSION 0x0201
-#endif /* RADEON_VID_H */
+#endif /* MPLAYER_RADEON_VID_H */
Modified: trunk/drivers/tdfx_vid.h
==============================================================================
--- trunk/drivers/tdfx_vid.h (original)
+++ trunk/drivers/tdfx_vid.h Fri Feb 22 10:09:46 2008
@@ -18,8 +18,8 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#ifndef TDFX_VID_H
-#define TDFX_VID_H
+#ifndef MPLAYER_TDFX_VID_H
+#define MPLAYER_TDFX_VID_H
#define TDFX_VID_VERSION 1
@@ -125,4 +125,4 @@ typedef struct tdfx_vid_overlay_s {
#define TDFX_VID_OVERLAY_ON _IO ('J', 8)
#define TDFX_VID_OVERLAY_OFF _IO ('J', 9)
-#endif /* TDFX_VID_H */
+#endif /* MPLAYER_TDFX_VID_H */
Modified: trunk/edl.h
==============================================================================
--- trunk/edl.h (original)
+++ trunk/edl.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
// EDL version 0.6
-#ifndef EDL_H
-#define EDL_H
+#ifndef MPLAYER_EDL_H
+#define MPLAYER_EDL_H
#define EDL_SKIP 0
#define EDL_MUTE 1
@@ -26,4 +26,4 @@ extern char *edl_output_filename; // fil
void free_edl(edl_record_ptr next_edl_record); // free's entire EDL list.
edl_record_ptr edl_parse_file(void); // fills EDL stack
-#endif /* EDL_H */
+#endif /* MPLAYER_EDL_H */
Modified: trunk/fmt-conversion.h
==============================================================================
--- trunk/fmt-conversion.h (original)
+++ trunk/fmt-conversion.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef FMT_CONVERSION_H
-#define FMT_CONVERSION_H
+#ifndef MPLAYER_FMT_CONVERSION_H
+#define MPLAYER_FMT_CONVERSION_H
#ifdef USE_LIBAVUTIL_SO
#include <ffmpeg/avutil.h>
@@ -73,4 +73,4 @@ enum PixelFormat imgfmt2pixfmt(int fmt)
return PIX_FMT_NONE;
}
-#endif /* FMT_CONVERSION_H */
+#endif /* MPLAYER_FMT_CONVERSION_H */
Modified: trunk/get_path.h
==============================================================================
--- trunk/get_path.h (original)
+++ trunk/get_path.h Fri Feb 22 10:09:46 2008
@@ -18,10 +18,10 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef GET_PATH_H
-#define GET_PATH_H
+#ifndef MPLAYER_GET_PATH_H
+#define MPLAYER_GET_PATH_H
char *get_path(const char *filename);
void set_path_env();
-#endif /* GET_PATH_H */
+#endif /* MPLAYER_GET_PATH_H */
Modified: trunk/gui/app.h
==============================================================================
--- trunk/gui/app.h (original)
+++ trunk/gui/app.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_APP_H
-#define GUI_APP_H
+#ifndef MPLAYER_GUI_APP_H
+#define MPLAYER_GUI_APP_H
#include "bitmap.h"
#include "wm/ws.h"
@@ -184,4 +183,4 @@ extern void btnModify( int event,float s
extern float btnGetValue( int event );
extern void btnSet( int event,int set );
-#endif /* GUI_APP_H */
+#endif /* MPLAYER_GUI_APP_H */
Modified: trunk/gui/bitmap.h
==============================================================================
--- trunk/gui/bitmap.h (original)
+++ trunk/gui/bitmap.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GUI_BITMAP_H
-#define GUI_BITMAP_H
+#ifndef MPLAYER_GUI_BITMAP_H
+#define MPLAYER_GUI_BITMAP_H
typedef struct txSample
{
@@ -13,4 +13,4 @@ typedef struct txSample
int bpRead( char * fname, txSample * bf );
void Convert32to1( txSample * in,txSample * out,int adaptivlimit );
-#endif /* GUI_BITMAP_H */
+#endif /* MPLAYER_GUI_BITMAP_H */
Modified: trunk/gui/cfg.h
==============================================================================
--- trunk/gui/cfg.h (original)
+++ trunk/gui/cfg.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_CFG_H
-#define GUI_CFG_H
+#ifndef MPLAYER_GUI_CFG_H
+#define MPLAYER_GUI_CFG_H
extern int gtkEnableAudioEqualizer;
@@ -59,4 +58,4 @@ extern gtkASS_t gtkASS;
extern int cfg_read( void );
extern int cfg_write( void );
-#endif /* GUI_CFG_H */
+#endif /* MPLAYER_GUI_CFG_H */
Modified: trunk/gui/interface.h
==============================================================================
--- trunk/gui/interface.h (original)
+++ trunk/gui/interface.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_INTERFACE_H
-#define GUI_INTERFACE_H
+#ifndef MPLAYER_GUI_INTERFACE_H
+#define MPLAYER_GUI_INTERFACE_H
#include "../config.h"
#include "mplayer/play.h"
@@ -223,4 +222,4 @@ extern char * gstrchr( char * str,int c
sprintf( s,"%s/%s",d,n ); \
}
-#endif /* GUI_INTERFACE_H */
+#endif /* MPLAYER_GUI_INTERFACE_H */
Modified: trunk/gui/mplayer/gmplayer.h
==============================================================================
--- trunk/gui/mplayer/gmplayer.h (original)
+++ trunk/gui/mplayer/gmplayer.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_GMPLAYER_H
-#define GUI_GMPLAYER_H
+#ifndef MPLAYER_GUI_GMPLAYER_H
+#define MPLAYER_GUI_GMPLAYER_H
extern int mplSubRender;
extern int mplMainRender;
@@ -31,4 +30,4 @@ extern void mplMenuMouseHandle( int X,in
extern void mplPBInit( void );
extern void mplPBShow( int x, int y );
-#endif /* GUI_GMPLAYER_H */
+#endif /* MPLAYER_GUI_GMPLAYER_H */
Modified: trunk/gui/mplayer/gtk/about.h
==============================================================================
--- trunk/gui/mplayer/gtk/about.h (original)
+++ trunk/gui/mplayer/gtk/about.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_ABOUT_H
-#define GUI_ABOUT_H
+#ifndef MPLAYER_GUI_ABOUT_H
+#define MPLAYER_GUI_ABOUT_H
#include <gtk/gtk.h>
@@ -9,4 +8,4 @@ extern GtkWidget * About;
extern GtkWidget * create_About( void );
extern void ShowAboutBox( void );
-#endif /* GUI_ABOUT_H */
+#endif /* MPLAYER_GUI_ABOUT_H */
Modified: trunk/gui/mplayer/gtk/eq.h
==============================================================================
--- trunk/gui/mplayer/gtk/eq.h (original)
+++ trunk/gui/mplayer/gtk/eq.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_EQ_H
-#define GUI_EQ_H
+#ifndef MPLAYER_GUI_EQ_H
+#define MPLAYER_GUI_EQ_H
#include <gtk/gtk.h>
@@ -9,4 +8,4 @@ extern GtkWidget * Equalizer;
extern GtkWidget * create_Equalizer( void );
extern void ShowEqualizer( void );
-#endif /* GUI_EQ_H */
+#endif /* MPLAYER_GUI_EQ_H */
Modified: trunk/gui/mplayer/gtk/fs.h
==============================================================================
--- trunk/gui/mplayer/gtk/fs.h (original)
+++ trunk/gui/mplayer/gtk/fs.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GUI_FS_H
-#define GUI_FS_H
+#ifndef MPLAYER_GUI_FS_H
+#define MPLAYER_GUI_FS_H
#include <gtk/gtk.h>
@@ -18,4 +18,4 @@ extern void ShowFileSelect( int type, in
extern GtkWidget * create_FileSelect( void );
-#endif /* GUI_FS_H */
+#endif /* MPLAYER_GUI_FS_H */
Modified: trunk/gui/mplayer/gtk/gtk_common.h
==============================================================================
--- trunk/gui/mplayer/gtk/gtk_common.h (original)
+++ trunk/gui/mplayer/gtk/gtk_common.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_GTK_COMMON_H
-#define GUI_GTK_COMMON_H
+#ifndef MPLAYER_GUI_GTK_COMMON_H
+#define MPLAYER_GUI_GTK_COMMON_H
#include <gdk/gdkkeysyms.h>
#include <gtk/gtk.h>
@@ -21,4 +20,4 @@ extern GtkWidget * AddVScaler( GtkAdjust
extern GtkWidget * AddComboBox( GtkWidget * parent );
extern void WidgetDestroy( GtkWidget * widget,GtkWidget ** widget_pointer );
-#endif /* GUI_GTK_COMMON_H */
+#endif /* MPLAYER_GUI_GTK_COMMON_H */
Modified: trunk/gui/mplayer/gtk/mb.h
==============================================================================
--- trunk/gui/mplayer/gtk/mb.h (original)
+++ trunk/gui/mplayer/gtk/mb.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_MB_H
-#define GUI_MB_H
+#ifndef MPLAYER_GUI_MB_H
+#define MPLAYER_GUI_MB_H
#include <gtk/gtk.h>
@@ -9,4 +8,4 @@ extern GtkWidget * MessageBox;
extern GtkWidget * create_MessageBox( int type );
extern void ShowMessageBox( const char * msg );
-#endif /* GUI_MB_H */
+#endif /* MPLAYER_GUI_MB_H */
Modified: trunk/gui/mplayer/gtk/menu.h
==============================================================================
--- trunk/gui/mplayer/gtk/menu.h (original)
+++ trunk/gui/mplayer/gtk/menu.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GUI_MENU_H
-#define GUI_MENU_H
+#ifndef MPLAYER_GUI_MENU_H
+#define MPLAYER_GUI_MENU_H
#include <gtk/gtk.h>
@@ -10,4 +10,4 @@ extern GtkWidget * AddSubMenu( GtkWidget
extern GtkWidget * AddSeparator( GtkWidget * Menu );
extern GtkWidget * create_PopUpMenu( void );
-#endif /* GUI_MENU_H */
+#endif /* MPLAYER_GUI_MENU_H */
Modified: trunk/gui/mplayer/gtk/opts.h
==============================================================================
--- trunk/gui/mplayer/gtk/opts.h (original)
+++ trunk/gui/mplayer/gtk/opts.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_OPTS_H
-#define GUI_OPTS_H
+#ifndef MPLAYER_GUI_OPTS_H
+#define MPLAYER_GUI_OPTS_H
#include <gtk/gtk.h>
@@ -13,4 +12,4 @@ extern GtkWidget * create_AudioConfig( v
extern void ShowPreferences( void );
-#endif /* GUI_OPTS_H */
+#endif /* MPLAYER_GUI_OPTS_H */
Modified: trunk/gui/mplayer/gtk/pl.h
==============================================================================
--- trunk/gui/mplayer/gtk/pl.h (original)
+++ trunk/gui/mplayer/gtk/pl.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_PL_H
-#define GUI_PL_H
+#ifndef MPLAYER_GUI_PL_H
+#define MPLAYER_GUI_PL_H
#include <gtk/gtk.h>
@@ -9,4 +8,4 @@ extern void HidePlayList( void );
extern GtkWidget * create_PlayList (void);
-#endif /* GUI_PL_H */
+#endif /* MPLAYER_GUI_PL_H */
Modified: trunk/gui/mplayer/gtk/sb.h
==============================================================================
--- trunk/gui/mplayer/gtk/sb.h (original)
+++ trunk/gui/mplayer/gtk/sb.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GUI_SB_H
-#define GUI_SB_H
+#ifndef MPLAYER_GUI_SB_H
+#define MPLAYER_GUI_SB_H
#include <gtk/gtk.h>
@@ -9,4 +9,4 @@ extern GtkWidget * SkinBrowser;
extern void ShowSkinBrowser( void );
extern GtkWidget * create_SkinBrowser( void );
-#endif /* GUI_SB_H */
+#endif /* MPLAYER_GUI_SB_H */
Modified: trunk/gui/mplayer/gtk/url.h
==============================================================================
--- trunk/gui/mplayer/gtk/url.h (original)
+++ trunk/gui/mplayer/gtk/url.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_URL_H
-#define GUI_URL_H
+#ifndef MPLAYER_GUI_URL_H
+#define MPLAYER_GUI_URL_H
extern GtkWidget * URL;
extern int gtkVURLDialogBox;
@@ -8,4 +7,4 @@ extern int gtkVURLDialogBox;
extern void ShowURLDialogBox( void );
extern GtkWidget * create_URL( void );
-#endif /* GUI_URL_H */
+#endif /* MPLAYER_GUI_URL_H */
Modified: trunk/gui/mplayer/gui_common.h
==============================================================================
--- trunk/gui/mplayer/gui_common.h (original)
+++ trunk/gui/mplayer/gui_common.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_GUI_COMMON_H
-#define GUI_GUI_COMMON_H
+#ifndef MPLAYER_GUI_GUI_COMMON_H
+#define MPLAYER_GUI_GUI_COMMON_H
#include <stdlib.h>
#include <stdio.h>
@@ -18,4 +17,4 @@ extern void PutImage( txSample * bf,int
extern void SimplePotmeterPutImage( txSample * bf,int x,int y,float frac );
extern void Render( wsTWindow * window,wItem * Items,int nrItems,char * db,int size );
-#endif /* GUI_GUI_COMMON_H */
+#endif /* MPLAYER_GUI_GUI_COMMON_H */
Modified: trunk/gui/mplayer/play.h
==============================================================================
--- trunk/gui/mplayer/play.h (original)
+++ trunk/gui/mplayer/play.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_PLAY_H
-#define GUI_PLAY_H
+#ifndef MPLAYER_GUI_PLAY_H
+#define MPLAYER_GUI_PLAY_H
#include "../config.h"
@@ -31,4 +30,4 @@ extern void EventHandling( void );
extern void mplSetFileName( char * dir,char * name,int type );
-#endif /* GUI_PLAY_H */
+#endif /* MPLAYER_GUI_PLAY_H */
Modified: trunk/gui/mplayer/widgets.h
==============================================================================
--- trunk/gui/mplayer/widgets.h (original)
+++ trunk/gui/mplayer/widgets.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_WIDGETS_H
-#define GUI_WIDGETS_H
+#ifndef MPLAYER_GUI_WIDGETS_H
+#define MPLAYER_GUI_WIDGETS_H
#include <stdio.h>
#include <stdlib.h>
@@ -60,4 +59,4 @@ extern void gtkMessageBox( int type,cons
extern void gtkSetLayer( GtkWidget * wdg );
extern void gtkActive( GtkWidget * wdg );
-#endif /* GUI_WIDGETS_H */
+#endif /* MPLAYER_GUI_WIDGETS_H */
Modified: trunk/gui/skin/cut.h
==============================================================================
--- trunk/gui/skin/cut.h (original)
+++ trunk/gui/skin/cut.h Fri Feb 22 10:09:46 2008
@@ -1,10 +1,9 @@
-
-#ifndef GUI_CUT_H
-#define GUI_CUT_H
+#ifndef MPLAYER_GUI_CUT_H
+#define MPLAYER_GUI_CUT_H
extern void cutItem( char * in,char * out,char sep,int num );
extern int cutItemToInt( char * in,char sep,int num );
extern float cutItemToFloat( char * in,char sep,int num );
extern void cutChunk( char * in,char * s1 );
-#endif /* GUI_CUT_H */
+#endif /* MPLAYER_GUI_CUT_H */
Modified: trunk/gui/skin/font.h
==============================================================================
--- trunk/gui/skin/font.h (original)
+++ trunk/gui/skin/font.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_FONT_H
-#define GUI_FONT_H
+#ifndef MPLAYER_GUI_FONT_H
+#define MPLAYER_GUI_FONT_H
#include "bitmap.h"
#include "app.h"
@@ -34,4 +33,4 @@ extern int fntTextWidth( int id,char *
extern int fntRead( char * path,char * fname );
extern txSample * fntRender( wItem * item,int px,const char * fmt,... );
-#endif /* GUI_FONT_H */
+#endif /* MPLAYER_GUI_FONT_H */
Modified: trunk/gui/skin/skin.h
==============================================================================
--- trunk/gui/skin/skin.h (original)
+++ trunk/gui/skin/skin.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_SKIN_H
-#define GUI_SKIN_H
+#ifndef MPLAYER_GUI_SKIN_H
+#define MPLAYER_GUI_SKIN_H
#include "app.h"
@@ -15,4 +14,4 @@ extern char * trimleft( char * in );
extern char * strswap( char * in,char what,char whereof );
extern char * trim( char * in );
-#endif /* GUI_SKIN_H */
+#endif /* MPLAYER_GUI_SKIN_H */
Modified: trunk/gui/win32/dialogs.h
==============================================================================
--- trunk/gui/win32/dialogs.h (original)
+++ trunk/gui/win32/dialogs.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef GUI_DIALOGS_H
-#define GUI_DIALOGS_H
+#ifndef MPLAYER_GUI_DIALOGS_H
+#define MPLAYER_GUI_DIALOGS_H
#define TBS_TOOLTIPS 0x0100
#define WM_SYSTRAY (WM_USER+1)
@@ -131,4 +131,4 @@
#define GTK_MB_WARNING 0x4
#define GTK_MB_SIMPLE 0x8
-#endif /* GUI_DIALOGS_H */
+#endif /* MPLAYER_GUI_DIALOGS_H */
Modified: trunk/gui/win32/gui.h
==============================================================================
--- trunk/gui/win32/gui.h (original)
+++ trunk/gui/win32/gui.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef GUI_GUI_H
-#define GUI_GUI_H
+#ifndef MPLAYER_GUI_GUI_H
+#define MPLAYER_GUI_GUI_H
#include "config.h"
#include "mplayer.h"
@@ -117,4 +117,4 @@ extern void display_eqwindow(gui_t *gui)
extern void display_prefswindow(gui_t *gui);
extern void display_opensubtitlewindow(gui_t *gui);
-#endif /* GUI_GUI_H */
+#endif /* MPLAYER_GUI_GUI_H */
Modified: trunk/gui/win32/playlist.h
==============================================================================
--- trunk/gui/win32/playlist.h (original)
+++ trunk/gui/win32/playlist.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef GUI_PLAYLIST_H
-#define GUI_PLAYLIST_H
+#ifndef MPLAYER_GUI_PLAYLIST_H
+#define MPLAYER_GUI_PLAYLIST_H
typedef struct
{
@@ -56,4 +56,4 @@ struct playlist_t
extern playlist_t *create_playlist(void);
extern BOOL adddirtoplaylist(playlist_t *playlist, const char* path, BOOL recursive);
-#endif /* GUI_PLAYLIST_H */
+#endif /* MPLAYER_GUI_PLAYLIST_H */
Modified: trunk/gui/win32/skinload.h
==============================================================================
--- trunk/gui/win32/skinload.h (original)
+++ trunk/gui/win32/skinload.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef GUI_SKINLOAD_H
-#define GUI_SKINLOAD_H
+#ifndef MPLAYER_GUI_SKINLOAD_H
+#define MPLAYER_GUI_SKINLOAD_H
typedef struct
{
@@ -212,4 +212,4 @@ extern skin_t *loadskin(char *skindir, i
#define evShowWindow 7004
#define evFirstLoad 7005
-#endif /* GUI_SKINLOAD_H */
+#endif /* MPLAYER_GUI_SKINLOAD_H */
Modified: trunk/gui/win32/wincfg.h
==============================================================================
--- trunk/gui/win32/wincfg.h (original)
+++ trunk/gui/win32/wincfg.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef GUI_WINCFG_H
-#define GUI_WINCFG_H
+#ifndef MPLAYER_GUI_WINCFG_H
+#define MPLAYER_GUI_WINCFG_H
extern char *skinName;
extern int sub_window;
@@ -37,4 +37,4 @@ extern int gui_sub_pos_y;
extern int cfg_read(void);
extern int cfg_write(void);
-#endif /* GUI_WINCFG_H */
+#endif /* MPLAYER_GUI_WINCFG_H */
Modified: trunk/gui/wm/ws.h
==============================================================================
--- trunk/gui/wm/ws.h (original)
+++ trunk/gui/wm/ws.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
// Writed by pontscho / fresh!mindworkz
// ----------------------------------------------------------------------------------------------
-#ifndef GUI_WS_H
-#define GUI_WS_H
+#ifndef MPLAYER_GUI_WS_H
+#define MPLAYER_GUI_WS_H
#include <X11/Xlib.h>
#include <X11/Xutil.h>
@@ -257,4 +257,4 @@ extern void wsScreenSaverOff( Display *
#define wgIsRect( X,Y,tX,tY,bX,bY ) ( ( (X) > (tX) )&&( (Y) > (tY) )&&( (X) < (bX) )&&( (Y) < (bY) ) )
-#endif /* GUI_WS_H */
+#endif /* MPLAYER_GUI_WS_H */
Modified: trunk/gui/wm/wskeys.h
==============================================================================
--- trunk/gui/wm/wskeys.h (original)
+++ trunk/gui/wm/wskeys.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_WSKEYS_H
-#define GUI_WSKEYS_H
+#ifndef MPLAYER_GUI_WSKEYS_H
+#define MPLAYER_GUI_WSKEYS_H
#define wsKeyNone -1
@@ -161,4 +160,4 @@ typedef struct
extern const TwsKeyNames wsKeyNames[ wsKeyNumber ];
-#endif /* GUI_WSKEYS_H */
+#endif /* MPLAYER_GUI_WSKEYS_H */
Modified: trunk/gui/wm/wsmkeys.h
==============================================================================
--- trunk/gui/wm/wsmkeys.h (original)
+++ trunk/gui/wm/wsmkeys.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GUI_WSMKEYS_H
-#define GUI_WSMKEYS_H
+#ifndef MPLAYER_GUI_WSMKEYS_H
+#define MPLAYER_GUI_WSMKEYS_H
#include "wskeys.h"
@@ -65,4 +65,4 @@ const TwsKeyNames wsKeyNames[ wsKeyNumbe
{ wsKeyNone, "None" }
};
-#endif /* GUI_WSMKEYS_H */
+#endif /* MPLAYER_GUI_WSMKEYS_H */
Modified: trunk/gui/wm/wsxdnd.h
==============================================================================
--- trunk/gui/wm/wsxdnd.h (original)
+++ trunk/gui/wm/wsxdnd.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef GUI_WSXDND_H
-#define GUI_WSXDND_H
+#ifndef MPLAYER_GUI_WSXDND_H
+#define MPLAYER_GUI_WSXDND_H
void wsXDNDInitialize(void);
@@ -50,4 +49,4 @@ void wsXDNDClearAwareness(wsTWindow* win
/* XdndFinished */
#define XDND_FINISHED_TARGET_WIN(e) ((e)->xclient.data.l[0])
-#endif /* GUI_WSXDND_H */
+#endif /* MPLAYER_GUI_WSXDND_H */
Modified: trunk/input/ar.h
==============================================================================
--- trunk/input/ar.h (original)
+++ trunk/input/ar.h Fri Feb 22 10:09:46 2008
@@ -20,8 +20,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef INPUT_AR_H
-#define INPUT_AR_H
+#ifndef MPLAYER_AR_H
+#define MPLAYER_AR_H
#define AR_BASE 0x500
#define AR_PLAY (AR_BASE + 0)
@@ -39,4 +39,4 @@ int mp_input_ar_init(void);
int mp_input_ar_read(int fd);
void mp_input_ar_close(int fd);
-#endif /* INPUT_AR_H */
+#endif /* MPLAYER_AR_H */
Modified: trunk/input/input.h
==============================================================================
--- trunk/input/input.h (original)
+++ trunk/input/input.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef INPUT_H
-#define INPUT_H
+#ifndef MPLAYER_INPUT_H
+#define MPLAYER_INPUT_H
// All command IDs
#define MP_CMD_SEEK 0
@@ -302,4 +302,4 @@ mp_input_check_interrupt(int time);
extern int async_quit_request;
-#endif /* INPUT_H */
+#endif /* MPLAYER_INPUT_H */
Modified: trunk/input/joystick.h
==============================================================================
--- trunk/input/joystick.h (original)
+++ trunk/input/joystick.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef JOYSTICK_H
-#define JOYSTICK_H
+#ifndef MPLAYER_JOYSTICK_H
+#define MPLAYER_JOYSTICK_H
#define JOY_BASE (0x100+128)
#define JOY_AXIS0_PLUS (JOY_BASE+0)
@@ -39,4 +39,4 @@ int mp_input_joystick_init(char* dev);
int mp_input_joystick_read(int fd);
-#endif /* JOYSTICK_H */
+#endif /* MPLAYER_JOYSTICK_H */
Modified: trunk/input/lirc.h
==============================================================================
--- trunk/input/lirc.h (original)
+++ trunk/input/lirc.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef LIRC_H
-#define LIRC_H
+#ifndef MPLAYER_LIRC_H
+#define MPLAYER_LIRC_H
int
mp_input_lirc_init(void);
@@ -10,4 +10,4 @@ mp_input_lirc_read(int fd,char* dest, in
void
mp_input_lirc_close(int fd);
-#endif /* LIRC_H */
+#endif /* MPLAYER_LIRC_H */
Modified: trunk/input/mouse.h
==============================================================================
--- trunk/input/mouse.h (original)
+++ trunk/input/mouse.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MOUSE_H
-#define MOUSE_H
+#ifndef MPLAYER_MOUSE_H
+#define MPLAYER_MOUSE_H
#define MOUSE_BASE ((0x100+256)|MP_NO_REPEAT_KEY)
#define MOUSE_BTN0 (MOUSE_BASE+0)
@@ -25,4 +25,4 @@
#define MOUSE_BTN8_DBL (MOUSE_BASE_DBL+8)
#define MOUSE_BTN9_DBL (MOUSE_BASE_DBL+9)
-#endif /* MOUSE_H */
+#endif /* MPLAYER_MOUSE_H */
Modified: trunk/libaf/af.h
==============================================================================
--- trunk/libaf/af.h (original)
+++ trunk/libaf/af.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AF_H
-#define AF_H
+#ifndef MPLAYER_AF_H
+#define MPLAYER_AF_H
#include <stdio.h>
@@ -354,4 +354,4 @@ extern af_msg_cfg_t af_msg_cfg; // Messa
#endif
//! \}
-#endif /* AF_H */
+#endif /* MPLAYER_AF_H */
Modified: trunk/libaf/af_format.h
==============================================================================
--- trunk/libaf/af_format.h (original)
+++ trunk/libaf/af_format.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,9 @@
/* The sample format system used lin libaf is based on bitmasks. The
format definition only refers to the storage format not the
resolution. */
-#ifndef AF_FORMAT_H
-#define AF_FORMAT_H
+
+#ifndef MPLAYER_AF_FORMAT_H
+#define MPLAYER_AF_FORMAT_H
#ifndef MPLAYER_CONFIG_H
#error af_format.h needs config.h
@@ -93,4 +94,4 @@ extern int af_bits2fmt(int bits);
extern char* af_fmt2str(int format, char* str, int size);
extern const char* af_fmt2str_short(int format);
-#endif /* AF_FORMAT_H */
+#endif /* MPLAYER_AF_FORMAT_H */
Modified: trunk/libaf/af_hrtf.h
==============================================================================
--- trunk/libaf/af_hrtf.h (original)
+++ trunk/libaf/af_hrtf.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AF_HRTF_H
-#define AF_HRTF_H
+#ifndef MPLAYER_AF_HRTF_H
+#define MPLAYER_AF_HRTF_H
#define HRTF_MIX_51 0
#define HRTF_MIX_STEREO 1
@@ -490,4 +490,4 @@ float cr_filt[128] = {
-0.0002379619297227554, 0.0007130120121089036
};
-#endif /* AF_HRTF_H */
+#endif /* MPLAYER_AF_HRTF_H */
Modified: trunk/libaf/af_mp.h
==============================================================================
--- trunk/libaf/af_mp.h (original)
+++ trunk/libaf/af_mp.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
/* Include file for mplayer specific defines and includes */
-#ifndef AF_MP_H
-#define AF_MP_H
+#ifndef MPLAYER_AF_MP_H
+#define MPLAYER_AF_MP_H
#include "config.h"
#include "mp_msg.h"
@@ -19,4 +19,4 @@
#define af_msg(lev, args... ) \
mp_msg(MSGT_AFILTER,(((lev)<0)?((lev)+3):(((lev)==0)?MSGL_INFO:((lev)+5))), ##args )
-#endif /* AF_MP_H */
+#endif /* MPLAYER_AF_MP_H */
Modified: trunk/libaf/control.h
==============================================================================
--- trunk/libaf/control.h (original)
+++ trunk/libaf/control.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AF_CONTROL_H
-#define AF_CONTROL_H
+#ifndef MPLAYER_CONTROL_H
+#define MPLAYER_CONTROL_H
/*********************************************
// Control info struct.
@@ -234,4 +234,4 @@ typedef struct af_control_ext_s{
#define AF_CONTROL_PLAYBACK_SPEED 0x00002500 | AF_CONTROL_FILTER_SPECIFIC
#define AF_CONTROL_SCALETEMPO_AMOUNT 0x00002600 | AF_CONTROL_FILTER_SPECIFIC
-#endif /* AF_CONTROL_H */
+#endif /* MPLAYER_CONTROL_H */
Modified: trunk/libaf/dsp.h
==============================================================================
--- trunk/libaf/dsp.h (original)
+++ trunk/libaf/dsp.h Fri Feb 22 10:09:46 2008
@@ -8,8 +8,8 @@
//=============================================================================
*/
-#ifndef DSP_H
-#define DSP_H
+#ifndef MPLAYER_DSP_H
+#define MPLAYER_DSP_H
/* Implementation of routines used for DSP */
@@ -19,4 +19,4 @@
#include <window.h>
#include <filter.h>
-#endif /* DSP_H */
+#endif /* MPLAYER_DSP_H */
Modified: trunk/libaf/equalizer.h
==============================================================================
--- trunk/libaf/equalizer.h (original)
+++ trunk/libaf/equalizer.h Fri Feb 22 10:09:46 2008
@@ -8,8 +8,8 @@
//=============================================================================
*/
-#ifndef EQUALIZER_H
-#define EQUALIZER_H
+#ifndef MPLAYER_EQUALIZER_H
+#define MPLAYER_EQUALIZER_H
/* Equalizer plugin header file defines struct used for setting or
getting the gain of a specific channel and frequency */
@@ -35,4 +35,4 @@ nr. center frequency
9 16.00 kHz
*/
-#endif /* EQUALIZER_H */
+#endif /* MPLAYER_EQUALIZER_H */
Modified: trunk/libaf/filter.h
==============================================================================
--- trunk/libaf/filter.h (original)
+++ trunk/libaf/filter.h Fri Feb 22 10:09:46 2008
@@ -8,12 +8,12 @@
//=============================================================================
*/
-#if !defined DSP_H
+#if !defined MPLAYER_DSP_H
# error "Never use <filter.h> directly; include <dsp.h> instead"
#endif
-#ifndef FILTER_H
-#define FILTER_H
+#ifndef MPLAYER_FILTER_H
+#define MPLAYER_FILTER_H
// Design and implementation of different types of digital filters
@@ -66,4 +66,4 @@ extern int af_filter_szxform(_ftype_t* a
xq[xi]=(xq)[(xi)+(n)]=*(in);\
xi=(++(xi))&((n)-1);
-#endif /* FILTER_H */
+#endif /* MPLAYER_FILTER_H */
Modified: trunk/libaf/reorder_ch.h
==============================================================================
--- trunk/libaf/reorder_ch.h (original)
+++ trunk/libaf/reorder_ch.h Fri Feb 22 10:09:46 2008
@@ -20,8 +20,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef REORDER_CH_H
-#define REORDER_CH_H
+#ifndef MPLAYER_REORDER_CH_H
+#define MPLAYER_REORDER_CH_H
// L - Left
// R - Right
@@ -122,4 +122,4 @@ void reorder_channel_nch(void *buf,
int samples,
int samplesize);
-#endif /* REORDER_CH_H */
+#endif /* MPLAYER_REORDER_CH_H */
Modified: trunk/libaf/window.h
==============================================================================
--- trunk/libaf/window.h (original)
+++ trunk/libaf/window.h Fri Feb 22 10:09:46 2008
@@ -15,12 +15,12 @@
coefficients will be stored.
*/
-#if !defined DSP_H
+#if !defined MPLAYER_DSP_H
# error "Never use <window.h> directly; include <dsp.h> instead"
#endif
-#ifndef WINDOW_H
-#define WINDOW_H
+#ifndef MPLAYER_WINDOW_H
+#define MPLAYER_WINDOW_H
extern void af_window_boxcar(int n, _ftype_t* w);
extern void af_window_triang(int n, _ftype_t* w);
@@ -30,4 +30,4 @@ extern void af_window_blackman(int n,_ft
extern void af_window_flattop(int n,_ftype_t* w);
extern void af_window_kaiser(int n, _ftype_t* w,_ftype_t b);
-#endif /* WINDOW_H */
+#endif /* MPLAYER_WINDOW_H */
Modified: trunk/libao2/audio_out.h
==============================================================================
--- trunk/libao2/audio_out.h (original)
+++ trunk/libao2/audio_out.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef AUDIO_OUT_H
-#define AUDIO_OUT_H
+#ifndef MPLAYER_AUDIO_OUT_H
+#define MPLAYER_AUDIO_OUT_H
typedef struct ao_info_s
{
@@ -72,4 +71,4 @@ typedef struct ao_control_vol_s {
float right;
} ao_control_vol_t;
-#endif /* AUDIO_OUT_H */
+#endif /* MPLAYER_AUDIO_OUT_H */
Modified: trunk/libao2/audio_out_internal.h
==============================================================================
--- trunk/libao2/audio_out_internal.h (original)
+++ trunk/libao2/audio_out_internal.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AUDIO_OUT_INTERNAL_H
-#define AUDIO_OUT_INTERNAL_H
+#ifndef MPLAYER_AUDIO_OUT_INTERNAL_H
+#define MPLAYER_AUDIO_OUT_INTERNAL_H
// prototypes:
//static ao_info_t info;
@@ -27,4 +27,4 @@ static void audio_resume(void);
audio_resume\
};
-#endif /* AUDIO_OUT_INTERNAL_H */
+#endif /* MPLAYER_AUDIO_OUT_INTERNAL_H */
Modified: trunk/libmenu/menu.h
==============================================================================
--- trunk/libmenu/menu.h (original)
+++ trunk/libmenu/menu.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MENU_H
-#define MENU_H
+#ifndef MPLAYER_MENU_H
+#define MPLAYER_MENU_H
struct menu_priv_s;
typedef struct menu_s menu_t;
@@ -92,4 +92,4 @@ void menu_draw_text_full(mp_image_t* mpi
void menu_draw_box(mp_image_t* mpi, unsigned char grey, unsigned char alpha, int x, int y, int w, int h);
-#endif /* MENU_H */
+#endif /* MPLAYER_MENU_H */
Modified: trunk/libmenu/menu_list.h
==============================================================================
--- trunk/libmenu/menu_list.h (original)
+++ trunk/libmenu/menu_list.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MENU_LIST_H
-#define MENU_LIST_H
+#ifndef MPLAYER_MENU_LIST_H
+#define MPLAYER_MENU_LIST_H
typedef struct list_entry_s list_entry_t;
@@ -83,4 +83,4 @@ extern const menu_list_priv_t menu_list_
{ "ptr-bg-alpha", M_ST_OFF(menu_list_priv_t,ptr_bg_alpha), \
CONF_TYPE_INT, M_OPT_RANGE, 0, 255, NULL } \
-#endif /* MENU_LIST_H */
+#endif /* MPLAYER_MENU_LIST_H */
Modified: trunk/libmpcodecs/ad.h
==============================================================================
--- trunk/libmpcodecs/ad.h (original)
+++ trunk/libmpcodecs/ad.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AD_H
-#define AD_H
+#ifndef MPLAYER_AD_H
+#define MPLAYER_AD_H
#include "mpc_info.h"
typedef mp_codec_info_t ad_info_t;
@@ -30,4 +30,4 @@ extern ad_functions_t* mpcodecs_ad_drive
// fallback: use hw mixer in libao
#define ADCTRL_SET_VOLUME 4 /* set volume (used for mp3lib and liba52) */
-#endif /* AD_H */
+#endif /* MPLAYER_AD_H */
Modified: trunk/libmpcodecs/ad_internal.h
==============================================================================
--- trunk/libmpcodecs/ad_internal.h (original)
+++ trunk/libmpcodecs/ad_internal.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AD_INTERNAL_H
-#define AD_INTERNAL_H
+#ifndef MPLAYER_AD_INTERNAL_H
+#define MPLAYER_AD_INTERNAL_H
#include "codec-cfg.h"
#include "libaf/af_format.h"
@@ -26,4 +26,4 @@ static int decode_audio(sh_audio_t *sh,u
decode_audio\
};
-#endif /* AD_INTERNAL_H */
+#endif /* MPLAYER_AD_INTERNAL_H */
Modified: trunk/libmpcodecs/ae.h
==============================================================================
--- trunk/libmpcodecs/ae.h (original)
+++ trunk/libmpcodecs/ae.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef AE_H
-#define AE_H
+#ifndef MPLAYER_AE_H
+#define MPLAYER_AE_H
#define ACODEC_COPY 0
#define ACODEC_PCM 1
@@ -43,4 +42,4 @@ typedef struct audio_encoder_s {
audio_encoder_t *new_audio_encoder(muxer_stream_t *stream, audio_encoding_params_t *params);
-#endif /* AE_H */
+#endif /* MPLAYER_AE_H */
Modified: trunk/libmpcodecs/ae_faac.h
==============================================================================
--- trunk/libmpcodecs/ae_faac.h (original)
+++ trunk/libmpcodecs/ae_faac.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef AE_FAAC_H
-#define AE_FAAC_H
+#ifndef MPLAYER_AE_FAAC_H
+#define MPLAYER_AE_FAAC_H
#include "ae.h"
int mpae_init_faac(audio_encoder_t *encoder);
-#endif /* AE_FAAC_H */
+#endif /* MPLAYER_AE_FAAC_H */
Modified: trunk/libmpcodecs/ae_lame.h
==============================================================================
--- trunk/libmpcodecs/ae_lame.h (original)
+++ trunk/libmpcodecs/ae_lame.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef AE_LAME_H
-#define AE_LAME_H
+#ifndef MPLAYER_AE_LAME_H
+#define MPLAYER_AE_LAME_H
#include "ae.h"
int mpae_init_lame(audio_encoder_t *encoder);
-#endif /* AE_LAME_H */
+#endif /* MPLAYER_AE_LAME_H */
Modified: trunk/libmpcodecs/ae_lavc.h
==============================================================================
--- trunk/libmpcodecs/ae_lavc.h (original)
+++ trunk/libmpcodecs/ae_lavc.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef AE_LAVC_H
-#define AE_LAVC_H
+#ifndef MPLAYER_AE_LAVC_H
+#define MPLAYER_AE_LAVC_H
#include "ae.h"
int mpae_init_lavc(audio_encoder_t *encoder);
-#endif /* AE_LAVC_H */
+#endif /* MPLAYER_AE_LAVC_H */
Modified: trunk/libmpcodecs/ae_pcm.h
==============================================================================
--- trunk/libmpcodecs/ae_pcm.h (original)
+++ trunk/libmpcodecs/ae_pcm.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef AE_PCM_H
-#define AE_PCM_H
+#ifndef MPLAYER_AE_PCM_H
+#define MPLAYER_AE_PCM_H
#include "ae.h"
int mpae_init_pcm(audio_encoder_t *encoder);
-#endif /* AE_PCM_H */
+#endif /* MPLAYER_AE_PCM_H */
Modified: trunk/libmpcodecs/ae_toolame.h
==============================================================================
--- trunk/libmpcodecs/ae_toolame.h (original)
+++ trunk/libmpcodecs/ae_toolame.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AE_TOOLAME_H
-#define AE_TOOLAME_H
+#ifndef MPLAYER_AE_TOOLAME_H
+#define MPLAYER_AE_TOOLAME_H
#include "ae.h"
#include <toolame.h>
@@ -13,4 +13,4 @@ typedef struct {
int mpae_init_toolame(audio_encoder_t *encoder);
-#endif /* AE_TOOLAME_H */
+#endif /* MPLAYER_AE_TOOLAME_H */
Modified: trunk/libmpcodecs/ae_twolame.h
==============================================================================
--- trunk/libmpcodecs/ae_twolame.h (original)
+++ trunk/libmpcodecs/ae_twolame.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AE_TWOLAME_H
-#define AE_TWOLAME_H
+#ifndef MPLAYER_AE_TWOLAME_H
+#define MPLAYER_AE_TWOLAME_H
#include "ae.h"
#include <twolame.h>
@@ -11,4 +11,4 @@ typedef struct {
int mpae_init_twolame(audio_encoder_t *encoder);
-#endif /* AE_TWOLAME_H */
+#endif /* MPLAYER_AE_TWOLAME_H */
Modified: trunk/libmpcodecs/cmmx.h
==============================================================================
--- trunk/libmpcodecs/cmmx.h (original)
+++ trunk/libmpcodecs/cmmx.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* Author: Zoltan Hidvegi
*/
-#ifndef CMMX_H
-#define CMMX_H
+#ifndef MPLAYER_CMMX_H
+#define MPLAYER_CMMX_H
typedef unsigned long cmmx_t;
@@ -183,4 +183,4 @@ pcmpeqb(cmmx_t a, cmmx_t b)
return pcmpzb(a ^ b);
}
-#endif /* CMMX_H */
+#endif /* MPLAYER_CMMX_H */
Modified: trunk/libmpcodecs/dec_audio.h
==============================================================================
--- trunk/libmpcodecs/dec_audio.h (original)
+++ trunk/libmpcodecs/dec_audio.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef DEC_AUDIO_H
-#define DEC_AUDIO_H
+#ifndef MPLAYER_DEC_AUDIO_H
+#define MPLAYER_DEC_AUDIO_H
// dec_audio.c:
extern void afm_help(void);
@@ -12,4 +12,4 @@ extern void uninit_audio(sh_audio_t *sh_
extern int init_audio_filters(sh_audio_t *sh_audio, int in_samplerate,
int *out_samplerate, int *out_channels, int *out_format);
-#endif /* DEC_AUDIO_H */
+#endif /* MPLAYER_DEC_AUDIO_H */
Modified: trunk/libmpcodecs/dec_video.h
==============================================================================
--- trunk/libmpcodecs/dec_video.h (original)
+++ trunk/libmpcodecs/dec_video.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef DEC_VIDEO_H
-#define DEC_VIDEO_H
+#ifndef MPLAYER_DEC_VIDEO_H
+#define MPLAYER_DEC_VIDEO_H
// dec_video.c:
extern void vfm_help(void);
@@ -21,4 +21,4 @@ extern int get_current_video_decoder_lag
extern int divx_quality;
-#endif /* DEC_VIDEO_H */
+#endif /* MPLAYER_DEC_VIDEO_H */
Modified: trunk/libmpcodecs/img_format.h
==============================================================================
--- trunk/libmpcodecs/img_format.h (original)
+++ trunk/libmpcodecs/img_format.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef IMG_FORMAT_H
-#define IMG_FORMAT_H
+#ifndef MPLAYER_IMG_FORMAT_H
+#define MPLAYER_IMG_FORMAT_H
/* RGB/BGR Formats */
@@ -117,4 +116,4 @@ typedef struct {
const char *vo_format_name(int format);
-#endif /* IMG_FORMAT_H */
+#endif /* MPLAYER_IMG_FORMAT_H */
Modified: trunk/libmpcodecs/mp_image.h
==============================================================================
--- trunk/libmpcodecs/mp_image.h (original)
+++ trunk/libmpcodecs/mp_image.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MP_IMAGE_H
-#define MP_IMAGE_H
+#ifndef MPLAYER_MP_IMAGE_H
+#define MPLAYER_MP_IMAGE_H
//--------- codec's requirements (filled by the codec/vf) ---------
@@ -228,4 +228,4 @@ static inline void free_mp_image(mp_imag
mp_image_t* alloc_mpi(int w, int h, unsigned long int fmt);
void copy_mpi(mp_image_t *dmpi, mp_image_t *mpi);
-#endif /* MP_IMAGE_H */
+#endif /* MPLAYER_MP_IMAGE_H */
Modified: trunk/libmpcodecs/mpc_info.h
==============================================================================
--- trunk/libmpcodecs/mpc_info.h (original)
+++ trunk/libmpcodecs/mpc_info.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MPC_INFO_H
-#define MPC_INFO_H
+#ifndef MPLAYER_MPC_INFO_H
+#define MPLAYER_MPC_INFO_H
typedef struct mp_codec_info_s
{
@@ -22,4 +22,4 @@ typedef struct mp_codec_info_s
#define CONTROL_ERROR -2
#define CONTROL_NA -3
-#endif /* MPC_INFO_H */
+#endif /* MPLAYER_MPC_INFO_H */
Modified: trunk/libmpcodecs/native/alaw.h
==============================================================================
--- trunk/libmpcodecs/native/alaw.h (original)
+++ trunk/libmpcodecs/native/alaw.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
// Generated by TOOLS/alaw-gen.c
-#ifndef ALAW_H
-#define ALAW_H
+#ifndef MPLAYER_ALAW_H
+#define MPLAYER_ALAW_H
const short alaw2short[]={
-5504, -5248, -6016, -5760, -4480, -4224, -4992, -4736,
@@ -73,4 +73,4 @@ const short ulaw2short[]={
56, 48, 40, 32, 24, 16, 8, 0
};
-#endif /* ALAW_H */
+#endif /* MPLAYER_ALAW_H */
Modified: trunk/libmpcodecs/native/mmx.h
==============================================================================
--- trunk/libmpcodecs/native/mmx.h (original)
+++ trunk/libmpcodecs/native/mmx.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MMX_H
-#define MMX_H
+#ifndef MPLAYER_MMX_H
+#define MPLAYER_MMX_H
typedef union {
long long q; /* Quadword (64-bit) value */
@@ -77,4 +77,4 @@ typedef union {
#define emms() __asm__ __volatile__ ("emms")
-#endif /* MMX_H */
+#endif /* MPLAYER_MMX_H */
Modified: trunk/libmpcodecs/native/xa_gsm.h
==============================================================================
--- trunk/libmpcodecs/native/xa_gsm.h (original)
+++ trunk/libmpcodecs/native/xa_gsm.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef XA_GSM_H
-#define XA_GSM_H
+#ifndef MPLAYER_XA_GSM_H
+#define MPLAYER_XA_GSM_H
void XA_MSGSM_Decoder(unsigned char *ibuf,unsigned short *obuf);
void XA_GSM_Decoder(unsigned char *ibuf,unsigned short *obuf);
void GSM_Init(void);
-#endif /* XA_GSM_H */
+#endif /* MPLAYER_XA_GSM_H */
Modified: trunk/libmpcodecs/native/xa_gsm_int.h
==============================================================================
--- trunk/libmpcodecs/native/xa_gsm_int.h (original)
+++ trunk/libmpcodecs/native/xa_gsm_int.h Fri Feb 22 10:09:46 2008
@@ -22,8 +22,8 @@
*
********************************************************************/
-#ifndef XA_GSM_INT_H
-#define XA_GSM_INT_H
+#ifndef MPLAYER_XA_GSM_INT_H
+#define MPLAYER_XA_GSM_INT_H
#include "xa_gsm.h"
@@ -131,4 +131,4 @@ typedef struct {
*/
-#endif /* XA_GSM_INT_H */
+#endif /* MPLAYER_XA_GSM_INT_H */
Modified: trunk/libmpcodecs/pullup.h
==============================================================================
--- trunk/libmpcodecs/pullup.h (original)
+++ trunk/libmpcodecs/pullup.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef PULLUP_H
-#define PULLUP_H
+#ifndef MPLAYER_PULLUP_H
+#define MPLAYER_PULLUP_H
#define PULLUP_CPU_MMX 1
#define PULLUP_CPU_MMX2 2
@@ -81,4 +81,4 @@ void pullup_preinit_context(struct pullu
void pullup_init_context(struct pullup_context *c);
void pullup_free_context(struct pullup_context *c);
-#endif /* PULLUP_H */
+#endif /* MPLAYER_PULLUP_H */
Modified: trunk/libmpcodecs/vd.h
==============================================================================
--- trunk/libmpcodecs/vd.h (original)
+++ trunk/libmpcodecs/vd.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VD_H
-#define VD_H
+#ifndef MPLAYER_VD_H
+#define MPLAYER_VD_H
#include "mp_image.h"
#include "mpc_info.h"
@@ -35,4 +35,4 @@ void mpcodecs_draw_slice(sh_video_t *sh,
#define VDFLAGS_DROPFRAME 3
-#endif /* VD_H */
+#endif /* MPLAYER_VD_H */
Modified: trunk/libmpcodecs/vd_internal.h
==============================================================================
--- trunk/libmpcodecs/vd_internal.h (original)
+++ trunk/libmpcodecs/vd_internal.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VD_INTERNAL_H
-#define VD_INTERNAL_H
+#ifndef MPLAYER_VD_INTERNAL_H
+#define MPLAYER_VD_INTERNAL_H
#include "codec-cfg.h"
#include "img_format.h"
@@ -27,4 +27,4 @@ static mp_image_t* decode(sh_video_t *sh
decode\
};
-#endif /* VD_INTERNAL_H */
+#endif /* MPLAYER_VD_INTERNAL_H */
Modified: trunk/libmpcodecs/vf.h
==============================================================================
--- trunk/libmpcodecs/vf.h (original)
+++ trunk/libmpcodecs/vf.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VF_H
-#define VF_H
+#ifndef MPLAYER_VF_H
+#define MPLAYER_VF_H
struct vf_instance_s;
struct vf_priv_s;
@@ -123,4 +123,4 @@ int vf_config_wrapper(struct vf_instance
int width, int height, int d_width, int d_height,
unsigned int flags, unsigned int outfmt);
-#endif /* VF_H */
+#endif /* MPLAYER_VF_H */
Modified: trunk/libmpcodecs/vf_scale.h
==============================================================================
--- trunk/libmpcodecs/vf_scale.h (original)
+++ trunk/libmpcodecs/vf_scale.h Fri Feb 22 10:09:46 2008
@@ -1,9 +1,9 @@
//GPL
-#ifndef VF_SCALE_H
-#define VF_SCALE_H
+#ifndef MPLAYER_VF_SCALE_H
+#define MPLAYER_VF_SCALE_H
int get_sws_cpuflags(void);
struct SwsContext *sws_getContextFromCmdLine(int srcW, int srcH, int srcFormat, int dstW, int dstH, int dstFormat);
-#endif /* VF_SCALE_H */
+#endif /* MPLAYER_VF_SCALE_H */
Modified: trunk/libmpcodecs/vfcap.h
==============================================================================
--- trunk/libmpcodecs/vfcap.h (original)
+++ trunk/libmpcodecs/vfcap.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
// VFCAP_* values: they are flags, returned by query_format():
-#ifndef VFCAP_H
-#define VFCAP_H
+#ifndef MPLAYER_VFCAP_H
+#define MPLAYER_VFCAP_H
// set, if the given colorspace is supported (with or without conversion)
#define VFCAP_CSP_SUPPORTED 0x1
@@ -34,4 +34,4 @@
// filter will draw EOSD at screen resolution (without scaling)
#define VFCAP_EOSD_UNSCALED 0x4000
-#endif /* VFCAP_H */
+#endif /* MPLAYER_VFCAP_H */
Modified: trunk/libmpcodecs/vqf.h
==============================================================================
--- trunk/libmpcodecs/vqf.h (original)
+++ trunk/libmpcodecs/vqf.h Fri Feb 22 10:09:46 2008
@@ -5,8 +5,8 @@
// Modified for MPlayer on 2004.12.29
-#ifndef VQF_H
-#define VQF_H
+#ifndef MPLAYER_VQF_H
+#define MPLAYER_VQF_H
#ifdef _MSC_VER
# ifdef DLL_MODULE
@@ -223,4 +223,4 @@ DllPort int TvqGetFbTotalBits(); // q
#endif
-#endif /* VQF_H */
+#endif /* MPLAYER_VQF_H */
Modified: trunk/libmpdemux/asf.h
==============================================================================
--- trunk/libmpdemux/asf.h (original)
+++ trunk/libmpdemux/asf.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef ASF_H
-#define ASF_H
+#ifndef MPLAYER_ASF_H
+#define MPLAYER_ASF_H
//#include "config.h" /* for WORDS_BIGENDIAN */
#include <inttypes.h>
@@ -244,4 +244,4 @@ struct asf_priv {
unsigned bps;
};
-#endif /* ASF_H */
+#endif /* MPLAYER_ASF_H */
Modified: trunk/libmpdemux/aviheader.h
==============================================================================
--- trunk/libmpdemux/aviheader.h (original)
+++ trunk/libmpdemux/aviheader.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AVIHEADER_H
-#define AVIHEADER_H
+#ifndef MPLAYER_AVIHEADER_H
+#define MPLAYER_AVIHEADER_H
//#include "config.h" /* get correct definition WORDS_BIGENDIAN */
#include "libavutil/common.h"
@@ -353,4 +353,4 @@ typedef struct {
#define AVI_IDX_OFFSET(x) ((((uint64_t)(x)->dwFlags&0xffff0000)<<16)+(x)->dwChunkOffset)
-#endif /* AVIHEADER_H */
+#endif /* MPLAYER_AVIHEADER_H */
Modified: trunk/libmpdemux/demux_avs.h
==============================================================================
--- trunk/libmpdemux/demux_avs.h (original)
+++ trunk/libmpdemux/demux_avs.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Boston, MA 02110-1301 USA.
*/
-#ifndef DEMUX_AVS_H
-#define DEMUX_AVS_H
+#ifndef MPLAYER_DEMUX_AVS_H
+#define MPLAYER_DEMUX_AVS_H
enum { AVISYNTH_INTERFACE_VERSION = 2 };
@@ -166,4 +166,4 @@ static inline int avs_bits_per_pixel(con
}
}
-#endif /* DEMUX_AVS_H */
+#endif /* MPLAYER_DEMUX_AVS_H */
Modified: trunk/libmpdemux/demux_rtp.h
==============================================================================
--- trunk/libmpdemux/demux_rtp.h (original)
+++ trunk/libmpdemux/demux_rtp.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef DEMUX_RTP_H
-#define DEMUX_RTP_H
+#ifndef MPLAYER_DEMUX_RTP_H
+#define MPLAYER_DEMUX_RTP_H
#include <stdlib.h>
#include <stdio.h>
@@ -28,4 +28,4 @@ int demux_rtp_fill_buffer(demuxer_t *dem
// Close a RTP demuxer
void demux_close_rtp(demuxer_t* demuxer);
-#endif /* DEMUX_RTP_H */
+#endif /* MPLAYER_DEMUX_RTP_H */
Modified: trunk/libmpdemux/demux_rtp_internal.h
==============================================================================
--- trunk/libmpdemux/demux_rtp_internal.h (original)
+++ trunk/libmpdemux/demux_rtp_internal.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef DEMUX_RTP_INTERNAL_H
-#define DEMUX_RTP_INTERNAL_H
+#ifndef MPLAYER_DEMUX_RTP_INTERNAL_H
+#define MPLAYER_DEMUX_RTP_INTERNAL_H
#include <stdlib.h>
@@ -41,4 +41,4 @@ Boolean awaitRTPPacket(demuxer_t* demuxe
// "streamType": 0 => video; 1 => audio
// This routine returns False if the input stream has closed
-#endif /* DEMUX_RTP_INTERNAL_H */
+#endif /* MPLAYER_DEMUX_RTP_INTERNAL_H */
Modified: trunk/libmpdemux/demux_xmms_plugin.h
==============================================================================
--- trunk/libmpdemux/demux_xmms_plugin.h (original)
+++ trunk/libmpdemux/demux_xmms_plugin.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
-#ifndef DEMUX_XMMS_PLUGIN_H
-#define DEMUX_XMMS_PLUGIN_H
+#ifndef MPLAYER_DEMUX_XMMS_PLUGIN_H
+#define MPLAYER_DEMUX_XMMS_PLUGIN_H
typedef enum
{
@@ -152,4 +152,4 @@ typedef struct VisPlugin
void (*render_freq)(short freq_data[2][256]); /* Render the freq data, don't do anything time consuming in here */
} VisPlugin;
-#endif /* DEMUX_XMMS_PLUGIN_H */
+#endif /* MPLAYER_DEMUX_XMMS_PLUGIN_H */
Modified: trunk/libmpdemux/demuxer.h
==============================================================================
--- trunk/libmpdemux/demuxer.h (original)
+++ trunk/libmpdemux/demuxer.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef DEMUXER_H
-#define DEMUXER_H
+#ifndef MPLAYER_DEMUXER_H
+#define MPLAYER_DEMUXER_H
#ifdef USE_ASS
#include "libass/ass_types.h"
@@ -421,4 +421,4 @@ int demuxer_set_angle(demuxer_t *demuxer
/// Get number of angles.
int demuxer_angles_count(demuxer_t *demuxer);
-#endif /* DEMUXER_H */
+#endif /* MPLAYER_DEMUXER_H */
Modified: trunk/libmpdemux/ebml.h
==============================================================================
--- trunk/libmpdemux/ebml.h (original)
+++ trunk/libmpdemux/ebml.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef EBML_H
-#define EBML_H
+#ifndef MPLAYER_EBML_H
+#define MPLAYER_EBML_H
#include <inttypes.h>
@@ -188,4 +188,4 @@ int ebml_read_skip (stream_t *s, uint64_
uint32_t ebml_read_master (stream_t *s, uint64_t *length);
char *ebml_read_header (stream_t *s, int *version);
-#endif /* EBML_H */
+#endif /* MPLAYER_EBML_H */
Modified: trunk/libmpdemux/genres.h
==============================================================================
--- trunk/libmpdemux/genres.h (original)
+++ trunk/libmpdemux/genres.h Fri Feb 22 10:09:46 2008
@@ -13,9 +13,8 @@
* detailed changelog at http://svn.mplayerhq.hu/mplayer/trunk/
*/
-
-#ifndef GENRES_H
-#define GENRES_H
+#ifndef MPLAYER_GENRES_H
+#define MPLAYER_GENRES_H
const char * const genres[] = {
@@ -277,5 +276,4 @@ const char * const genres[] = {
"Unknown", /* 255 */
};
-
-#endif /* GENRES_H */
+#endif /* MPLAYER_GENRES_H */
Modified: trunk/libmpdemux/matroska.h
==============================================================================
--- trunk/libmpdemux/matroska.h (original)
+++ trunk/libmpdemux/matroska.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* see http://cvs.corecodec.org/cgi-bin/cvsweb.cgi/~checkout~/matroska/doc/website…
*/
-#ifndef MATROSKA_H
-#define MATROSKA_H
+#ifndef MPLAYER_MATROSKA_H
+#define MPLAYER_MATROSKA_H
#define MKV_A_AAC_2MAIN "A_AAC/MPEG2/MAIN"
#define MKV_A_AAC_2LC "A_AAC/MPEG2/LC"
@@ -67,4 +67,4 @@ void demux_mkv_get_audio_lang(demuxer_t
void demux_mkv_get_sub_lang(demuxer_t *demuxer, int track_num, char *lang,
int maxlen);
-#endif /* MATROSKA_H */
+#endif /* MPLAYER_MATROSKA_H */
Modified: trunk/libmpdemux/mf.h
==============================================================================
--- trunk/libmpdemux/mf.h (original)
+++ trunk/libmpdemux/mf.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef MF_H
-#define MF_H
+#ifndef MPLAYER_MF_H
+#define MPLAYER_MF_H
extern int mf_w;
extern int mf_h;
@@ -16,4 +16,4 @@ typedef struct
mf_t* open_mf(char * filename);
-#endif /* MF_H */
+#endif /* MPLAYER_MF_H */
Modified: trunk/libmpdemux/mp3_hdr.h
==============================================================================
--- trunk/libmpdemux/mp3_hdr.h (original)
+++ trunk/libmpdemux/mp3_hdr.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MP3_HDR_H
-#define MP3_HDR_H
+#ifndef MPLAYER_MP3_HDR_H
+#define MPLAYER_MP3_HDR_H
int mp_get_mp3_header(unsigned char* hbuf,int* chans, int* freq, int* spf, int* mpa_layer, int* br);
@@ -12,4 +12,4 @@ static inline int mp_check_mp3_header(un
return 1;
}
-#endif /* MP3_HDR_H */
+#endif /* MPLAYER_MP3_HDR_H */
Modified: trunk/libmpdemux/mpeg_hdr.h
==============================================================================
--- trunk/libmpdemux/mpeg_hdr.h (original)
+++ trunk/libmpdemux/mpeg_hdr.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MPEG_HDR_H
-#define MPEG_HDR_H
+#ifndef MPLAYER_MPEG_HDR_H
+#define MPLAYER_MPEG_HDR_H
typedef struct {
// video info:
@@ -30,4 +30,4 @@ void mp4_header_process_vop(mp_mpeg_head
int h264_parse_sps(mp_mpeg_header_t * picture, unsigned char * buf, int len);
int mp_vc1_decode_sequence_header(mp_mpeg_header_t * picture, unsigned char * buf, int len);
-#endif /* MPEG_HDR_H */
+#endif /* MPLAYER_MPEG_HDR_H */
Modified: trunk/libmpdemux/mpeg_packetizer.h
==============================================================================
--- trunk/libmpdemux/mpeg_packetizer.h (original)
+++ trunk/libmpdemux/mpeg_packetizer.h Fri Feb 22 10:09:46 2008
@@ -22,8 +22,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef MPEG_PACKETIZER_H
-#define MPEG_PACKETIZER_H
+#ifndef MPLAYER_MPEG_PACKETIZER_H
+#define MPLAYER_MPEG_PACKETIZER_H
/* Send MPEG <type> PES packet */
int send_mpeg_pes_packet (unsigned char *data, int len, int id, uint64_t pts,
@@ -38,4 +38,4 @@ int send_mpeg_lpcm_packet (unsigned char
int id, uint64_t pts, int freq_id,
int my_write (const unsigned char *data, int len));
-#endif /* MPEG_PACKETIZER_H */
+#endif /* MPLAYER_MPEG_PACKETIZER_H */
Modified: trunk/libmpdemux/ms_hdr.h
==============================================================================
--- trunk/libmpdemux/ms_hdr.h (original)
+++ trunk/libmpdemux/ms_hdr.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MS_HDR_H
-#define MS_HDR_H
+#ifndef MPLAYER_MS_HDR_H
+#define MPLAYER_MS_HDR_H
#ifndef _WAVEFORMATEX_
#define _WAVEFORMATEX_
@@ -79,4 +79,4 @@ typedef struct {
#endif
#endif
-#endif /* MS_HDR_H */
+#endif /* MPLAYER_MS_HDR_H */
Modified: trunk/libmpdemux/muxer.h
==============================================================================
--- trunk/libmpdemux/muxer.h (original)
+++ trunk/libmpdemux/muxer.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MUXER_H
-#define MUXER_H
+#ifndef MPLAYER_MUXER_H
+#define MPLAYER_MUXER_H
#define MUXER_MAX_STREAMS 16
@@ -116,4 +116,4 @@ int muxer_init_muxer_rawvideo(muxer_t *)
int muxer_init_muxer_lavf(muxer_t *);
int muxer_init_muxer_rawaudio(muxer_t *);
-#endif /* MUXER_H */
+#endif /* MPLAYER_MUXER_H */
Modified: trunk/libmpdemux/nuppelvideo.h
==============================================================================
--- trunk/libmpdemux/nuppelvideo.h (original)
+++ trunk/libmpdemux/nuppelvideo.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
/* nuppelvideo.h rh */
-#ifndef NUPPELVIDEO_H
-#define NUPPELVIDEO_H
+#ifndef MPLAYER_NUPPELVIDEO_H
+#define MPLAYER_NUPPELVIDEO_H
#include "libavutil/intfloat_readwrite.h"
@@ -159,4 +159,4 @@ typedef struct audbuffertype
(h)->lavc_maxqdiff = le2me_32((h)->lavc_maxqdiff); \
}
-#endif /* NUPPELVIDEO_H */
+#endif /* MPLAYER_NUPPELVIDEO_H */
Modified: trunk/libmpdemux/parse_es.h
==============================================================================
--- trunk/libmpdemux/parse_es.h (original)
+++ trunk/libmpdemux/parse_es.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef PARSE_ES_H
-#define PARSE_ES_H
+#ifndef MPLAYER_PARSE_ES_H
+#define MPLAYER_PARSE_ES_H
#define MAX_VIDEO_PACKET_SIZE (224*1024+4)
#define VIDEOBUFFER_SIZE 0x100000
@@ -18,4 +18,4 @@ int read_video_packet(demux_stream_t *ds
// return: next packet code
int skip_video_packet(demux_stream_t *ds);
-#endif /* PARSE_ES_H */
+#endif /* MPLAYER_PARSE_ES_H */
Modified: trunk/libmpdemux/parse_mp4.h
==============================================================================
--- trunk/libmpdemux/parse_mp4.h (original)
+++ trunk/libmpdemux/parse_mp4.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* File licensed under the GPL, see http://www.fsf.org/ for more info.
*/
-#ifndef PARSE_MP4_H
-#define PARSE_MP4_H
+#ifndef MPLAYER_PARSE_MP4_H
+#define MPLAYER_PARSE_MP4_H
#include <inttypes.h>
@@ -107,5 +107,5 @@ typedef struct {
int mp4_parse_esds(unsigned char *data, int datalen, esds_t *esds);
void mp4_free_esds(esds_t *esds);
-#endif /* PARSE_MP4_H */
+#endif /* MPLAYER_PARSE_MP4_H */
Modified: trunk/libmpdemux/qtpalette.h
==============================================================================
--- trunk/libmpdemux/qtpalette.h (original)
+++ trunk/libmpdemux/qtpalette.h Fri Feb 22 10:09:46 2008
@@ -2,8 +2,8 @@
// Automatically generated from a utility derived from XAnim:
// http://xanim.va.pubnix.com/home.html
-#ifndef QTPALETTE_H
-#define QTPALETTE_H
+#ifndef MPLAYER_QTPALETTE_H
+#define MPLAYER_QTPALETTE_H
static const unsigned char qt_default_palette_4[4 * 4] = {
0x5E, 0x65, 0x93, 0x00,
@@ -568,4 +568,4 @@ static const unsigned char qt_default_gr
/* 255, 0xFF */ 0x00, 0x00, 0x00, 0x00
};
-#endif /* QTPALETTE_H */
+#endif /* MPLAYER_QTPALETTE_H */
Modified: trunk/libmpdemux/stheader.h
==============================================================================
--- trunk/libmpdemux/stheader.h (original)
+++ trunk/libmpdemux/stheader.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef STHEADER_H
-#define STHEADER_H
+#ifndef MPLAYER_STHEADER_H
+#define MPLAYER_STHEADER_H
#include "aviheader.h"
#include "ms_hdr.h"
@@ -121,4 +121,4 @@ void free_sh_video(sh_video_t *sh);
int video_read_properties(sh_video_t *sh_video);
int video_read_frame(sh_video_t* sh_video,float* frame_time_ptr,unsigned char** start,int force_fps);
-#endif /* STHEADER_H */
+#endif /* MPLAYER_STHEADER_H */
Modified: trunk/libmpdemux/yuv4mpeg.h
==============================================================================
--- trunk/libmpdemux/yuv4mpeg.h (original)
+++ trunk/libmpdemux/yuv4mpeg.h Fri Feb 22 10:09:46 2008
@@ -24,8 +24,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef YUV4MPEG_H
-#define YUV4MPEG_H
+#ifndef MPLAYER_YUV4MPEG_H
+#define MPLAYER_YUV4MPEG_H
#include <stdlib.h>
//#include "mp_msg.h"
@@ -449,6 +449,6 @@ int y4m_allow_unknown_tags(int yn);
************************************************************************
************************************************************************/
-#endif /* YUV4MPEG_H */
+#endif /* MPLAYER_YUV4MPEG_H */
Modified: trunk/libmpdemux/yuv4mpeg_intern.h
==============================================================================
--- trunk/libmpdemux/yuv4mpeg_intern.h (original)
+++ trunk/libmpdemux/yuv4mpeg_intern.h Fri Feb 22 10:09:46 2008
@@ -19,8 +19,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef YUV4MPEG_INTERN_H
-#define YUV4MPEG_INTERN_H
+#ifndef MPLAYER_YUV4MPEG_INTERN_H
+#define MPLAYER_YUV4MPEG_INTERN_H
#define Y4M_MAGIC "YUV4MPEG2"
@@ -75,4 +75,4 @@
#define Y4M_DAR_MPEG2_3 { 16, 9 }
#define Y4M_DAR_MPEG2_4 { 221, 100 }
-#endif /* YUV4MPEG_INTERN_H */
+#endif /* MPLAYER_YUV4MPEG_INTERN_H */
Modified: trunk/libvo/aspect.h
==============================================================================
--- trunk/libvo/aspect.h (original)
+++ trunk/libvo/aspect.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef ASPECT_H
-#define ASPECT_H
+#ifndef MPLAYER_ASPECT_H
+#define MPLAYER_ASPECT_H
/* Stuff for correct aspect scaling. */
extern int vo_panscan_x;
@@ -21,4 +21,4 @@ void aspect_save_screenres(int scrw, int
void aspect(int *srcw, int *srch, int zoom);
void aspect_fit(int *srcw, int *srch, int fitw, int fith);
-#endif /* ASPECT_H */
+#endif /* MPLAYER_ASPECT_H */
Modified: trunk/libvo/fastmemcpy.h
==============================================================================
--- trunk/libvo/fastmemcpy.h (original)
+++ trunk/libvo/fastmemcpy.h Fri Feb 22 10:09:46 2008
@@ -16,8 +16,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef FASTMEMCPY_H
-#define FASTMEMCPY_H
+#ifndef MPLAYER_FASTMEMCPY_H
+#define MPLAYER_FASTMEMCPY_H
#include "config.h"
#include <inttypes.h>
@@ -105,4 +105,4 @@ static inline void * memcpy_pic2(void *
return retval;
}
-#endif /* FASTMEMCPY_H */
+#endif /* MPLAYER_FASTMEMCPY_H */
Modified: trunk/libvo/font_load.h
==============================================================================
--- trunk/libvo/font_load.h (original)
+++ trunk/libvo/font_load.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef FONT_LOAD_H
-#define FONT_LOAD_H
+#ifndef MPLAYER_FONT_LOAD_H
+#define MPLAYER_FONT_LOAD_H
#ifdef HAVE_FREETYPE
#include <ft2build.h>
@@ -102,4 +102,4 @@ static int kerning(font_desc_t *desc, in
raw_file* load_raw(char *name,int verbose);
font_desc_t* read_font_desc(const char* fname,float factor,int verbose);
-#endif /* FONT_LOAD_H */
+#endif /* MPLAYER_FONT_LOAD_H */
Modified: trunk/libvo/geometry.h
==============================================================================
--- trunk/libvo/geometry.h (original)
+++ trunk/libvo/geometry.h Fri Feb 22 10:09:46 2008
@@ -1,10 +1,10 @@
/* This file (C) Mark Zealey <mark(a)zealos.org 2002, released under GPL */
-#ifndef GEOMETRY_H
-#define GEOMETRY_H
+#ifndef MPLAYER_GEOMETRY_H
+#define MPLAYER_GEOMETRY_H
extern char *vo_geometry;
extern int geometry_wh_changed;
extern int geometry_xy_changed;
int geometry(int *xpos, int *ypos, int *widw, int *widh, int scrw, int scrh);
-#endif /* GEOMETRY_H */
+#endif /* MPLAYER_GEOMETRY_H */
Modified: trunk/libvo/gl_common.h
==============================================================================
--- trunk/libvo/gl_common.h (original)
+++ trunk/libvo/gl_common.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GL_COMMON_H
-#define GL_COMMON_H
+#ifndef MPLAYER_GL_COMMON_H
+#define MPLAYER_GL_COMMON_H
#include "mp_msg.h"
#include "config.h"
@@ -330,4 +330,4 @@ extern int (APIENTRY *SwapInterval)(int)
extern void (APIENTRY *TexImage3D)(GLenum, GLint, GLenum, GLsizei, GLsizei,
GLsizei, GLint, GLenum, GLenum, const GLvoid *);
-#endif /* GL_COMMON_H */
+#endif /* MPLAYER_GL_COMMON_H */
Modified: trunk/libvo/gtf.h
==============================================================================
--- trunk/libvo/gtf.h (original)
+++ trunk/libvo/gtf.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GTF_H
-#define GTF_H
+#ifndef MPLAYER_GTF_H
+#define MPLAYER_GTF_H
#include <vbe.h>
@@ -45,4 +45,4 @@ typedef struct {
void GTF_calcTimings(double X,double Y,double freq, int type,
int want_margins, int want_interlace,struct VesaCRTCInfoBlock *result);
-#endif /* GTF_H */
+#endif /* MPLAYER_GTF_H */
Modified: trunk/libvo/jpeg_enc.h
==============================================================================
--- trunk/libvo/jpeg_enc.h (original)
+++ trunk/libvo/jpeg_enc.h Fri Feb 22 10:09:46 2008
@@ -22,8 +22,8 @@
* http://www.ece.purdue.edu/~bourman/grad-labs/lab8/pdf/lab.pdf
*/
-#ifndef JPEG_ENC_H
-#define JPEG_ENC_H
+#ifndef MPLAYER_JPEG_ENC_H
+#define MPLAYER_JPEG_ENC_H
typedef struct {
struct MpegEncContext *s;
@@ -46,4 +46,4 @@ int jpeg_enc_frame(jpeg_enc_t *j, unsign
void jpeg_enc_uninit(jpeg_enc_t *j);
-#endif /* JPEG_ENC_H */
+#endif /* MPLAYER_JPEG_ENC_H */
Modified: trunk/libvo/osd_font.h
==============================================================================
--- trunk/libvo/osd_font.h (original)
+++ trunk/libvo/osd_font.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef OSD_FONT_H
-#define OSD_FONT_H
+#ifndef MPLAYER_OSD_FONT_H
+#define MPLAYER_OSD_FONT_H
const unsigned char osd_font_pfb[] = {
0x80,0x01,0x02,0x17,0x00,0x00,0x25,0x21,0x50,0x53,0x2d,0x41,0x64,0x6f,0x62,0x65,
@@ -524,4 +524,4 @@ const unsigned char osd_font_pfb[] = {
0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x30,0x0a,
0x80,0x03,};
-#endif /* OSD_FONT_H */
+#endif /* MPLAYER_OSD_FONT_H */
Modified: trunk/libvo/spuenc.h
==============================================================================
--- trunk/libvo/spuenc.h (original)
+++ trunk/libvo/spuenc.h Fri Feb 22 10:09:46 2008
@@ -19,8 +19,8 @@
*
*/
-#ifndef SPUENC_H
-#define SPUENC_H
+#ifndef MPLAYER_SPUENC_H
+#define MPLAYER_SPUENC_H
#include <stdlib.h>
#define DATASIZE 53220
@@ -42,4 +42,4 @@ typedef struct {
void pixbuf_encode_rle(int x, int y, int w, int h, char *inbuf, int stride, encodedata *ed);
void pixbuf_delete(pixbuf* pb);
-#endif /* SPUENC_H */
+#endif /* MPLAYER_SPUENC_H */
Modified: trunk/libvo/vesa_lvo.h
==============================================================================
--- trunk/libvo/vesa_lvo.h (original)
+++ trunk/libvo/vesa_lvo.h Fri Feb 22 10:09:46 2008
@@ -9,8 +9,8 @@
* This file contains vo_vesa interface to Linux Video Overlay.
*/
-#ifndef VESA_LVO_H
-#define VESA_LVO_H
+#ifndef MPLAYER_VESA_LVO_H
+#define MPLAYER_VESA_LVO_H
int vlvo_preinit(const char *drvname);
int vlvo_init(unsigned src_width,unsigned src_height,
@@ -24,4 +24,4 @@ uint32_t vlvo_draw_frame(uint8_t *src[])
void vlvo_flip_page(void);
void vlvo_draw_osd(void);
-#endif /* VESA_LVO_H */
+#endif /* MPLAYER_VESA_LVO_H */
Modified: trunk/libvo/video_out.h
==============================================================================
--- trunk/libvo/video_out.h (original)
+++ trunk/libvo/video_out.h Fri Feb 22 10:09:46 2008
@@ -7,8 +7,8 @@
*
*/
-#ifndef VIDEO_OUT_H
-#define VIDEO_OUT_H
+#ifndef MPLAYER_VIDEO_OUT_H
+#define MPLAYER_VIDEO_OUT_H
#include <inttypes.h>
#include <stdarg.h>
@@ -255,4 +255,4 @@ extern char *monitor_dotclock_str;
#endif /* defined(HAVE_FBDEV) || defined(HAVE_VESA) */
-#endif /* VIDEO_OUT_H */
+#endif /* MPLAYER_VIDEO_OUT_H */
Modified: trunk/libvo/video_out_internal.h
==============================================================================
--- trunk/libvo/video_out_internal.h (original)
+++ trunk/libvo/video_out_internal.h Fri Feb 22 10:09:46 2008
@@ -20,8 +20,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef VIDEO_OUT_INTERNAL_H
-#define VIDEO_OUT_INTERNAL_H
+#ifndef MPLAYER_VIDEO_OUT_INTERNAL_H
+#define MPLAYER_VIDEO_OUT_INTERNAL_H
/* All video drivers will want this */
#include "libmpcodecs/vfcap.h"
@@ -57,4 +57,4 @@ static int preinit(const char *);
#include "osd.h"
-#endif /* VIDEO_OUT_INTERNAL_H */
+#endif /* MPLAYER_VIDEO_OUT_INTERNAL_H */
Modified: trunk/libvo/videodev_mjpeg.h
==============================================================================
--- trunk/libvo/videodev_mjpeg.h (original)
+++ trunk/libvo/videodev_mjpeg.h Fri Feb 22 10:09:46 2008
@@ -3,8 +3,8 @@
<rainer(a)johanni.de>
*/
-#ifndef VIDEODEV_MJPEG_H
-#define VIDEODEV_MJPEG_H
+#ifndef MPLAYER_VIDEODEV_MJPEG_H
+#define MPLAYER_VIDEODEV_MJPEG_H
/* This is identical with the mgavideo internal params struct,
please tell me if you change this struct here ! <gz(a)lysator.liu.se) */
@@ -120,4 +120,4 @@ Private IOCTL to set up for displaying M
#define MJPIOC_SYNC _IOR ('v', BASE_VIDIOCPRIVATE+5, struct mjpeg_sync)
#define MJPIOC_G_STATUS _IOWR('v', BASE_VIDIOCPRIVATE+6, struct mjpeg_status)
-#endif /* VIDEODEV_MJPEG_H */
+#endif /* MPLAYER_VIDEODEV_MJPEG_H */
Modified: trunk/libvo/vo_quartz.h
==============================================================================
--- trunk/libvo/vo_quartz.h (original)
+++ trunk/libvo/vo_quartz.h Fri Feb 22 10:09:46 2008
@@ -26,8 +26,8 @@
slouken(a)libsdl.org
*/
-#ifndef VO_QUARTZ_H
-#define VO_QUARTZ_H
+#ifndef MPLAYER_VO_QUARTZ_H
+#define MPLAYER_VO_QUARTZ_H
/* These are the Macintosh key scancode constants -- from Inside Macintosh */
#define QZ_ESCAPE 0x35
@@ -149,4 +149,4 @@
#define QZ_IBOOK_DOWN 0x3D
#define QZ_IBOOK_UP 0x3E
-#endif /* VO_QUARTZ_H */
+#endif /* MPLAYER_VO_QUARTZ_H */
Modified: trunk/libvo/vosub_vidix.h
==============================================================================
--- trunk/libvo/vosub_vidix.h (original)
+++ trunk/libvo/vosub_vidix.h Fri Feb 22 10:09:46 2008
@@ -9,8 +9,8 @@
* This file contains vosub_vidix interface to any mplayer's VO driver
*/
-#ifndef VOSUB_VIDIX_H
-#define VOSUB_VIDIX_H
+#ifndef MPLAYER_VOSUB_VIDIX_H
+#define MPLAYER_VOSUB_VIDIX_H
/* drvname can be NULL */
int vidix_preinit(const char *drvname,vo_functions_t *server);
@@ -35,4 +35,4 @@ int vidix_grkey_support(void);
int vidix_grkey_get(vidix_grkey_t *gr_key);
int vidix_grkey_set(const vidix_grkey_t *gr_key);
-#endif /* VOSUB_VIDIX_H */
+#endif /* MPLAYER_VOSUB_VIDIX_H */
Modified: trunk/libvo/w32_common.h
==============================================================================
--- trunk/libvo/w32_common.h (original)
+++ trunk/libvo/w32_common.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef W32_COMMON_H
-#define W32_COMMON_H
+#ifndef MPLAYER_W32_COMMON_H
+#define MPLAYER_W32_COMMON_H
extern HWND vo_w32_window;
extern int vo_vm;
@@ -14,4 +14,4 @@ extern int vo_w32_config(uint32_t, uint3
extern void destroyRenderingContext(void);
extern void w32_update_xinerama_info(void);
-#endif /* W32_COMMON_H */
+#endif /* MPLAYER_W32_COMMON_H */
Modified: trunk/libvo/wskeys.h
==============================================================================
--- trunk/libvo/wskeys.h (original)
+++ trunk/libvo/wskeys.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef WSKEYS_H
-#define WSKEYS_H
+#ifndef MPLAYER_WSKEYS_H
+#define MPLAYER_WSKEYS_H
#define wsosbrackets '['
#define wscsbrackets ']'
@@ -152,4 +152,4 @@
#define wsGrayInsert 0x9e + 256
#define wsGrayDelete 0x9f + 256
-#endif /* WSKEYS_H */
+#endif /* MPLAYER_WSKEYS_H */
Modified: trunk/libvo/x11_common.h
==============================================================================
--- trunk/libvo/x11_common.h (original)
+++ trunk/libvo/x11_common.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef X11_COMMON_H
-#define X11_COMMON_H
+#ifndef MPLAYER_X11_COMMON_H
+#define MPLAYER_X11_COMMON_H
#include <X11/Xlib.h>
#include <X11/Xutil.h>
@@ -123,4 +122,4 @@ void update_xinerama_info(void);
int vo_find_depth_from_visuals(Display *dpy, int screen, Visual **visual_return);
-#endif /* X11_COMMON_H */
+#endif /* MPLAYER_X11_COMMON_H */
Modified: trunk/m_config.h
==============================================================================
--- trunk/m_config.h (original)
+++ trunk/m_config.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef M_CONFIG_H
-#define M_CONFIG_H
+#ifndef MPLAYER_M_CONFIG_H
+#define MPLAYER_M_CONFIG_H
/// \defgroup Config Config manager
///
@@ -206,4 +206,4 @@ m_config_set_profile(m_config_t* config,
///@}
-#endif /* M_CONFIG_H */
+#endif /* MPLAYER_M_CONFIG_H */
Modified: trunk/m_option.h
==============================================================================
--- trunk/m_option.h (original)
+++ trunk/m_option.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef M_OPTION_H
-#define M_OPTION_H
+#ifndef MPLAYER_M_OPTION_H
+#define MPLAYER_M_OPTION_H
/// \defgroup Options
/// m_option allows to parse, print and copy data of various types.
@@ -500,4 +500,4 @@ m_option_free(const m_option_t* opt,void
/*@}*/
-#endif /* M_OPTION_H */
+#endif /* MPLAYER_M_OPTION_H */
Modified: trunk/m_property.h
==============================================================================
--- trunk/m_property.h (original)
+++ trunk/m_property.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef M_PROPERTY_H
-#define M_PROPERTY_H
+#ifndef MPLAYER_M_PROPERTY_H
+#define MPLAYER_M_PROPERTY_H
/// \defgroup Properties
///
@@ -201,4 +201,4 @@ int m_property_bitrate(const m_option_t*
///@}
-#endif /* M_PROPERTY_H */
+#endif /* MPLAYER_M_PROPERTY_H */
Modified: trunk/m_struct.h
==============================================================================
--- trunk/m_struct.h (original)
+++ trunk/m_struct.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef M_STRUCT_H
-#define M_STRUCT_H
+#ifndef MPLAYER_M_STRUCT_H
+#define MPLAYER_M_STRUCT_H
/// \defgroup OptionsStruct Options struct
/// \ingroup Options
@@ -105,4 +105,4 @@ m_struct_get_field(const m_struct_t* st,
///@}
-#endif /* M_STRUCT_H */
+#endif /* MPLAYER_M_STRUCT_H */
Modified: trunk/mangle.h
==============================================================================
--- trunk/mangle.h (original)
+++ trunk/mangle.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* File licensed under the GPL, see http://www.fsf.org/ for more info.
*/
-#ifndef MANGLE_H
-#define MANGLE_H
+#ifndef MPLAYER_MANGLE_H
+#define MPLAYER_MANGLE_H
/* Feel free to add more to the list, eg. a.out IMO */
#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__OS2__) || \
@@ -15,4 +15,4 @@
#define MANGLE(a) #a
#endif
-#endif /* MANGLE_H */
+#endif /* MPLAYER_MANGLE_H */
Modified: trunk/metadata.h
==============================================================================
--- trunk/metadata.h (original)
+++ trunk/metadata.h Fri Feb 22 10:09:46 2008
@@ -17,8 +17,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef METADATA_H
-#define METADATA_H
+#ifndef MPLAYER_METADATA_H
+#define MPLAYER_METADATA_H
typedef enum metadata_s metadata_t;
enum metadata_s {
@@ -47,5 +47,5 @@ enum metadata_s {
char *get_metadata (metadata_t type);
-#endif /* METADATA_H */
+#endif /* MPLAYER_METADATA_H */
Modified: trunk/mp_core.h
==============================================================================
--- trunk/mp_core.h (original)
+++ trunk/mp_core.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MP_CORE_H
-#define MP_CORE_H
+#ifndef MPLAYER_MP_CORE_H
+#define MPLAYER_MP_CORE_H
#include "mp_osd.h"
@@ -120,4 +120,4 @@ void exit_player_with_rc(const char* how
void add_subtitles(char *filename, float fps, int noerr);
int reinit_video_chain(void);
-#endif /* MP_CORE_H */
+#endif /* MPLAYER_MP_CORE_H */
Modified: trunk/mp_fifo.h
==============================================================================
--- trunk/mp_fifo.h (original)
+++ trunk/mp_fifo.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
-#ifndef MP_FIFO_H
-#define MP_FIFO_H
+#ifndef MPLAYER_MP_FIFO_H
+#define MPLAYER_MP_FIFO_H
int mplayer_get_key(int fd);
void mplayer_put_key(int code);
-#endif /* MP_FIFO_H */
+#endif /* MPLAYER_MP_FIFO_H */
Modified: trunk/mp_msg.h
==============================================================================
--- trunk/mp_msg.h (original)
+++ trunk/mp_msg.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,5 @@
-
-#ifndef MP_MSG_H
-#define MP_MSG_H
+#ifndef MPLAYER_MP_MSG_H
+#define MPLAYER_MP_MSG_H
// defined in mplayer.c and mencoder.c
extern int verbose;
@@ -138,4 +137,4 @@ const char* filename_recode(const char*
#endif /* TARGET_OS2 */
-#endif /* MP_MSG_H */
+#endif /* MPLAYER_MP_MSG_H */
Modified: trunk/mp_osd.h
==============================================================================
--- trunk/mp_osd.h (original)
+++ trunk/mp_osd.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MP_OSD_H
-#define MP_OSD_H
+#ifndef MPLAYER_MP_OSD_H
+#define MPLAYER_MP_OSD_H
#define OSD_MSG_TV_CHANNEL 0
#define OSD_MSG_TEXT 1
@@ -23,4 +23,4 @@ void set_osd_bar(int type,const char* na
void set_osd_msg(int id, int level, int time, const char* fmt, ...);
void rm_osd_msg(int id);
-#endif /* MP_OSD_H */
+#endif /* MPLAYER_MP_OSD_H */
Modified: trunk/mpbswap.h
==============================================================================
--- trunk/mpbswap.h (original)
+++ trunk/mpbswap.h Fri Feb 22 10:09:46 2008
@@ -1,9 +1,9 @@
-#ifndef MPBSWAP_H
-#define MPBSWAP_H
+#ifndef MPLAYER_MPBSWAP_H
+#define MPLAYER_MPBSWAP_H
#include "libavutil/bswap.h"
#ifndef HAVE_SWAB
void swab(const void *from, void *to, ssize_t n);
#endif
-#endif /* MPBSWAP_H */
+#endif /* MPLAYER_MPBSWAP_H */
Modified: trunk/mpcommon.h
==============================================================================
--- trunk/mpcommon.h (original)
+++ trunk/mpcommon.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef MPCOMMON_H
-#define MPCOMMON_H
+#ifndef MPLAYER_MPCOMMON_H
+#define MPLAYER_MPCOMMON_H
extern double sub_last_pts;
extern struct ass_track_s *ass_track;
@@ -7,4 +7,4 @@ extern subtitle *vo_sub_last;
void update_subtitles(sh_video_t *sh_video, demux_stream_t *d_dvdsub, int reset);
void update_teletext(sh_video_t *sh_video, demuxer_t *demuxer, int reset);
-#endif /* MPCOMMON_H */
+#endif /* MPLAYER_MPCOMMON_H */
Modified: trunk/mplayer.h
==============================================================================
--- trunk/mplayer.h (original)
+++ trunk/mplayer.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef MPLAYER_H
-#define MPLAYER_H
+#ifndef MPLAYER_MPLAYER_H
+#define MPLAYER_MPLAYER_H
extern char* current_module;
@@ -50,4 +50,4 @@ extern int vobsub_id;
extern void exit_player(const char* how);
extern void update_set_of_subtitles(void);
-#endif /* MPLAYER_H */
+#endif /* MPLAYER_MPLAYER_H */
Modified: trunk/osdep/getch2.h
==============================================================================
--- trunk/osdep/getch2.h (original)
+++ trunk/osdep/getch2.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
/* GyS-TermIO v2.0 (for GySmail v3) (C) 1999 A'rpi/ESP-team */
/* a very small replacement of ncurses library */
-#ifndef GETCH2_H
-#define GETCH2_H
+#ifndef MPLAYER_GETCH2_H
+#define MPLAYER_GETCH2_H
/* Screen size. Initialized by load_termcap() and get_screen_size() */
extern int screen_width;
@@ -35,4 +35,4 @@ extern int mp_input_slave_cmd_func(int f
#define MP_INPUT_SLAVE_CMD_FUNC NULL
#endif
-#endif /* GETCH2_H */
+#endif /* MPLAYER_GETCH2_H */
Modified: trunk/osdep/glob.h
==============================================================================
--- trunk/osdep/glob.h (original)
+++ trunk/osdep/glob.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef GLOB_H
-#define GLOB_H
+#ifndef MPLAYER_GLOB_H
+#define MPLAYER_GLOB_H
#include "config.h"
@@ -13,4 +13,4 @@ void globfree(glob_t *pglob);
int glob(const char *pattern, int flags, int (*errfunc)(const char *epath, int eerrno), glob_t *pglob);
-#endif /* GLOB_H */
+#endif /* MPLAYER_GLOB_H */
Modified: trunk/osdep/keycodes.h
==============================================================================
--- trunk/osdep/keycodes.h (original)
+++ trunk/osdep/keycodes.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
/* KEY code definitions for GyS-TermIO v2.0 (C) 1999 A'rpi/ESP-team */
-#ifndef KEYCODES_H
-#define KEYCODES_H
+#ifndef MPLAYER_KEYCODES_H
+#define MPLAYER_KEYCODES_H
#define KEY_ENTER 13
#define KEY_TAB 9
@@ -74,4 +74,4 @@
#define KEY_INTERN (0x1000)
#define KEY_CLOSE_WIN (KEY_INTERN+0)
-#endif /* KEYCODES_H */
+#endif /* MPLAYER_KEYCODES_H */
Modified: trunk/osdep/mmap_anon.h
==============================================================================
--- trunk/osdep/mmap_anon.h (original)
+++ trunk/osdep/mmap_anon.h Fri Feb 22 10:09:46 2008
@@ -1,8 +1,8 @@
-#ifndef MMAP_ANON_H
-#define MMAP_ANON_H
+#ifndef MPLAYER_MMAP_ANON_H
+#define MPLAYER_MMAP_ANON_H
#include <sys/types.h>
void *mmap_anon(void *, size_t, int, int, off_t);
-#endif /* MMAP_ANON_H */
+#endif /* MPLAYER_MMAP_ANON_H */
Modified: trunk/osdep/shmem.h
==============================================================================
--- trunk/osdep/shmem.h (original)
+++ trunk/osdep/shmem.h Fri Feb 22 10:09:46 2008
@@ -1,7 +1,7 @@
-#ifndef SHMEM_H
-#define SHMEM_H
+#ifndef MPLAYER_SHMEM_H
+#define MPLAYER_SHMEM_H
void* shmem_alloc(int size);
void shmem_free(void* p,int size);
-#endif /* SHMEM_H */
+#endif /* MPLAYER_SHMEM_H */
Modified: trunk/parser-cfg.h
==============================================================================
--- trunk/parser-cfg.h (original)
+++ trunk/parser-cfg.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef PARSER_CFG_H
-#define PARSER_CFG_H
+#ifndef MPLAYER_PARSER_CFG_H
+#define MPLAYER_PARSER_CFG_H
extern int m_config_parse_config_file(m_config_t* config, char *conffile);
-#endif /* PARSER_CFG_H */
+#endif /* MPLAYER_PARSER_CFG_H */
Modified: trunk/parser-mecmd.h
==============================================================================
--- trunk/parser-mecmd.h (original)
+++ trunk/parser-mecmd.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef PARSER_MECMD_H
-#define PARSER_MECMD_H
+#ifndef MPLAYER_PARSER_MECMD_H
+#define MPLAYER_PARSER_MECMD_H
/// \file
/// \ingroup ConfigParsers MEntry
@@ -32,4 +32,4 @@ m_config_parse_me_command_line(m_config_
///@}
-#endif /* PARSER_MECMD_H */
+#endif /* MPLAYER_PARSER_MECMD_H */
Modified: trunk/parser-mpcmd.h
==============================================================================
--- trunk/parser-mpcmd.h (original)
+++ trunk/parser-mpcmd.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef PARSER_MPCMD_H
-#define PARSER_MPCMD_H
+#ifndef MPLAYER_PARSER_MPCMD_H
+#define MPLAYER_PARSER_MPCMD_H
extern play_tree_t* m_config_parse_mp_command_line(m_config_t *config, int argc, char **argv);
-#endif /* PARSER_MPCMD_H */
+#endif /* MPLAYER_PARSER_MPCMD_H */
Modified: trunk/playtree.h
==============================================================================
--- trunk/playtree.h (original)
+++ trunk/playtree.h Fri Feb 22 10:09:46 2008
@@ -1,10 +1,9 @@
+#ifndef MPLAYER_PLAYTREE_H
+#define MPLAYER_PLAYTREE_H
/// \file
/// \ingroup Playtree
-#ifndef PLAYTREE_H
-#define PLAYTREE_H
-
struct stream_st;
struct m_config;
@@ -282,6 +281,6 @@ void pt_iter_goto_head(play_tree_iter_t*
///@}
-#endif /* PLAYTREE_H */
-
///@}
+
+#endif /* MPLAYER_PLAYTREE_H */
Modified: trunk/playtreeparser.h
==============================================================================
--- trunk/playtreeparser.h (original)
+++ trunk/playtreeparser.h Fri Feb 22 10:09:46 2008
@@ -1,3 +1,5 @@
+#ifndef MPLAYER_PLAYTREEPARSER_H
+#define MPLAYER_PLAYTREEPARSER_H
/// \defgroup PlaytreeParser Playtree parser
/// \ingroup Playtree
@@ -8,9 +10,6 @@
/// \file
-#ifndef PLAYTREEPARSER_H
-#define PLAYTREEPARSER_H
-
struct stream_st;
typedef struct play_tree_parser {
@@ -47,6 +46,6 @@ play_tree_parser_get_play_tree(play_tree
void
play_tree_add_bpf(play_tree_t* pt, char* filename);
-#endif /* PLAYTREEPARSER_H */
-
///@}
+
+#endif /* MPLAYER_PLAYTREEPARSER_H */
Modified: trunk/stream/audio_in.h
==============================================================================
--- trunk/stream/audio_in.h (original)
+++ trunk/stream/audio_in.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef AUDIO_IN_H
-#define AUDIO_IN_H
+#ifndef MPLAYER_AUDIO_IN_H
+#define MPLAYER_AUDIO_IN_H
#define AUDIO_IN_ALSA 1
#define AUDIO_IN_OSS 2
@@ -72,4 +72,4 @@ int ai_oss_set_channels(audio_in_t *ai);
int ai_oss_init(audio_in_t *ai);
#endif
-#endif /* AUDIO_IN_H */
+#endif /* MPLAYER_AUDIO_IN_H */
Modified: trunk/stream/cache2.h
==============================================================================
--- trunk/stream/cache2.h (original)
+++ trunk/stream/cache2.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef CACHE2_H
-#define CACHE2_H
+#ifndef MPLAYER_CACHE2_H
+#define MPLAYER_CACHE2_H
extern void cache_uninit(stream_t *s);
-#endif /* CACHE2_H */
+#endif /* MPLAYER_CACHE2_H */
Modified: trunk/stream/cdd.h
==============================================================================
--- trunk/stream/cdd.h (original)
+++ trunk/stream/cdd.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef CDD_H
-#define CDD_H
+#ifndef MPLAYER_CDD_H
+#define MPLAYER_CDD_H
#include "config.h"
#ifndef HAVE_LIBCDIO
@@ -74,4 +74,4 @@ cd_track_t* cd_info_get_track(cd_info_t
void cd_info_debug(cd_info_t *cd_info);
-#endif /* CDD_H */
+#endif /* MPLAYER_CDD_H */
Modified: trunk/stream/cookies.h
==============================================================================
--- trunk/stream/cookies.h (original)
+++ trunk/stream/cookies.h Fri Feb 22 10:09:46 2008
@@ -5,12 +5,12 @@
* by Dave Lambley <mplayer(a)davel.me.uk>
*/
-#ifndef COOKIES_H
-#define COOKIES_H
+#ifndef MPLAYER_COOKIES_H
+#define MPLAYER_COOKIES_H
#include "http.h"
extern void cookies_set(HTTP_header_t * http_hdr, const char *hostname,
const char *url);
-#endif /* COOKIES_H */
+#endif /* MPLAYER_COOKIES_H */
Modified: trunk/stream/dvbin.h
==============================================================================
--- trunk/stream/dvbin.h (original)
+++ trunk/stream/dvbin.h Fri Feb 22 10:09:46 2008
@@ -5,8 +5,8 @@
* $Id$
*/
-#ifndef DVBIN_H
-#define DVBIN_H
+#ifndef MPLAYER_DVBIN_H
+#define MPLAYER_DVBIN_H
#include "stream.h"
@@ -113,4 +113,4 @@ extern int dvb_set_channel(stream_t *, i
extern dvb_config_t *dvb_get_config(void);
extern void dvb_free_config(dvb_config_t *config);
-#endif /* DVBIN_H */
+#endif /* MPLAYER_DVBIN_H */
Modified: trunk/stream/frequencies.h
==============================================================================
--- trunk/stream/frequencies.h (original)
+++ trunk/stream/frequencies.h Fri Feb 22 10:09:46 2008
@@ -6,8 +6,8 @@
* Frequencies are given in kHz
*/
-#ifndef FREQUENCIES_H
-#define FREQUENCIES_H
+#ifndef MPLAYER_FREQUENCIES_H
+#define MPLAYER_FREQUENCIES_H
#define NTSC_AUDIO_CARRIER 4500
#define PAL_AUDIO_CARRIER_I 6000
@@ -114,4 +114,4 @@ extern int chantab;
extern const struct CHANLIST *chanlist;
extern int chancount;
-#endif /* FREQUENCIES_H */
+#endif /* MPLAYER_FREQUENCIES_H */
Modified: trunk/stream/http.h
==============================================================================
--- trunk/stream/http.h (original)
+++ trunk/stream/http.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* (C) 2001, MPlayer team.
*/
-#ifndef HTTP_H
-#define HTTP_H
+#ifndef MPLAYER_HTTP_H
+#define MPLAYER_HTTP_H
typedef struct HTTP_field_type {
char *field_name;
@@ -49,4 +49,4 @@ int http_add_basic_authentication( HTTP
void http_debug_hdr( HTTP_header_t *http_hdr );
int base64_encode(const void *enc, int encLen, char *out, int outMax);
-#endif /* HTTP_H */
+#endif /* MPLAYER_HTTP_H */
Modified: trunk/stream/librtsp/rtsp.h
==============================================================================
--- trunk/stream/librtsp/rtsp.h (original)
+++ trunk/stream/librtsp/rtsp.h Fri Feb 22 10:09:46 2008
@@ -29,8 +29,8 @@
* fixed a lot of RFC compliance issues.
*/
-#ifndef RTSP_H
-#define RTSP_H
+#ifndef MPLAYER_RTSP_H
+#define MPLAYER_RTSP_H
/* some codes returned by rtsp_request_* functions */
@@ -80,4 +80,4 @@ void rtsp_schedule_field(rtsp_t *s, cons
void rtsp_unschedule_field(rtsp_t *s, const char *string);
void rtsp_unschedule_all(rtsp_t *s);
-#endif /* RTSP_H */
+#endif /* MPLAYER_RTSP_H */
Modified: trunk/stream/librtsp/rtsp_rtp.h
==============================================================================
--- trunk/stream/librtsp/rtsp_rtp.h (original)
+++ trunk/stream/librtsp/rtsp_rtp.h Fri Feb 22 10:09:46 2008
@@ -18,8 +18,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef RTSP_RTP_H
-#define RTSP_RTP_H
+#ifndef MPLAYER_RTSP_RTP_H
+#define MPLAYER_RTSP_RTP_H
#include "rtsp.h"
@@ -37,5 +37,5 @@ off_t rtp_read (struct rtp_rtsp_session_
void rtp_session_free (struct rtp_rtsp_session_t *st);
void rtcp_send_rr (rtsp_t *s, struct rtp_rtsp_session_t *st);
-#endif /* RTSP_RTP_H */
+#endif /* MPLAYER_RTSP_RTP_H */
Modified: trunk/stream/librtsp/rtsp_session.h
==============================================================================
--- trunk/stream/librtsp/rtsp_session.h (original)
+++ trunk/stream/librtsp/rtsp_session.h Fri Feb 22 10:09:46 2008
@@ -28,8 +28,8 @@
* Support for MPEG-TS streaming through RFC compliant RTSP servers
*/
-#ifndef HAVE_RTSP_SESSION_H
-#define HAVE_RTSP_SESSION_H
+#ifndef MPLAYER_RTSP_SESSION_H
+#define MPLAYER_RTSP_SESSION_H
typedef struct rtsp_session_s rtsp_session_t;
@@ -40,4 +40,4 @@ int rtsp_session_read(rtsp_session_t *se
void rtsp_session_end(rtsp_session_t *session);
-#endif /* HAVE_RTSP_SESSION_H */
+#endif /* MPLAYER_RTSP_SESSION_H */
Modified: trunk/stream/netstream.h
==============================================================================
--- trunk/stream/netstream.h (original)
+++ trunk/stream/netstream.h Fri Feb 22 10:09:46 2008
@@ -7,8 +7,8 @@
* Data is always low endian
*/
-#ifndef NETSTREAM_H
-#define NETSTREAM_H
+#ifndef MPLAYER_NETSTREAM_H
+#define MPLAYER_NETSTREAM_H
typedef struct mp_net_stream_packet_st {
uint16_t len;
@@ -138,4 +138,4 @@ static void net_stream_opened_2_me(mp_ne
o->end_pos = le2me_64(o->end_pos);
}
-#endif /* NETSTREAM_H */
+#endif /* MPLAYER_NETSTREAM_H */
Modified: trunk/stream/network.h
==============================================================================
--- trunk/stream/network.h (original)
+++ trunk/stream/network.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* (C) 2001, MPlayer team.
*/
-#ifndef NETWORK_H
-#define NETWORK_H
+#ifndef MPLAYER_NETWORK_H
+#define MPLAYER_NETWORK_H
#include <fcntl.h>
#include <sys/time.h>
@@ -63,4 +63,4 @@ HTTP_header_t *http_read_response(int fd
int http_authenticate(HTTP_header_t *http_hdr, URL_t *url, int *auth_retry);
URL_t* check4proxies(URL_t *url);
-#endif /* NETWORK_H */
+#endif /* MPLAYER_NETWORK_H */
Modified: trunk/stream/pnm.h
==============================================================================
--- trunk/stream/pnm.h (original)
+++ trunk/stream/pnm.h Fri Feb 22 10:09:46 2008
@@ -22,8 +22,8 @@
* pnm util functions header by joschka
*/
-#ifndef PNM_H
-#define PNM_H
+#ifndef MPLAYER_PNM_H
+#define MPLAYER_PNM_H
#include <inttypes.h>
/*#include "xine_internal.h" */
@@ -34,4 +34,4 @@ typedef struct pnm_s pnm_t;
//int pnm_read (pnm_t *this, char *data, int len);
-#endif /* PNM_H */
+#endif /* MPLAYER_PNM_H */
Modified: trunk/stream/pvr.h
==============================================================================
--- trunk/stream/pvr.h (original)
+++ trunk/stream/pvr.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef PVR_H
-#define PVR_H
+#ifndef MPLAYER_PVR_H
+#define MPLAYER_PVR_H
#include "tv.h"
@@ -84,4 +84,4 @@ int pvr_set_channel_step (stream_t *stre
*/
int pvr_force_freq_step (stream_t *stream, int step);
-#endif /* PVR_H */
+#endif /* MPLAYER_PVR_H */
Modified: trunk/stream/realrtsp/asmrp.h
==============================================================================
--- trunk/stream/realrtsp/asmrp.h (original)
+++ trunk/stream/realrtsp/asmrp.h Fri Feb 22 10:09:46 2008
@@ -37,11 +37,11 @@
*/
-#ifndef ASMRP_H
-#define ASMRP_H
+#ifndef MPLAYER_ASMRP_H
+#define MPLAYER_ASMRP_H
#define MAX_RULEMATCHES 16
int asmrp_match (const char *rules, int bandwidth, int *matches) ;
-#endif /* ASMRP_H */
+#endif /* MPLAYER_ASMRP_H */
Modified: trunk/stream/realrtsp/real.h
==============================================================================
--- trunk/stream/realrtsp/real.h (original)
+++ trunk/stream/realrtsp/real.h Fri Feb 22 10:09:46 2008
@@ -27,8 +27,8 @@
*
*/
-#ifndef HAVE_REAL_H
-#define HAVE_REAL_H
+#ifndef MPLAYER_REAL_H
+#define MPLAYER_REAL_H
#include "rmff.h"
#include "../librtsp/rtsp.h"
@@ -57,4 +57,4 @@ rmff_header_t *real_setup_and_get_header
struct real_rtsp_session_t *init_real_rtsp_session (void);
void free_real_rtsp_session (struct real_rtsp_session_t* real_session);
-#endif /* HAVE_REAL_H */
+#endif /* MPLAYER_REAL_H */
Modified: trunk/stream/realrtsp/rmff.h
==============================================================================
--- trunk/stream/realrtsp/rmff.h (original)
+++ trunk/stream/realrtsp/rmff.h Fri Feb 22 10:09:46 2008
@@ -26,6 +26,9 @@
* adopted from joschkas real tools
*/
+#ifndef MPLAYER_RMFF_H
+#define MPLAYER_RMFF_H
+
#include <sys/types.h>
#include "config.h"
#ifndef HAVE_WINSOCK2
@@ -43,10 +46,6 @@
#include <inttypes.h>
-#ifndef HAVE_RMFF_H
-#define HAVE_RMFF_H
-
-
#define RMFF_HEADER_SIZE 0x12
#define RMFF_FILEHEADER_SIZE 18
@@ -273,4 +272,4 @@ void rmff_dump_pheader(rmff_pheader_t *h
*/
void rmff_free_header(rmff_header_t *h);
-#endif /* HAVE_RMFF_H */
+#endif /* MPLAYER_RMFF_H */
Modified: trunk/stream/realrtsp/sdpplin.h
==============================================================================
--- trunk/stream/realrtsp/sdpplin.h (original)
+++ trunk/stream/realrtsp/sdpplin.h Fri Feb 22 10:09:46 2008
@@ -25,9 +25,9 @@
* sdp/sdpplin parser.
*
*/
-
-#ifndef HAVE_SDPPLIN_H
-#define HAVE_SDPPLIN_H
+
+#ifndef MPLAYER_SDPPLIN_H
+#define MPLAYER_SDPPLIN_H
#include "rmff.h"
#include "../librtsp/rtsp.h"
@@ -105,4 +105,4 @@ sdpplin_t *sdpplin_parse(char *data);
void sdpplin_free(sdpplin_t *description);
-#endif /* HAVE_SDPPLIN_H */
+#endif /* MPLAYER_SDPPLIN_H */
Modified: trunk/stream/realrtsp/xbuffer.h
==============================================================================
--- trunk/stream/realrtsp/xbuffer.h (original)
+++ trunk/stream/realrtsp/xbuffer.h Fri Feb 22 10:09:46 2008
@@ -13,9 +13,8 @@
*
*/
-
-#ifndef XBUFFER_H
-#define XBUFFER_H
+#ifndef MPLAYER_XBUFFER_H
+#define MPLAYER_XBUFFER_H
void *xbuffer_init(int chunk_size);
void *xbuffer_free(void *buf);
@@ -23,4 +22,4 @@ void *xbuffer_copyin(void *buf, int inde
void *xbuffer_ensure_size(void *buf, int size);
void *xbuffer_strcat(void *buf, char *data);
-#endif /* XBUFFER_H */
+#endif /* MPLAYER_XBUFFER_H */
Modified: trunk/stream/rtp.h
==============================================================================
--- trunk/stream/rtp.h (original)
+++ trunk/stream/rtp.h Fri Feb 22 10:09:46 2008
@@ -5,9 +5,9 @@
* $Id$
*/
-#ifndef RTP_H
-#define RTP_H
+#ifndef MPLAYER_RTP_H
+#define MPLAYER_RTP_H
int read_rtp_from_server(int fd, char *buffer, int length);
-#endif /* RTP_H */
+#endif /* MPLAYER_RTP_H */
Modified: trunk/stream/stream.h
==============================================================================
--- trunk/stream/stream.h (original)
+++ trunk/stream/stream.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef STREAM_H
-#define STREAM_H
+#ifndef MPLAYER_STREAM_H
+#define MPLAYER_STREAM_H
#include "mp_msg.h"
#include <string.h>
@@ -311,4 +311,4 @@ typedef struct {
int channels;
} stream_language_t;
-#endif /* STREAM_H */
+#endif /* MPLAYER_STREAM_H */
Modified: trunk/stream/stream_dvd.h
==============================================================================
--- trunk/stream/stream_dvd.h (original)
+++ trunk/stream/stream_dvd.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef STREAM_DVD_H
-#define STREAM_DVD_H
+#ifndef MPLAYER_STREAM_DVD_H
+#define MPLAYER_STREAM_DVD_H
#ifdef USE_DVDREAD_INTERNAL
#include "dvdread/dvd_reader.h"
@@ -48,4 +48,4 @@ int dvd_aid_from_lang(stream_t *stream,
int dvd_sid_from_lang(stream_t *stream, unsigned char* lang);
int dvd_chapter_from_cell(dvd_priv_t *dvd,int title,int cell);
-#endif /* STREAM_DVD_H */
+#endif /* MPLAYER_STREAM_DVD_H */
Modified: trunk/stream/stream_dvd_common.h
==============================================================================
--- trunk/stream/stream_dvd_common.h (original)
+++ trunk/stream/stream_dvd_common.h Fri Feb 22 10:09:46 2008
@@ -1,6 +1,6 @@
-#ifndef STREAM_DVD_COMMON_H
-#define STREAM_DVD_COMMON_H
+#ifndef MPLAYER_STREAM_DVD_COMMON_H
+#define MPLAYER_STREAM_DVD_COMMON_H
int mp_dvdtimetomsec(dvd_time_t *dt);
-#endif /* STREAM_DVD_COMMON_H */
+#endif /* MPLAYER_STREAM_DVD_COMMON_H */
Modified: trunk/stream/stream_radio.h
==============================================================================
--- trunk/stream/stream_radio.h (original)
+++ trunk/stream/stream_radio.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef STREAM_RADIO_H
-#define STREAM_RADIO_H
+#ifndef MPLAYER_STREAM_RADIO_H
+#define MPLAYER_STREAM_RADIO_H
#define RADIO_CHANNEL_LOWER 1
#define RADIO_CHANNEL_HIGHER 2
@@ -41,4 +41,4 @@ int radio_set_channel(struct stream_st *
int radio_step_channel(struct stream_st *stream, int direction);
int radio_step_freq(struct stream_st *stream, float step_interval);
-#endif
+#endif /* MPLAYER_STREAM_RADIO_H */
Modified: trunk/stream/tcp.h
==============================================================================
--- trunk/stream/tcp.h (original)
+++ trunk/stream/tcp.h Fri Feb 22 10:09:46 2008
@@ -19,8 +19,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef TCP_H
-#define TCP_H
+#ifndef MPLAYER_TCP_H
+#define MPLAYER_TCP_H
/* Connect to a server using a TCP connection */
int connect2Server (char *host, int port, int verb);
@@ -29,4 +29,4 @@ int connect2Server (char *host, int port
#define TCP_ERROR_FATAL -2 /* unable to resolve name */
#define TCP_ERROR_PORT -1 /* unable to connect to a particular port */
-#endif /* TCP_H */
+#endif /* MPLAYER_TCP_H */
Modified: trunk/stream/tv.h
==============================================================================
--- trunk/stream/tv.h (original)
+++ trunk/stream/tv.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef TV_H
-#define TV_H
+#ifndef MPLAYER_TV_H
+#define MPLAYER_TV_H
//#include "libao2/afmt.h"
//#include "libmpcodecs/img_format.h"
@@ -344,4 +344,4 @@ typedef struct tt_stream_props_s{
int bufsize; ///< required buffer size
} tt_stream_props;
-#endif /* TV_H */
+#endif /* MPLAYER_TV_H */
Modified: trunk/stream/tvi_def.h
==============================================================================
--- trunk/stream/tvi_def.h (original)
+++ trunk/stream/tvi_def.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef TVI_DEF_H
-#define TVI_DEF_H
+#ifndef MPLAYER_TVI_DEF_H
+#define MPLAYER_TVI_DEF_H
#include <stdlib.h> /* malloc */
#include <string.h> /* memset */
@@ -107,4 +107,4 @@ static inline void fill_blank_frame(char
}
}
-#endif /* TVI_DEF_H */
+#endif /* MPLAYER_TVI_DEF_H */
Modified: trunk/stream/tvi_dshow.h
==============================================================================
--- trunk/stream/tvi_dshow.h (original)
+++ trunk/stream/tvi_dshow.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef TVI_DSHOW_H_
-#define TVI_DSHOW_H_
+#ifndef MPLAYER_TVI_DSHOW_H
+#define MPLAYER_TVI_DSHOW_H
/// \defgroup tvi_dshow TV driver (Directshow)
@@ -690,4 +690,4 @@ DECLARE_ENUMERATOR_(IEnumMediaTypes, AM_
#define OLE_RELEASE_SAFE(p) if(p){ OLE_CALL((IUnknown*)p,Release); p=NULL;}
#define OLE_QUERYINTERFACE(p,iface,ptr) OLE_CALL_ARGS((IUnknown*)p,QueryInterface,&iface,(void*)&ptr)
-#endif // TVI_DSHOW_H_
+#endif /* MPLAYER_TVI_DSHOW_H */
Modified: trunk/stream/udp.h
==============================================================================
--- trunk/stream/udp.h (original)
+++ trunk/stream/udp.h Fri Feb 22 10:09:46 2008
@@ -17,9 +17,9 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef UDP_H
-#define UDP_H
+#ifndef MPLAYER_UDP_H
+#define MPLAYER_UDP_H
int udp_open_socket (URL_t *url);
-#endif /* UDP_H */
+#endif /* MPLAYER_UDP_H */
Modified: trunk/stream/url.h
==============================================================================
--- trunk/stream/url.h (original)
+++ trunk/stream/url.h Fri Feb 22 10:09:46 2008
@@ -4,8 +4,8 @@
* (C) 2001, MPlayer team.
*/
-#ifndef URL_H
-#define URL_H
+#ifndef MPLAYER_URL_H
+#define MPLAYER_URL_H
//#define URL_DEBUG
@@ -30,4 +30,4 @@ void url_escape_string(char *outbuf, con
void url_debug(const URL_t* url);
#endif /* URL_DEBUG */
-#endif /* URL_H */
+#endif /* MPLAYER_URL_H */
Modified: trunk/stream/vcd_read.h
==============================================================================
--- trunk/stream/vcd_read.h (original)
+++ trunk/stream/vcd_read.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VCD_READ_H
-#define VCD_READ_H
+#ifndef MPLAYER_VCD_READ_H
+#define MPLAYER_VCD_READ_H
#include "libavutil/intreadwrite.h"
//=================== VideoCD ==========================
@@ -225,4 +225,4 @@ static int sun_vcd_read(mp_vcd_priv_t* v
#endif
-#endif /* VCD_READ_H */
+#endif /* MPLAYER_VCD_READ_H */
Modified: trunk/stream/vcd_read_darwin.h
==============================================================================
--- trunk/stream/vcd_read_darwin.h (original)
+++ trunk/stream/vcd_read_darwin.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VCD_READ_DARWIN_H
-#define VCD_READ_DARWIN_H
+#ifndef MPLAYER_VCD_READ_DARWIN_H
+#define MPLAYER_VCD_READ_DARWIN_H
#include <sys/types.h>
#include <CoreFoundation/CFBase.h>
@@ -203,4 +203,4 @@ static int vcd_read(mp_vcd_priv_t* vcd,c
return VCD_SECTOR_DATA;
}
-#endif /* VCD_READ_DARWIN_H */
+#endif /* MPLAYER_VCD_READ_DARWIN_H */
Modified: trunk/stream/vcd_read_fbsd.h
==============================================================================
--- trunk/stream/vcd_read_fbsd.h (original)
+++ trunk/stream/vcd_read_fbsd.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VCD_READ_FBSD_H
-#define VCD_READ_FBSD_H
+#ifndef MPLAYER_VCD_READ_FBSD_H
+#define MPLAYER_VCD_READ_FBSD_H
#include <sys/types.h>
#include <inttypes.h>
@@ -233,4 +233,4 @@ vcd_read(mp_vcd_priv_t* vcd, char *mem)
return VCD_SECTOR_DATA;
}
-#endif /* VCD_READ_FBSD_H */
+#endif /* MPLAYER_VCD_READ_FBSD_H */
Modified: trunk/stream/vcd_read_win32.h
==============================================================================
--- trunk/stream/vcd_read_win32.h (original)
+++ trunk/stream/vcd_read_win32.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef VCD_READ_WIN32_H
-#define VCD_READ_WIN32_H
+#ifndef MPLAYER_VCD_READ_WIN32_H
+#define MPLAYER_VCD_READ_WIN32_H
#include <ddk/ntddcdrm.h>
@@ -130,7 +130,7 @@ static int vcd_read(mp_vcd_priv_t* vcd,
return VCD_SECTOR_DATA;
}
-#endif /* VCD_READ_WIN32_H */
+#endif /* MPLAYER_VCD_READ_WIN32_H */
/*
vim:noet:sw=4:cino=\:0,g0
Modified: trunk/sub_cc.h
==============================================================================
--- trunk/sub_cc.h (original)
+++ trunk/sub_cc.h Fri Feb 22 10:09:46 2008
@@ -1,10 +1,10 @@
-#ifndef SUB_CC_H
-#define SUB_CC_H
+#ifndef MPLAYER_SUB_CC_H
+#define MPLAYER_SUB_CC_H
extern int subcc_enabled;
void subcc_init(void);
void subcc_process_data(unsigned char *inputdata,unsigned int len);
-#endif /* SUB_CC_H */
+#endif /* MPLAYER_SUB_CC_H */
Modified: trunk/subopt-helper.h
==============================================================================
--- trunk/subopt-helper.h (original)
+++ trunk/subopt-helper.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef SUBOPT_HELPER_H
-#define SUBOPT_HELPER_H
+#ifndef MPLAYER_SUBOPT_HELPER_H
+#define MPLAYER_SUBOPT_HELPER_H
/**
* \file subopt-helper.h
@@ -47,4 +47,4 @@ int int_pos( int * i );
int strargcmp(strarg_t *arg, const char *str);
int strargcasecmp(strarg_t *arg, char *str);
-#endif /* SUBOPT_HELPER_H */
+#endif /* MPLAYER_SUBOPT_HELPER_H */
Modified: trunk/unrar_exec.h
==============================================================================
--- trunk/unrar_exec.h (original)
+++ trunk/unrar_exec.h Fri Feb 22 10:09:46 2008
@@ -21,8 +21,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef UNRAR_EXEC_H
-#define UNRAR_EXEC_H
+#ifndef MPLAYER_UNRAR_EXEC_H
+#define MPLAYER_UNRAR_EXEC_H
struct RAR_archive_entry
{
@@ -51,4 +51,4 @@ int unrar_exec_list(const char *rarfile,
void unrar_exec_freelist(ArchiveList_struct *list);
-#endif /* UNRAR_EXEC_H */
+#endif /* MPLAYER_UNRAR_EXEC_H */
Modified: trunk/xvid_vbr.h
==============================================================================
--- trunk/xvid_vbr.h (original)
+++ trunk/xvid_vbr.h Fri Feb 22 10:09:46 2008
@@ -23,8 +23,8 @@
*
*****************************************************************************/
-#ifndef XVID_VBR_H
-#define XVID_VBR_H
+#ifndef MPLAYER_XVID_VBR_H
+#define MPLAYER_XVID_VBR_H
#define VBR_VERSION 0
@@ -228,4 +228,4 @@ extern int vbrUpdate(vbr_control_t *stat
int ublocks);
extern int vbrFinish(vbr_control_t *state);
-#endif /* XVID_VBR_H */
+#endif /* MPLAYER_XVID_VBR_H */
Modified: trunk/xvmc_render.h
==============================================================================
--- trunk/xvmc_render.h (original)
+++ trunk/xvmc_render.h Fri Feb 22 10:09:46 2008
@@ -1,5 +1,5 @@
-#ifndef XVMC_RENDER_H
-#define XVMC_RENDER_H
+#ifndef MPLAYER_XVMC_RENDER_H
+#define MPLAYER_XVMC_RENDER_H
#include <X11/Xlib.h>
#include <X11/Xutil.h>
@@ -52,4 +52,4 @@ typedef struct{
} xvmc_render_state_t;
-#endif /* XVMC_RENDER_H */
+#endif /* MPLAYER_XVMC_RENDER_H */
3
2
Author: rtogni
Date: Tue Feb 5 22:32:37 2008
New Revision: 25957
Log:
Check buffer index while reading to avoid sig11
Fixes bugzilla #956
Modified:
trunk/libmpdemux/demux_asf.c
Modified: trunk/libmpdemux/demux_asf.c
==============================================================================
--- trunk/libmpdemux/demux_asf.c (original)
+++ trunk/libmpdemux/demux_asf.c Tue Feb 5 22:32:37 2008
@@ -39,6 +39,16 @@ static inline unsigned read_varlen(uint8
return def;
}
+/**
+ * \brief checks if there is enough data to read the bytes given by len
+ * \param ptr pointer to read from
+ * \param endptr pointer to the end of the buffer
+ * \param len lowest 2 bits indicate number of bytes to read
+ */
+static inline int check_varlen(uint8_t *ptr, uint8_t *endptr, int len) {
+ return len&3 ? ptr + (1<<(len&3 - 1)) - 1 < endptr : 1;
+}
+
static void asf_descrambling(unsigned char **src,unsigned len, struct asf_priv* asf){
unsigned char *dst=malloc(len);
unsigned char *s2=*src;
@@ -334,6 +344,7 @@ static int demux_asf_fill_buffer(demuxer
stream_read(demux->stream,asf->packet,asf->packetsize);
if(demux->stream->eof) return 0; // EOF
+ if(asf->packetsize < 2) return 0; // Packet too short
{
unsigned char* p=asf->packet;
@@ -352,7 +363,7 @@ static int demux_asf_fill_buffer(demuxer
if( mp_msg_test(MSGT_DEMUX,MSGL_DBG2) ){
int i;
- for(i=0;i<16;i++) printf(" %02X",asf->packet[i]);
+ for(i=0;i<FFMIN(16, asf->packetsize);i++) printf(" %02X",asf->packet[i]);
printf("\n");
}
@@ -362,6 +373,7 @@ static int demux_asf_fill_buffer(demuxer
if (flags & 0x80)
{
p += (flags & 0x0f)+1;
+ if (p+1 >= p_end) return 0; // Packet too short
flags = p[0];
segtype = p[1];
}
@@ -371,12 +383,15 @@ static int demux_asf_fill_buffer(demuxer
p+=2; // skip flags & segtype
// Read packet size (plen):
+ if(!check_varlen(p, p_end, flags>> 5)) return 0; // Not enough data
plen = read_varlen(&p, flags >> 5, 0);
// Read sequence:
+ if(!check_varlen(p, p_end, flags>> 1)) return 0; // Not enough data
sequence = read_varlen(&p, flags >> 1, 0);
// Read padding size (padding):
+ if(!check_varlen(p, p_end, flags>> 3)) return 0; // Not enough data
padding = read_varlen(&p, flags >> 3, 0);
if(((flags>>5)&3)!=0){
@@ -389,12 +404,14 @@ static int demux_asf_fill_buffer(demuxer
}
// Read time & duration:
+ if (p+5 >= p_end) return 0; // Packet too short
time = AV_RL32(p); p+=4;
duration = AV_RL16(p); p+=2;
// Read payload flags:
if(flags&1){
// multiple sub-packets
+ if (p >= p_end) return 0; // Packet too short
segsizetype=p[0]>>6;
segs=p[0] & 0x3F;
++p;
@@ -421,7 +438,7 @@ static int demux_asf_fill_buffer(demuxer
if( mp_msg_test(MSGT_DEMUX,MSGL_DBG2) ){
int i;
printf("seg %d:",seg);
- for(i=0;i<16;i++) printf(" %02X",p[i]);
+ for(i=0;i<FFMIN(16, p_end - p);i++) printf(" %02X",p[i]);
printf("\n");
}
@@ -430,12 +447,15 @@ static int demux_asf_fill_buffer(demuxer
p++;
// Read media object number (seq):
+ if(!check_varlen(p, p_end, segtype >> 4)) break; // Not enough data
seq = read_varlen(&p, segtype >> 4, 0);
// Read offset or timestamp:
+ if(!check_varlen(p, p_end, segtype >> 2)) break; // Not enough data
x = read_varlen(&p, segtype >> 2, 0);
// Read replic.data len:
+ if(!check_varlen(p, p_end, segtype)) break; // Not enough data
rlen = read_varlen(&p, segtype, 0);
// printf("### rlen=%d \n",rlen);
@@ -448,6 +468,7 @@ static int demux_asf_fill_buffer(demuxer
default:
if(rlen>=8){
p+=4; // skip object size
+ if (p+3 >= p_end) break; // Packet too short
time2=AV_RL32(p); // read PTS
if (asf->asf_is_dvr_ms)
get_payload_extension_data(demux, &p, streamno, seq, &keyframe, &time2);
@@ -461,6 +482,7 @@ static int demux_asf_fill_buffer(demuxer
if(flags&1){
// multiple segments
+ if(!check_varlen(p, p_end, segsizetype)) break; // Not enough data
len = read_varlen(&p, segsizetype, plen-(p-asf->packet));
} else {
// single segment
@@ -480,6 +502,7 @@ static int demux_asf_fill_buffer(demuxer
int len2=p[0];
p++;
//printf(" group part: %d bytes\n",len2);
+ if(len2 > len - 1) break; // Not enough data
demux_asf_read_packet(demux,p,len2,streamno,seq,x,duration,-1,keyframe);
p+=len2;
len-=len2+1;
2
1
r24584 - in trunk: cfg-common.h configure libmpdemux/Makefile libmpdemux/demux_nemesi.c libmpdemux/demux_nemesi.h libmpdemux/demuxer.c stream/Makefile stream/stream_nemesi.c
by lu_zero 22 Mar '08
by lu_zero 22 Mar '08
22 Mar '08
Author: lu_zero
Date: Wed Sep 19 23:38:22 2007
New Revision: 24584
Log:
libnemesi support, yet another rtsp/rtp library...
Added:
trunk/libmpdemux/demux_nemesi.c
trunk/libmpdemux/demux_nemesi.h
trunk/stream/stream_nemesi.c
Modified:
trunk/cfg-common.h
trunk/configure
trunk/libmpdemux/Makefile
trunk/libmpdemux/demuxer.c
trunk/stream/Makefile
Modified: trunk/cfg-common.h
==============================================================================
--- trunk/cfg-common.h (original)
+++ trunk/cfg-common.h Wed Sep 19 23:38:22 2007
@@ -74,6 +74,9 @@
{"sdp", "-sdp has been removed, use sdp://file instead.\n", CONF_TYPE_PRINT, 0, 0, 0, NULL},
// -rtsp-stream-over-tcp option, specifying TCP streaming of RTP/RTCP
{"rtsp-stream-over-tcp", &rtspStreamOverTCP, CONF_TYPE_FLAG, 0, 0, 1, NULL},
+#elif defined (LIBNEMESI)
+ {"rtsp-stream-over-tcp", &rtsp_transport_tcp, CONF_TYPE_FLAG, 0, 0, 1, NULL},
+ {"rtsp-stream-over-sctp", &rtsp_transport_sctp, CONF_TYPE_FLAG, 0, 0, 1, NULL},
#else
{"rtsp-stream-over-tcp", "-rtsp-stream-over-tcp requires the \"LIVE555 Streaming Media\" libraries.\n", CONF_TYPE_PRINT, CONF_NOCFG, 0, 0, NULL},
#endif
@@ -502,6 +505,10 @@ extern m_option_t lavfdopts_conf[];
#ifdef STREAMING_LIVE555
extern int rtspStreamOverTCP;
#endif
+#ifdef LIBNEMESI
+extern int rtsp_transport_tcp;
+extern int rtsp_transport_sctp;
+#endif
extern int rtsp_port;
extern char *rtsp_destination;
Modified: trunk/configure
==============================================================================
--- trunk/configure (original)
+++ trunk/configure Wed Sep 19 23:38:22 2007
@@ -255,6 +255,7 @@ Optional features:
--enable-winsock2 enable winsock2 [autodetect]
--enable-smb enable Samba (SMB) input [autodetect]
--enable-live enable LIVE555 Streaming Media [autodetect]
+ --enable-nemesi enable Nemesi Streaming Media [autodetect]
--disable-dvdnav disable libdvdnav [autodetect]
--disable-dvdread disable libdvdread [autodetect]
--disable-dvdread-internal disable internal libdvdread [autodetect]
@@ -587,6 +588,8 @@ _libdvdcss_internal=auto
_xanim=auto
_real=auto
_live=auto
+_nemesi=auto
+_native_rtsp=yes
_xinerama=auto
_mga=no
_xmga=auto
@@ -944,6 +947,8 @@ for ac_option do
--disable-real) _real=no ;;
--enable-live) _live=yes ;;
--disable-live) _live=no ;;
+ --enable-nemesi) _nemesi=yes ;;
+ --disable-nemesi) _nemesi=no ;;
--enable-xinerama) _xinerama=yes ;;
--disable-xinerama) _xinerama=no ;;
--enable-mga) _mga=yes ;;
@@ -6222,6 +6227,24 @@ else
fi
echores "$_qtx"
+echocheck "Nemesi Streaming Media libraries"
+if test "$_nemesi" = auto && test "$_network" = yes ; then
+ _nemesi=no
+ if $_pkg_config --exists libnemesi ; then
+ _ld_extra="$_ld_extra `$_pkg_config --libs libnemesi`"
+ _nemesi=yes
+ fi
+fi
+echores "$_nemesi"
+
+if test "$_nemesi" = yes; then
+ _native_rtsp=no
+ _def_nemesi='#define LIBNEMESI 1'
+ _inputmodules="nemesi $_inputmodules"
+else
+ _def_nemesi='#undef LIBNEMESI'
+ _noinputmodules="nemesi $_noinputmodules"
+fi
echocheck "LIVE555 Streaming Media libraries"
if test "$_live" = auto && test "$_network" = yes ; then
@@ -6254,11 +6277,11 @@ EOF
fi
fi
fi
-if test "$_live" = yes && test "$_network" = yes ; then
+if test "$_live" = yes && test "$_network" = yes && test "$_nemesi" = no; then
_res_comment="using $_livelibdir"
_def_live='#define STREAMING_LIVE555 1'
_inputmodules="live555 $_inputmodules"
-elif test "$_live_dist" = yes && test "$_network" = yes ; then
+elif test "$_live_dist" = yes && test "$_network" = yes && test "$_nemesi" = no; then
_res_comment="using distribution version"
_live="yes"
_def_live='#define STREAMING_LIVE555 1'
@@ -7519,6 +7542,8 @@ EXESUF = $_exesuf
MPLAYER_NETWORK = $_network
FTP = $_ftp
STREAMING_LIVE555 = $_live
+LIBNEMESI = $_nemesi
+NATIVE_RTSP = $_native_rtsp
VSTREAM = $_vstream
STREAM_CACHE = $_stream_cache
DVBIN = $_dvbin
@@ -8084,6 +8109,9 @@ $_def_real_path
/* LIVE555 Streaming Media library support */
$_def_live
+/* libnemesi Streaming Media library support */
+$_def_nemesi
+
/* Use 3dnow/mmxext/sse/mmx optimized fast memcpy() [maybe buggy... signal 4]*/
$_def_fastmemcpy
Modified: trunk/libmpdemux/Makefile
==============================================================================
--- trunk/libmpdemux/Makefile (original)
+++ trunk/libmpdemux/Makefile Wed Sep 19 23:38:22 2007
@@ -48,6 +48,7 @@ SRCS_COMMON = asfheader.c \
SRCS_COMMON-$(GIF) += demux_gif.c
SRCS_COMMON-$(LIBAVFORMAT) += demux_lavf.c
SRCS_COMMON-$(LIBDV) += demux_rawdv.c
+SRCS_COMMON-$(LIBNEMESI) += demux_nemesi.c
SRCS_COMMON-$(LIBNUT) += demux_nut.c
SRCS_COMMON-$(LIBVORBIS) += demux_ogg.c
SRCS_COMMON-$(MUSEPACK) += demux_mpc.c
Added: trunk/libmpdemux/demux_nemesi.c
==============================================================================
--- (empty file)
+++ trunk/libmpdemux/demux_nemesi.c Wed Sep 19 23:38:22 2007
@@ -0,0 +1,439 @@
+/*
+ * Copyright (C) 2007 Alessandro Molina <amol.wrk(a)gmail.com>
+ *
+ * MPlayer is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MPlayer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MPlayer; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "demux_nemesi.h"
+#include "stheader.h"
+#define HAVE_STRUCT_SOCKADDR_STORAGE
+#include "nemesi/rtsp.h"
+#include "nemesi/rtp.h"
+
+int rtsp_transport_tcp = 0;
+int rtsp_transport_sctp = 0;
+// extern int rtsp_port;
+
+typedef enum { NEMESI_SESSION_VIDEO,
+ NEMESI_SESSION_AUDIO } Nemesi_SessionType;
+
+typedef struct {
+ rtsp_ctrl * rtsp;
+ rtp_session * session[2];
+ rtp_frame first_pkt[2];
+ double time[2];
+ double seek;
+} Nemesi_DemuxerStreamData;
+
+static void link_session_and_fetch_conf(Nemesi_DemuxerStreamData * ndsd,
+ Nemesi_SessionType stype,
+ rtp_session * sess,
+ rtp_buff * buff, unsigned int * fps)
+{
+ extern float force_fps;
+ rtp_ssrc *ssrc;
+ rtsp_ctrl * ctl = ndsd->rtsp;
+ rtp_frame * fr = &ndsd->first_pkt[stype];
+ rtp_buff trash_buff;
+
+ ndsd->session[stype] = sess;
+
+ if (buff == NULL)
+ buff = &trash_buff;
+
+ if ( (buff != NULL) || (fps != NULL) ) {
+ rtp_fill_buffers(rtsp_get_rtp_th(ctl));
+ for (ssrc = rtp_active_ssrc_queue(rtsp_get_rtp_queue(ctl));
+ ssrc;
+ ssrc = rtp_next_active_ssrc(ssrc)) {
+ if (ssrc->rtp_sess == sess) {
+ rtp_fill_buffer(ssrc, fr, buff);
+ break;
+ }
+ }
+
+ if ( (force_fps == 0.0) && (fps != NULL) ) {
+ rtp_fill_buffers(rtsp_get_rtp_th(ctl));
+ *fps = rtp_get_fps(ssrc);
+ }
+ }
+}
+
+demuxer_t* demux_open_rtp(demuxer_t* demuxer)
+{
+ nms_rtsp_hints hints;
+ char * url = demuxer->stream->streaming_ctrl->url->url;
+ rtsp_ctrl * ctl;
+ RTSP_Error reply;
+ rtsp_medium * media;
+ Nemesi_DemuxerStreamData * ndsd = calloc(1, sizeof(Nemesi_DemuxerStreamData));
+
+ memset(&hints,0,sizeof(hints));
+// if (rtsp_port) hints.first_rtp_port = rtsp_port;
+ if (rtsp_transport_tcp) {
+ hints.pref_rtsp_proto = TCP;
+ hints.pref_rtp_proto = TCP;
+ }
+ if (rtsp_transport_sctp) {
+ hints.pref_rtsp_proto = SCTP;
+ hints.pref_rtp_proto = SCTP;
+ }
+
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "Initializing libNemesi\n");
+ if ((ctl = rtsp_init(&hints)) == NULL) {
+ free(ndsd);
+ return STREAM_ERROR;
+ }
+
+ ndsd->rtsp = ctl;
+ demuxer->priv = ndsd;
+ //nms_verbosity_set(1);
+
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "Opening: %s\n", url);
+ if (rtsp_open(ctl, url)) {
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "rtsp_open failed.\n");
+ return demuxer;
+ }
+
+ reply = rtsp_wait(ctl);
+ if (reply.got_error) {
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "OPEN Error from the server: %s\n",
+ reply.message.reply_str);
+ return demuxer;
+ }
+
+ rtsp_play(ctl, 0, 0);
+ reply = rtsp_wait(ctl);
+ if (reply.got_error) {
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "PLAY Error from the server: %s\n",
+ reply.message.reply_str);
+ return demuxer;
+ }
+
+ media = ctl->rtsp_queue->media_queue;
+ for (; media; media=media->next) {
+ sdp_medium_info * info = media->medium_info;
+ rtp_session * sess = media->rtp_sess;
+
+ int media_format = atoi(info->fmts);
+ rtp_pt * ptinfo = rtp_get_pt_info(sess, media_format);
+ char const * format_name = ptinfo ? ptinfo->name : NULL;
+
+ if (sess->parsers[media_format] == NULL) {
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "libNemesi unsupported media format: %s\n",
+ format_name ? format_name : info->fmts);
+ continue;
+ }
+ else {
+ mp_msg(MSGT_DEMUX, MSGL_INFO,
+ "libNemesi supported media: %s\n",
+ format_name);
+ }
+
+ if (ptinfo->type == AU) {
+ if (ndsd->session[NEMESI_SESSION_AUDIO] == NULL) {
+ sh_audio_t* sh_audio = new_sh_audio(demuxer,0);
+ WAVEFORMATEX* wf = calloc(1,sizeof(WAVEFORMATEX));
+ demux_stream_t* d_audio = demuxer->audio;
+
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "Detected as AUDIO stream...\n");
+
+ link_session_and_fetch_conf(ndsd, NEMESI_SESSION_AUDIO,
+ sess, NULL, NULL);
+
+ sh_audio->wf = wf;
+ d_audio->sh = sh_audio;
+ sh_audio->ds = d_audio;
+ wf->nSamplesPerSec = 0;
+
+ //List of known audio formats
+ if (!strcmp(format_name, "MPA"))
+ wf->wFormatTag =
+ sh_audio->format = 0x55;
+ else if (!strcmp(format_name, "vorbis"))
+ wf->wFormatTag =
+ sh_audio->format = mmioFOURCC('v','r','b','s');
+ else
+ mp_msg(MSGT_DEMUX, MSGL_WARN,
+ "Unknown MPlayer format code for MIME"
+ " type \"audio/%s\"\n", format_name);
+ } else {
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "There is already an audio session registered,"
+ " ignoring...\n");
+ }
+ } else if (ptinfo->type == VI) {
+ if (ndsd->session[NEMESI_SESSION_AUDIO] == NULL) {
+ sh_video_t* sh_video;
+ BITMAPINFOHEADER* bih;
+ demux_stream_t* d_video;
+ int fps = 0;
+ rtp_buff buff;
+
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "Detected as VIDEO stream...\n");
+
+ link_session_and_fetch_conf(ndsd, NEMESI_SESSION_VIDEO,
+ sess, &buff, &fps);
+
+ if (buff.len) {
+ bih = calloc(1,sizeof(BITMAPINFOHEADER)+buff.len);
+ bih->biSize = sizeof(BITMAPINFOHEADER)+buff.len;
+ memcpy(bih+1, buff.data, buff.len);
+ } else {
+ bih = calloc(1,sizeof(BITMAPINFOHEADER));
+ bih->biSize = sizeof(BITMAPINFOHEADER);
+ }
+
+ sh_video = new_sh_video(demuxer,0);
+ sh_video->bih = bih;
+ d_video = demuxer->video;
+ d_video->sh = sh_video;
+ sh_video->ds = d_video;
+
+ if (fps)
+ sh_video->fps = fps;
+
+ //List of known video formats
+ if (!strcmp(format_name, "MPV")) {
+ bih->biCompression =
+ sh_video->format = mmioFOURCC('M','P','E','G');
+ } else if (!strcmp(format_name, "H264")) {
+ bih->biCompression =
+ sh_video->format = mmioFOURCC('H','2','6','4');
+ } else {
+ mp_msg(MSGT_DEMUX, MSGL_WARN,
+ "Unknown MPlayer format code for MIME"
+ " type \"video/%s\"\n", format_name);
+ }
+ } else {
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "There is already a video session registered,"
+ " ignoring...\n");
+ }
+ } else {
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "Unsupported media type\n");
+ }
+ }
+
+ demuxer->stream->eof = 0;
+
+ return demuxer;
+}
+
+static int get_data_for_session(Nemesi_DemuxerStreamData * ndsd,
+ Nemesi_SessionType stype, rtp_frame * fr)
+{
+ rtsp_ctrl * ctl = ndsd->rtsp;
+ rtp_ssrc *ssrc = NULL;
+
+ for (ssrc = rtp_active_ssrc_queue(rtsp_get_rtp_queue(ctl));
+ ssrc;
+ ssrc = rtp_next_active_ssrc(ssrc)) {
+ if (ssrc->rtp_sess == ndsd->session[stype]) {
+ if (ndsd->first_pkt[stype].len != 0) {
+ fr->data = ndsd->first_pkt[stype].data;
+ fr->time_sec = ndsd->first_pkt[stype].time_sec;
+ fr->len = ndsd->first_pkt[stype].len;
+ ndsd->first_pkt[stype].len = 0;
+ return RTP_FILL_OK;
+ } else {
+ rtp_buff buff;
+ return rtp_fill_buffer(ssrc, fr, &buff);
+ }
+ }
+ }
+
+ return RTP_SSRC_NOTVALID;
+}
+
+int demux_rtp_fill_buffer(demuxer_t* demuxer, demux_stream_t* ds)
+{
+ Nemesi_DemuxerStreamData * ndsd = demuxer->priv;
+ Nemesi_SessionType stype;
+ rtsp_ctrl * ctl = ndsd->rtsp;
+ rtp_thread * rtp_th = rtsp_get_rtp_th(ctl);
+ rtp_frame fr;
+
+ demux_packet_t* dp;
+
+ if ( (!ctl->rtsp_queue) || (demuxer->stream->eof) || (rtp_fill_buffers(rtp_th)) ) {
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "End of Stream...\n");
+ demuxer->stream->eof = 1;
+ return 0;
+ }
+
+ if (ds == demuxer->video)
+ stype = NEMESI_SESSION_VIDEO;
+ else if (ds == demuxer->audio)
+ stype = NEMESI_SESSION_AUDIO;
+ else
+ return 0;
+
+ if(!get_data_for_session(ndsd, stype, &fr)) {
+ dp = new_demux_packet(fr.len);
+ memcpy(dp->buffer, fr.data, fr.len);
+ fr.time_sec += ndsd->seek;
+ ndsd->time[stype] = dp->pts = fr.time_sec;
+ ds_add_packet(ds, dp);
+ }
+ else {
+ stype = (stype + 1) % 2;
+ if (stype == NEMESI_SESSION_VIDEO)
+ ds = demuxer->video;
+ else
+ ds = demuxer->audio;
+
+ if(!get_data_for_session(ndsd, stype, &fr)) {
+ dp = new_demux_packet(fr.len);
+ memcpy(dp->buffer, fr.data, fr.len);
+ fr.time_sec += ndsd->seek;
+ ndsd->time[stype] = dp->pts = fr.time_sec;
+ ds_add_packet(ds, dp);
+ }
+ }
+
+ return 1;
+}
+
+
+void demux_close_rtp(demuxer_t* demuxer)
+{
+ Nemesi_DemuxerStreamData * ndsd = demuxer->priv;
+ rtsp_ctrl * ctl = ndsd->rtsp;
+ RTSP_Error err;
+
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "Closing libNemesi RTSP Stream...\n");
+
+ if (ndsd == NULL)
+ return;
+
+ free(ndsd);
+
+ if (rtsp_close(ctl)) {
+ err = rtsp_wait(ctl);
+ if (err.got_error)
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "Error Closing Stream: %s\n",
+ err.message.reply_str);
+ }
+
+ rtsp_uninit(ctl);
+}
+
+static void demux_seek_rtp(demuxer_t *demuxer, float rel_seek_secs,
+ float audio_delay, int flags)
+{
+ Nemesi_DemuxerStreamData * ndsd = demuxer->priv;
+ rtsp_ctrl * ctl = ndsd->rtsp;
+ sdp_attr * r_attr = NULL;
+ sdp_range r = {0, 0};
+ double time = ndsd->time[NEMESI_SESSION_VIDEO] ?
+ ndsd->time[NEMESI_SESSION_VIDEO] :
+ ndsd->time[NEMESI_SESSION_AUDIO];
+
+ if (!ctl->rtsp_queue)
+ return;
+
+ r_attr = sdp_get_attr(ctl->rtsp_queue->info->attr_list, "range");
+ if (r_attr)
+ r = sdp_parse_range(r_attr->value);
+
+ //flags & 1 -> absolute seek
+ //flags & 2 -> percent seek
+ if (flags == 0) {
+ time += rel_seek_secs;
+ if (time < r.begin)
+ time = r.begin;
+ else if (time > r.end)
+ time = r.end;
+ ndsd->seek = time;
+
+ mp_msg(MSGT_DEMUX,MSGL_WARN,"libNemesi SEEK %f on %f - %f)\n",
+ time, r.begin, r.end);
+
+ if (!rtsp_seek(ctl, time, 0)) {
+ RTSP_Error err = rtsp_wait(ctl);
+ if (err.got_error) {
+ mp_msg(MSGT_DEMUX, MSGL_ERR,
+ "Error Performing Seek: %s\n",
+ err.message.reply_str);
+ demuxer->stream->eof = 1;
+ }
+ else
+ mp_msg(MSGT_DEMUX, MSGL_INFO, "Seek, performed\n");
+ }
+ else {
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "Unable to pause stream to perform seek\n");
+ demuxer->stream->eof = 1;
+ }
+ }
+ else
+ mp_msg(MSGT_DEMUX, MSGL_ERR, "Unsupported seek type\n");
+}
+
+static int demux_rtp_control(struct demuxer_st *demuxer, int cmd, void *arg)
+{
+ Nemesi_DemuxerStreamData * ndsd = demuxer->priv;
+ rtsp_ctrl * ctl = ndsd->rtsp;
+ sdp_attr * r_attr = NULL;
+ sdp_range r = {0, 0};
+ double time = ndsd->time[NEMESI_SESSION_VIDEO] ?
+ ndsd->time[NEMESI_SESSION_VIDEO] :
+ ndsd->time[NEMESI_SESSION_AUDIO];
+
+ if (!ctl->rtsp_queue)
+ return DEMUXER_CTRL_DONTKNOW;
+
+ r_attr = sdp_get_attr(ctl->rtsp_queue->info->attr_list, "range");
+ if (r_attr)
+ r = sdp_parse_range(r_attr->value);
+
+ switch (cmd) {
+ case DEMUXER_CTRL_GET_TIME_LENGTH:
+ if (r.end == 0)
+ return DEMUXER_CTRL_DONTKNOW;
+
+ *((double *)arg) = ((double)r.end) - ((double)r.begin);
+ return DEMUXER_CTRL_OK;
+
+ case DEMUXER_CTRL_GET_PERCENT_POS:
+ if (r.end == 0)
+ return DEMUXER_CTRL_DONTKNOW;
+
+ *((int *)arg) = (int)( time * 100 / (r.end - r.begin) );
+ return DEMUXER_CTRL_OK;
+ default:
+ return DEMUXER_CTRL_DONTKNOW;
+ }
+}
+
+demuxer_desc_t demuxer_desc_rtp = {
+ "libNemesi demuxer",
+ "rtp",
+ "",
+ "Alessandro Molina",
+ "requires libNemesi",
+ DEMUXER_TYPE_RTP,
+ 0, // no autodetect
+ NULL,
+ demux_rtp_fill_buffer,
+ demux_open_rtp,
+ demux_close_rtp,
+ demux_seek_rtp,
+ demux_rtp_control
+};
Added: trunk/libmpdemux/demux_nemesi.h
==============================================================================
--- (empty file)
+++ trunk/libmpdemux/demux_nemesi.h Wed Sep 19 23:38:22 2007
@@ -0,0 +1,46 @@
+/*
+ * Copyright (C) 2007 Alessandro Molina <amol.wrk(a)gmail.com>
+ * based on previous Live555 RTP support.
+ *
+ * MPlayer is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MPlayer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MPlayer; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+
+#ifndef DEMUX_NEMESI_H
+#define DEMUX_NEMESI_H
+
+#include <stdlib.h>
+#include <stdio.h>
+#include "stream/stream.h"
+#include "demuxer.h"
+
+
+/**
+ * Open the RTP demuxer
+ */
+demuxer_t* demux_open_rtp(demuxer_t* demuxer);
+
+/**
+ * Read from the RTP demuxer
+ */
+int demux_rtp_fill_buffer(demuxer_t *demux, demux_stream_t* ds);
+
+/**
+ * Close the RTP demuxer
+ */
+void demux_close_rtp(demuxer_t* demuxer);
+
+#endif /* DEMUX_NEMESI_H */
+
Modified: trunk/libmpdemux/demuxer.c
==============================================================================
--- trunk/libmpdemux/demuxer.c (original)
+++ trunk/libmpdemux/demuxer.c Wed Sep 19 23:38:22 2007
@@ -116,7 +116,7 @@ demuxer_desc_t* demuxer_list[] = {
#endif
&demuxer_desc_audio,
&demuxer_desc_mpeg_ty,
-#ifdef STREAMING_LIVE555
+#if defined(STREAMING_LIVE555) || defined(LIBNEMESI)
&demuxer_desc_rtp,
#endif
#ifdef USE_LIBAVFORMAT
Modified: trunk/stream/Makefile
==============================================================================
--- trunk/stream/Makefile (original)
+++ trunk/stream/Makefile Wed Sep 19 23:38:22 2007
@@ -28,19 +28,22 @@ SRCS_COMMON-$(MPLAYER_NETWORK) += stre
udp.c \
tcp.c \
stream_rtp.c \
- stream_rtsp.c \
stream_udp.c \
+ realrtsp/asmrp.c \
+ realrtsp/real.c \
+ realrtsp/rmff.c \
+ realrtsp/sdpplin.c \
+ realrtsp/xbuffer.c \
+
+SRCS_COMMON-$(NATIVE_RTSP) += stream_rtsp.c \
freesdp/common.c \
freesdp/errorlist.c \
freesdp/parser.c \
librtsp/rtsp.c \
librtsp/rtsp_rtp.c \
librtsp/rtsp_session.c \
- realrtsp/asmrp.c \
- realrtsp/real.c \
- realrtsp/rmff.c \
- realrtsp/sdpplin.c \
- realrtsp/xbuffer.c \
+
+SRCS_COMMON-$(LIBNEMESI) += stream_nemesi.c
SRCS_COMMON-$(PVR) += stream_pvr.c
SRCS_COMMON-$(RADIO) += stream_radio.c
Added: trunk/stream/stream_nemesi.c
==============================================================================
--- (empty file)
+++ trunk/stream/stream_nemesi.c Wed Sep 19 23:38:22 2007
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2007 Alessandro Molina <amol.wrk(a)gmail.com>
+ * based on previous RTSP support from Benjamin Zores.
+ *
+ * MPlayer is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MPlayer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MPlayer; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#define HAVE_STRUCT_SOCKADDR_STORAGE
+
+#include <stdlib.h>
+#include <string.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <ctype.h>
+#include "config.h"
+
+#include "nemesi/rtsp.h"
+#include "libmpdemux/demux_nemesi.h"
+
+#include <errno.h>
+
+#include "stream.h"
+#include "tcp.h"
+
+extern int network_bandwidth;
+int rtsp_port = 0;
+char *rtsp_destination = NULL;
+
+static int rtsp_streaming_seek(int fd, off_t pos,
+ streaming_ctrl_t* streaming_ctrl) {
+ return -1;
+}
+
+static int rtsp_streaming_open (stream_t *stream, int mode, void *opts,
+ int *file_format)
+{
+ rtsp_ctrl * ctl;
+ extern int index_mode;
+ URL_t *url;
+ stream->fd = -1;
+
+ mp_msg (MSGT_OPEN, MSGL_V, "STREAM_RTSP, URL: %s\n", stream->url);
+ stream->streaming_ctrl = streaming_ctrl_new ();
+ if (!stream->streaming_ctrl)
+ return STREAM_ERROR;
+
+ stream->streaming_ctrl->bandwidth = network_bandwidth;
+ url = url_new(stream->url);
+ stream->streaming_ctrl->url = check4proxies(url);
+ stream->streaming_ctrl->streaming_seek = rtsp_streaming_seek;
+
+ *file_format = DEMUXER_TYPE_RTP;
+ stream->type = STREAMTYPE_STREAM;
+ return STREAM_OK;
+}
+
+stream_info_t stream_info_rtsp = {
+ "RTSP streaming",
+ "rtsp",
+ "Alessandro Molina",
+ "implemented over libnemesi",
+ rtsp_streaming_open,
+ {"rtsp", NULL},
+ NULL,
+ 0 /* Urls are an option string */
+};
+
5
5
Author: diego
Date: Wed Feb 27 00:24:53 2008
New Revision: 26106
Log:
Default to disabling VIDIX on platforms where it is not known to work.
Modified:
trunk/configure
Modified: trunk/configure
==============================================================================
--- trunk/configure (original)
+++ trunk/configure Wed Feb 27 00:24:53 2008
@@ -4254,10 +4254,9 @@ _def_vidix_drv_unichrome='#undef CONFIG_
_vidix_drv_unichrome=no
if test "$_vidix_internal" = auto ; then
_vidix_internal=no
- x86 && _vidix_internal=yes
- ppc && linux && _vidix_internal=yes
- alpha && linux && _vidix_internal=yes
- qnx || beos || darwin || os2 && _vidix_internal=no
+ x86 && linux || freebsd || netbsd || openbsd || sunos || win32 \
+ && _vidix_internal=yes
+ ppc || alpha && linux && _vidix_internal=yes
fi
if test "$_vidix_internal" = yes; then
_res_comment="internal"
3
4
Author: diego
Date: Thu Feb 28 19:31:35 2008
New Revision: 26111
Log:
TARGET_OS2 is never set, use __OS2__ instead.
Modified:
trunk/mp_msg.h
Modified: trunk/mp_msg.h
==============================================================================
--- trunk/mp_msg.h (original)
+++ trunk/mp_msg.h Thu Feb 28 19:31:35 2008
@@ -111,7 +111,7 @@ int mp_msg_test(int mod, int lev);
#include "config.h"
-#ifdef TARGET_OS2
+#ifdef __OS2__
// va_start/vsnprintf seems to be broken under OS2 :(
#define mp_msg(mod,lev, fmt, args... ) do{if((lev)<=mp_msg_levels[mod]) printf( fmt, ## args );}while(0)
#define mp_dbg(mod,lev, args... )
@@ -135,6 +135,6 @@ void mp_msg(int mod, int lev, const char
const char* filename_recode(const char* filename);
-#endif /* TARGET_OS2 */
+#endif /* __OS2__ */
#endif /* MPLAYER_MP_MSG_H */
4
7
r26128 - in trunk: configure vidix/Makefile vidix/drivers.c vidix/s3_regs.h vidix/s3_vid.c
by ben 01 Mar '08
by ben 01 Mar '08
01 Mar '08
Author: ben
Date: Fri Feb 29 21:01:28 2008
New Revision: 26128
Log:
New S3 VIDIX driver.
Provides support for S3 Trio and S3 Virge chipsets.
This deprecates the old Savage driver that worked with latest chips only.
(synchronized with vidix.sf.net r326 and r327)
Added:
trunk/vidix/s3_regs.h
trunk/vidix/s3_vid.c
Modified:
trunk/configure
trunk/vidix/Makefile
trunk/vidix/drivers.c
Modified: trunk/configure
==============================================================================
--- trunk/configure (original)
+++ trunk/configure Fri Feb 29 21:01:28 2008
@@ -337,7 +337,7 @@ Video output:
--disable-vidix-external disable external VIDIX [for x86 *nix]
--with-vidix-drivers[=*] list of VIDIX drivers to be compiled in
Available: cyberblade,ivtv,mach64,mga,mga_crtc2,
- nvidia,pm2,pm3,radeon,rage128,savage,sis,unichrome
+ nvidia,pm2,pm3,radeon,rage128,s3,sis,unichrome
--disable-vidix-pcidb disable VIDIX PCI device name database
--enable-gl enable OpenGL video output [autodetect]
--enable-dga2 enable DGA 2 support [autodetect]
@@ -4246,8 +4246,8 @@ _def_vidix_drv_radeon='#undef CONFIG_VID
_vidix_drv_radeon=no
_def_vidix_drv_rage128='#undef CONFIG_VIDIX_DRV_RAGE128'
_vidix_drv_rage128=no
-_def_vidix_drv_savage='#undef CONFIG_VIDIX_DRV_SAVAGE'
-_vidix_drv_savage=no
+_def_vidix_drv_s3='#undef CONFIG_VIDIX_DRV_S3'
+_vidix_drv_s3=no
_def_vidix_drv_sis='#undef CONFIG_VIDIX_DRV_SIS'
_vidix_drv_sis=no
_def_vidix_drv_unichrome='#undef CONFIG_VIDIX_DRV_UNICHROME'
@@ -4277,7 +4277,7 @@ if test "$_vidix" = yes ; then
_def_vidix='#define CONFIG_VIDIX 1'
_vosrc="$_vosrc vo_cvidix.c"
_vomodules="cvidix $_vomodules"
- test "$_vidix_drivers" || _vidix_drivers="cyberblade ivtv mach64 mga mga_crtc2 nvidia pm2 pm3 radeon rage128 savage sis unichrome"
+ test "$_vidix_drivers" || _vidix_drivers="cyberblade ivtv mach64 mga mga_crtc2 nvidia pm2 pm3 radeon rage128 s3 sis unichrome"
test $_ivtv = "yes" || _vidix_drivers=`echo $_vidix_drivers | sed s/ivtv//`
# some vidix drivers are meant to work on x86 only, discard them elsewhere
@@ -7821,7 +7821,7 @@ VIDIX_PM2=$_vidix_drv_pm2
VIDIX_PM3=$_vidix_drv_pm3
VIDIX_RADEON=$_vidix_drv_radeon
VIDIX_RAGE128=$_vidix_drv_rage128
-VIDIX_SAVAGE=$_vidix_drv_savage
+VIDIX_S3=$_vidix_drv_s3
VIDIX_SIS=$_vidix_drv_sis
VIDIX_UNICHROME=$_vidix_drv_unichrome
@@ -8504,7 +8504,7 @@ $_def_vidix_drv_nvidia
$_def_vidix_drv_pm3
$_def_vidix_drv_radeon
$_def_vidix_drv_rage128
-$_def_vidix_drv_savage
+$_def_vidix_drv_s3
$_def_vidix_drv_sis
$_def_vidix_drv_unichrome
$_def_vidix_pfx
Modified: trunk/vidix/Makefile
==============================================================================
--- trunk/vidix/Makefile (original)
+++ trunk/vidix/Makefile Fri Feb 29 21:01:28 2008
@@ -20,7 +20,7 @@ SRCS_MPLAYER-$(VIDIX_PM2)
SRCS_MPLAYER-$(VIDIX_PM3) += pm3_vid.c
SRCS_MPLAYER-$(VIDIX_RADEON) += radeon_vid.c
SRCS_MPLAYER-$(VIDIX_RAGE128) += rage128_vid.c
-SRCS_MPLAYER-$(VIDIX_SAVAGE) += savage_vid.c
+SRCS_MPLAYER-$(VIDIX_S3) += s3_vid.c
SRCS_MPLAYER-$(VIDIX_SIS) += sis_vid.c sis_bridge.c
SRCS_MPLAYER-$(VIDIX_UNICHROME) += unichrome_vid.c
Modified: trunk/vidix/drivers.c
==============================================================================
--- trunk/vidix/drivers.c (original)
+++ trunk/vidix/drivers.c Fri Feb 29 21:01:28 2008
@@ -42,7 +42,7 @@ extern VDXDriver pm2_drv;
extern VDXDriver pm3_drv;
extern VDXDriver radeon_drv;
extern VDXDriver rage128_drv;
-extern VDXDriver savage_drv;
+extern VDXDriver s3_drv;
extern VDXDriver sis_drv;
extern VDXDriver unichrome_drv;
@@ -89,8 +89,8 @@ void vidix_register_all_drivers (void)
#ifdef CONFIG_VIDIX_DRV_RAGE128
vidix_register_driver (&rage128_drv);
#endif
-#ifdef CONFIG_VIDIX_DRV_SAVAGE
- vidix_register_driver (&savage_drv);
+#ifdef CONFIG_VIDIX_DRV_S3
+ vidix_register_driver (&s3_drv);
#endif
#ifdef CONFIG_VIDIX_DRV_SIS
vidix_register_driver (&sis_drv);
Added: trunk/vidix/s3_regs.h
==============================================================================
--- (empty file)
+++ trunk/vidix/s3_regs.h Fri Feb 29 21:01:28 2008
@@ -0,0 +1,214 @@
+#ifndef _SAVAGE_REGS_H
+#define _SAVAGE_REGS_H
+
+#define S3_SAVAGE3D_SERIES(chip) ((chip>=S3_SAVAGE3D) && (chip<=S3_SAVAGE_MX))
+#define S3_SAVAGE4_SERIES(chip) ((chip==S3_SAVAGE4) || (chip==S3_PROSAVAGE))
+#define S3_SAVAGE_MOBILE_SERIES(chip) ((chip==S3_SAVAGE_MX) || (chip==S3_SUPERSAVAGE))
+#define S3_SAVAGE_SERIES(chip) ((chip>=S3_SAVAGE3D) && (chip<=S3_SAVAGE2000))
+
+/*
+ * Chip tags. These are used to group the adapters into
+ * related families.
+ */
+enum S3CHIPTAGS {
+ S3_UNKNOWN = 0,
+ S3_TRIO64V,
+ S3_VIRGE,
+ S3_SAVAGE3D,
+ S3_SAVAGE_MX,
+ S3_SAVAGE4,
+ S3_PROSAVAGE,
+ S3_SUPERSAVAGE,
+ S3_SAVAGE2000,
+ S3_LAST
+};
+
+#define BIOS_BSIZE 1024
+#define BIOS_BASE 0xc0000
+
+#define S3_NEWMMIO_REGBASE 0x1000000 /* 16MB */
+#define S3_NEWMMIO_REGSIZE 0x0010000 /* 64KB */
+#define S3_NEWMMIO_REGSIZE_SAVAGE 0x0080000 /* 512KB */
+
+#define BASE_FREQ 14.31818
+
+/*
+ * There are two different streams engines used in the S3 line.
+ * The old engine is in the Trio64, Virge,
+ * Savage3D, Savage4, SavagePro, and SavageTwister.
+ * The new engine is in the Savage2000, SavageMX,
+ * SavageIX, and SuperSavage.
+ */
+
+/* Old engine registers */
+#define PSTREAM_CONTROL_REG 0x8180
+#define COL_CHROMA_KEY_CONTROL_REG 0x8184
+#define SSTREAM_CONTROL_REG 0x8190
+#define CHROMA_KEY_UPPER_BOUND_REG 0x8194
+#define SSTREAM_STRETCH_REG 0x8198
+#define COLOR_ADJUSTMENT_REG 0x819C
+#define BLEND_CONTROL_REG 0x81A0
+#define PSTREAM_FBADDR0_REG 0x81C0
+#define PSTREAM_FBADDR1_REG 0x81C4
+#define PSTREAM_STRIDE_REG 0x81C8
+#define DOUBLE_BUFFER_REG 0x81CC
+#define SSTREAM_FBADDR0_REG 0x81D0
+#define SSTREAM_FBADDR1_REG 0x81D4
+#define SSTREAM_STRIDE_REG 0x81D8
+#define OPAQUE_OVERLAY_CONTROL_REG 0x81DC
+#define K1_VSCALE_REG 0x81E0
+#define SSTREAM_VSCALE_REG 0x81E0
+#define K2_VSCALE_REG 0x81E4
+#define SSTREAM_VINITIAL_REG 0x81E4
+#define DDA_VERT_REG 0x81E8
+#define SSTREAM_LINES_REG 0x81E8
+#define STREAMS_FIFO_REG 0x81EC
+#define PSTREAM_WINDOW_START_REG 0x81F0
+#define PSTREAM_WINDOW_SIZE_REG 0x81F4
+#define SSTREAM_WINDOW_START_REG 0x81F8
+#define SSTREAM_WINDOW_SIZE_REG 0x81FC
+#define FIFO_CONTROL 0x8200
+#define PSTREAM_FBSIZE_REG 0x8300
+#define SSTREAM_FBSIZE_REG 0x8304
+#define SSTREAM_FBADDR2_REG 0x8308
+
+/* New engine registers */
+#define PRI_STREAM_FBUF_ADDR0 0x81c0
+#define PRI_STREAM_FBUF_ADDR1 0x81c4
+#define PRI_STREAM_STRIDE 0x81c8
+#define PRI_STREAM_BUFFERSIZE 0x8214
+#define SEC_STREAM_CKEY_LOW 0x8184
+#define SEC_STREAM_CKEY_UPPER 0x8194
+#define BLEND_CONTROL 0x8190
+#define SEC_STREAM_COLOR_CONVERT1 0x8198
+#define SEC_STREAM_COLOR_CONVERT2 0x819c
+#define SEC_STREAM_COLOR_CONVERT3 0x81e4
+#define SEC_STREAM_HSCALING 0x81a0
+#define SEC_STREAM_BUFFERSIZE 0x81a8
+#define SEC_STREAM_HSCALE_NORMALIZE 0x81ac
+#define SEC_STREAM_VSCALING 0x81e8
+#define SEC_STREAM_FBUF_ADDR0 0x81d0
+#define SEC_STREAM_FBUF_ADDR1 0x81d4
+#define SEC_STREAM_FBUF_ADDR2 0x81ec
+#define SEC_STREAM_STRIDE 0x81d8
+#define SEC_STREAM_WINDOW_START 0x81f8
+#define SEC_STREAM_WINDOW_SZ 0x81fc
+#define SEC_STREAM_TILE_OFF 0x821c
+#define SEC_STREAM_OPAQUE_OVERLAY 0x81dc
+
+/* Savage 2000 registers */
+#define SEC_STREAM_COLOR_CONVERT0_2000 0x8198
+#define SEC_STREAM_COLOR_CONVERT1_2000 0x819c
+#define SEC_STREAM_COLOR_CONVERT2_2000 0x81e0
+#define SEC_STREAM_COLOR_CONVERT3_2000 0x81e4
+
+/* Virge+ registers */
+#define FIFO_CONTROL_REG 0x8200
+#define MIU_CONTROL_REG 0x8204
+#define STREAMS_TIMEOUT_REG 0x8208
+#define MISC_TIMEOUT_REG 0x820c
+
+/* VGA stuff */
+#define vgaCRIndex 0x3d4
+#define vgaCRReg 0x3d5
+
+/* CRT Control registers */
+#define EXT_MEM_CTRL1 0x53
+#define LIN_ADDR_CTRL 0x58
+#define EXT_MISC_CTRL2 0x67
+
+/* Old engine constants */
+#define ENABLE_NEWMMIO 0x08
+#define ENABLE_LFB 0x10
+#define ENABLE_STREAMS_OLD 0x0c
+#define NO_STREAMS_OLD 0xf3
+
+/* New engine constants */
+#define ENABLE_STREAM1 0x04
+#define NO_STREAMS 0xF9
+
+#define VerticalRetraceWait() \
+do { \
+ VGAIN8(0x3d4); \
+ VGAOUT8(0x3d4, 0x17); \
+ if (VGAIN8(0x3d5) & 0x80) { \
+ int i = 0x10000; \
+ while ((VGAIN8(0x3da) & 0x08) == 0x08 && i--) ; \
+ i = 0x10000; \
+ while ((VGAIN8(0x3da) & 0x08) == 0x00 && i--) ; \
+ } \
+} while (0)
+
+/* Scaling operations */
+#define HSCALING_Shift 0
+#define HSCALING_Mask (((1L << 16)-1) << HSCALING_Shift)
+#define HSCALING(w0,w1) ((((unsigned int)(((double)w0/(double)w1) * (1 << 15))) << HSCALING_Shift) & HSCALING_Mask)
+
+#define VSCALING_Shift 0
+#define VSCALING_Mask (((1L << 20)-1) << VSCALING_Shift)
+#define VSCALING(h0,h1) ((((unsigned int) (((double)h0/(double)h1) * (1 << 15))) << VSCALING_Shift) & VSCALING_Mask)
+
+/* Scaling factors */
+#define HDM_SHIFT 16
+#define HDSCALE_4 (2 << HDM_SHIFT)
+#define HDSCALE_8 (3 << HDM_SHIFT)
+#define HDSCALE_16 (4 << HDM_SHIFT)
+#define HDSCALE_32 (5 << HDM_SHIFT)
+#define HDSCALE_64 (6 << HDM_SHIFT)
+
+/* Window parameters */
+#define OS_XY(x,y) (((x+1)<<16)|(y+1))
+#define OS_WH(x,y) (((x-1)<<16)|(y))
+
+/* PCI stuff */
+
+/* PCI-Memory IO access macros. */
+#define VID_WR08(p,i,val) (((uint8_t *)(p))[(i)]=(val))
+#define VID_RD08(p,i) (((uint8_t *)(p))[(i)])
+
+#define VID_WR32(p,i,val) (((uint32_t *)(p))[(i)/4]=(val))
+#define VID_RD32(p,i) (((uint32_t *)(p))[(i)/4])
+
+#ifndef USE_RMW_CYCLES
+
+/* Can be used to inhibit READ-MODIFY-WRITE cycles. On by default. */
+#define MEM_BARRIER() __asm__ __volatile__ ("" : : : "memory")
+
+#undef VID_WR08
+#define VID_WR08(p,i,val) ({ MEM_BARRIER(); ((uint8_t *)(p))[(i)]=(val); })
+#undef VID_RD08
+#define VID_RD08(p,i) ({ MEM_BARRIER(); ((uint8_t *)(p))[(i)]; })
+
+#undef VID_WR16
+#define VID_WR16(p,i,val) ({ MEM_BARRIER(); ((uint16_t *)(p))[(i)/2]=(val); })
+#undef VID_RD16
+#define VID_RD16(p,i) ({ MEM_BARRIER(); ((uint16_t *)(p))[(i)/2]; })
+
+#undef VID_WR32
+#define VID_WR32(p,i,val) ({ MEM_BARRIER(); ((uint32_t *)(p))[(i)/4]=(val); })
+#undef VID_RD32
+#define VID_RD32(p,i) ({ MEM_BARRIER(); ((uint32_t *)(p))[(i)/4]; })
+#endif /* USE_RMW_CYCLES */
+
+#define VID_AND32(p,i,val) VID_WR32(p,i,VID_RD32(p,i)&(val))
+#define VID_OR32(p,i,val) VID_WR32(p,i,VID_RD32(p,i)|(val))
+#define VID_XOR32(p,i,val) VID_WR32(p,i,VID_RD32(p,i)^(val))
+
+#define VGAIN8(addr) VID_RD08(info->control_base+0x8000, addr)
+#define VGAIN16(addr) VID_RD16(info->control_base+0x8000, addr)
+#define VGAIN(addr) VID_RD32(info->control_base+0x8000, addr)
+
+#define VGAOUT8(addr,val) VID_WR08(info->control_base+0x8000, addr, val)
+#define VGAOUT16(addr,val) VID_WR16(info->control_base+0x8000, addr, val)
+#define VGAOUT(addr,val) VID_WR32(info->control_base+0x8000, addr, val)
+
+#define INREG(addr) VID_RD32(info->control_base, addr)
+#define OUTREG(addr,val) VID_WR32(info->control_base, addr, val)
+#define INREG8(addr) VID_RD08(info->control_base, addr)
+#define OUTREG8(addr,val) VID_WR08(info->control_base, addr, val)
+#define INREG16(addr) VID_RD16(info->control_base, addr)
+#define OUTREG16(addr,val) VID_WR16(info->control_base, addr, val)
+
+#define ALIGN_TO(v, n) (((v) + (n-1)) & ~(n-1))
+
+#endif /* _S3_REGS_H */
Added: trunk/vidix/s3_vid.c
==============================================================================
--- (empty file)
+++ trunk/vidix/s3_vid.c Fri Feb 29 21:01:28 2008
@@ -0,0 +1,929 @@
+/*
+ * VIDIX driver for S3 chipsets.
+ * Copyright (C) 2004 Reza Jelveh
+ *
+ * This file is part of MPlayer.
+ *
+ * MPlayer is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MPlayer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MPlayer; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Thanks to Alex Deucher for Support
+ *
+ * Trio/Virge support by Michael Kostylev
+ *
+ */
+
+#include <errno.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <inttypes.h>
+#include <unistd.h>
+#include <math.h>
+
+#include "vidix.h"
+#include "vidixlib.h"
+#include "fourcc.h"
+#include "dha.h"
+#include "pci_ids.h"
+#include "pci_names.h"
+#include "config.h"
+
+#include "s3_regs.h"
+
+static void S3SetColorKeyOld (void);
+static void S3SetColorKeyNew (void);
+static void S3SetColorKey2000 (void);
+static void (*S3SetColorKey) (void) = NULL;
+
+static void S3SetColorOld (void);
+static void S3SetColorNew (void);
+static void S3SetColor2000 (void);
+static void (*S3SetColor) (void) = NULL;
+
+static void S3DisplayVideoOld (void);
+static void S3DisplayVideoNew (void);
+static void S3DisplayVideo2000 (void);
+static void (*S3DisplayVideo) (void) = NULL;
+
+static void S3InitStreamsOld (void);
+static void S3InitStreamsNew (void);
+static void S3InitStreams2000 (void);
+static void (*S3InitStreams) (void) = NULL;
+
+pciinfo_t pci_info;
+
+struct s3_chip
+{
+ int arch;
+ unsigned long fbsize;
+ void (*lock) (struct s3_chip *, int);
+};
+typedef struct s3_chip s3_chip;
+
+struct s3_info
+{
+ vidix_video_eq_t eq;
+ unsigned int use_colorkey;
+ unsigned int colorkey;
+ unsigned int vidixcolorkey;
+ unsigned int depth;
+ unsigned int bpp;
+ unsigned int format;
+ unsigned int pitch;
+ unsigned int blendBase;
+ unsigned int displayWidth, displayHeight;
+ unsigned int src_w, src_h;
+ unsigned int drw_w, drw_h;
+ unsigned int wx, wy;
+ unsigned int screen_x;
+ unsigned int screen_y;
+ unsigned long frame_size;
+ struct s3_chip chip;
+ void *video_base;
+ void *control_base;
+ unsigned long picture_base;
+ unsigned long picture_offset;
+ unsigned int num_frames;
+ int bps;
+};
+typedef struct s3_info s3_info;
+
+static s3_info *info;
+
+static vidix_capability_t s3_cap = {
+ "S3 BES",
+ "Reza Jelveh, Michael Kostylev",
+ TYPE_OUTPUT,
+ {0, 0, 0, 0},
+ 4096,
+ 4096,
+ 4,
+ 4,
+ -1,
+ FLAG_UPSCALER | FLAG_DOWNSCALER,
+ VENDOR_S3_INC,
+ -1,
+ {0, 0, 0, 0}
+};
+
+struct s3_cards
+{
+ unsigned short chip_id;
+ unsigned short arch;
+};
+
+static struct s3_cards s3_card_ids[] = {
+ /* Trio64V */
+ {DEVICE_S3_INC_86C764_765_TRIO32_64_64V, S3_TRIO64V},
+ {DEVICE_S3_INC_86C767_TRIO_64UV, S3_TRIO64V},
+ {DEVICE_S3_INC_86C755_TRIO_64V2_DX, S3_TRIO64V},
+ {DEVICE_S3_INC_86C775_86C785_TRIO_64V2_DX, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY2, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY3, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY4, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY5, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY6, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY7, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY8, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY9, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY10, S3_TRIO64V},
+ {DEVICE_S3_INC_TRIO_64V_FAMILY11, S3_TRIO64V},
+ /* Virge */
+ {DEVICE_S3_INC_86C325_VIRGE, S3_VIRGE},
+ {DEVICE_S3_INC_86C988_VIRGE_VX, S3_VIRGE},
+ {DEVICE_S3_INC_VIRGE_DX_OR_GX, S3_VIRGE},
+ {DEVICE_S3_INC_VIRGE_GX2, S3_VIRGE},
+ {DEVICE_S3_INC_VIRGE_M3, S3_VIRGE},
+ {DEVICE_S3_INC_VIRGE_MX, S3_VIRGE},
+ {DEVICE_S3_INC_VIRGE_MX2, S3_VIRGE},
+ {DEVICE_S3_INC_VIRGE_MX_MV, S3_VIRGE},
+ /* Savage3D */
+ {DEVICE_S3_INC_86C794_SAVAGE_3D, S3_SAVAGE3D},
+ {DEVICE_S3_INC_86C390_SAVAGE_3D_MV, S3_SAVAGE3D},
+ /* Savage4 */
+ {DEVICE_S3_INC_SAVAGE_4, S3_SAVAGE4},
+ {DEVICE_S3_INC_SAVAGE_42, S3_SAVAGE4},
+ /* SavageMX */
+ {DEVICE_S3_INC_86C270_294_SAVAGE_MX_MV, S3_SAVAGE_MX},
+ {DEVICE_S3_INC_82C270_294_SAVAGE_MX, S3_SAVAGE_MX},
+ {DEVICE_S3_INC_86C270_294_SAVAGE_IX_MV, S3_SAVAGE_MX},
+ /* SuperSavage */
+ {DEVICE_S3_INC_SUPERSAVAGE_MX_128, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_MX_64, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_MX_64C, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_IX_128_SDR, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_IX_128_DDR, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_IX_64_SDR, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_IX_64_DDR, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_IX_C_SDR, S3_SUPERSAVAGE},
+ {DEVICE_S3_INC_SUPERSAVAGE_IX_C_DDR, S3_SUPERSAVAGE},
+ /* ProSavage */
+ {DEVICE_S3_INC_PROSAVAGE_PM133, S3_PROSAVAGE},
+ {DEVICE_S3_INC_PROSAVAGE_KM133, S3_PROSAVAGE},
+ {DEVICE_S3_INC_86C380_PROSAVAGEDDR_K4M266, S3_PROSAVAGE},
+ {DEVICE_S3_INC_VT8636A_PROSAVAGE_KN133, S3_PROSAVAGE},
+ {DEVICE_S3_INC_VT8751_PROSAVAGEDDR_P4M266, S3_PROSAVAGE},
+ {DEVICE_S3_INC_VT8375_PROSAVAGE8_KM266_KL266, S3_PROSAVAGE},
+ /* Savage2000 */
+ {DEVICE_S3_INC_86C410_SAVAGE_2000, S3_SAVAGE2000}
+};
+
+static unsigned int GetBlendForFourCC (int id)
+{
+ switch (id)
+ {
+ case IMGFMT_UYVY:
+ return 0;
+ case IMGFMT_YUY2:
+ return 1;
+ case IMGFMT_Y211:
+ return 4;
+ case IMGFMT_BGR15:
+ return 3;
+ case IMGFMT_BGR16:
+ return 5;
+ case IMGFMT_BGR24:
+ return 6;
+ case IMGFMT_BGR32:
+ return 7;
+ default:
+ return 1;
+ }
+}
+
+static void S3SetColorOld (void)
+{
+ char sat = (info->eq.saturation + 1000) * 15 / 2000;
+ double hue = info->eq.hue * 3.1415926 / 1000.0;
+ char hsx = ((char) (sat * cos (hue))) & 0x1f;
+ char hsy = ((char) (sat * sin (hue))) & 0x1f;
+
+ OUTREG (COLOR_ADJUSTMENT_REG, 0x80008000 | hsy << 24 | hsx << 16 |
+ ((info->eq.contrast + 1000) * 31 / 2000) << 8 |
+ (info->eq.brightness + 1000) * 255 / 2000);
+}
+
+static void S3SetColorNew (void)
+{
+ /* not yet */
+}
+
+static void S3SetColor2000 (void)
+{
+ /* not yet */
+}
+
+static void S3SetColorKeyOld (void)
+{
+ int red, green, blue;
+
+ /* Here, we reset the colorkey and all the controls */
+
+ red = (info->vidixcolorkey & 0x00FF0000) >> 16;
+ green = (info->vidixcolorkey & 0x0000FF00) >> 8;
+ blue = info->vidixcolorkey & 0x000000FF;
+
+ if (!info->vidixcolorkey)
+ {
+ OUTREG (COL_CHROMA_KEY_CONTROL_REG, 0);
+ OUTREG (CHROMA_KEY_UPPER_BOUND_REG, 0);
+ OUTREG (BLEND_CONTROL_REG, 0);
+ }
+ else
+ {
+ switch (info->depth)
+ {
+ // FIXME: isnt fixed yet
+ case 8:
+ OUTREG (COL_CHROMA_KEY_CONTROL_REG, 0x37000000 | (info->vidixcolorkey & 0xFF));
+ OUTREG (CHROMA_KEY_UPPER_BOUND_REG, 0x00000000 | (info->vidixcolorkey & 0xFF));
+ break;
+ case 15:
+ /* 15 bpp 555 */
+ red &= 0x1f;
+ green &= 0x1f;
+ blue &= 0x1f;
+ OUTREG (COL_CHROMA_KEY_CONTROL_REG, 0x05000000 | (red << 19) | (green << 11) | (blue << 3));
+ OUTREG (CHROMA_KEY_UPPER_BOUND_REG, 0x00000000 | (red << 19) | (green << 11) | (blue << 3));
+ break;
+ case 16:
+ /* 16 bpp 565 */
+ red &= 0x1f;
+ green &= 0x3f;
+ blue &= 0x1f;
+ OUTREG (COL_CHROMA_KEY_CONTROL_REG, 0x16000000 | (red << 19) | (green << 10) | (blue << 3));
+ OUTREG (CHROMA_KEY_UPPER_BOUND_REG, 0x00020002 | (red << 19) | (green << 10) | (blue << 3));
+ break;
+ case 24:
+ /* 24 bpp 888 */
+ OUTREG (COL_CHROMA_KEY_CONTROL_REG, 0x17000000 | (red << 16) | (green << 8) | (blue));
+ OUTREG (CHROMA_KEY_UPPER_BOUND_REG, 0x00000000 | (red << 16) | (green << 8) | (blue));
+ break;
+ }
+
+ /* We use destination colorkey */
+ OUTREG (BLEND_CONTROL_REG, 0x05000000);
+ }
+}
+
+static void S3SetColorKeyNew (void)
+{
+ /* not yet */
+}
+
+static void S3SetColorKey2000 (void)
+{
+ /* not yet */
+}
+
+static void S3DisplayVideoOld (void)
+{
+ unsigned int ssControl;
+ int cr92;
+
+ /* Set surface location and stride */
+ OUTREG (SSTREAM_FBADDR0_REG, info->picture_offset);
+ OUTREG (SSTREAM_FBADDR1_REG, 0);
+ OUTREG (SSTREAM_STRIDE_REG, info->pitch);
+ /* Set window parameters */
+ OUTREG (SSTREAM_WINDOW_START_REG, OS_XY (info->wx, info->wy));
+ OUTREG (SSTREAM_WINDOW_SIZE_REG, OS_WH (info->drw_w, info->drw_h));
+
+ /* Set surface format and adjust scaling */
+ if (info->chip.arch <= S3_VIRGE)
+ {
+ ssControl = ((info->src_w - 1) << 1) - ((info->drw_w - 1) & 0xffff);
+ ssControl |= GetBlendForFourCC (info->format) << 24;
+ if (info->src_w != info->drw_w)
+ ssControl |= 2 << 28;
+
+ OUTREG (SSTREAM_CONTROL_REG, ssControl);
+ OUTREG (SSTREAM_STRETCH_REG, (((info->src_w - info->drw_w) & 0x7ff) << 16) | (info->src_w - 1));
+ /* Calculate vertical scale factor */
+ OUTREG (K1_VSCALE_REG, info->src_h - 1);
+ OUTREG (K2_VSCALE_REG, (info->src_h - info->drw_h) & 0x7ff);
+ OUTREG (DDA_VERT_REG, (1 - info->drw_h) & 0xfff);
+ }
+ else
+ {
+ ssControl = GetBlendForFourCC (info->format) << 24 | info->src_w;
+ if (info->src_w > (info->drw_w << 1))
+ {
+ /* BUGBUG shouldn't this be >=? */
+ if (info->src_w <= (info->drw_w << 2))
+ ssControl |= HDSCALE_4;
+ else if (info->src_w > (info->drw_w << 3))
+ ssControl |= HDSCALE_8;
+ else if (info->src_w > (info->drw_w << 4))
+ ssControl |= HDSCALE_16;
+ else if (info->src_w > (info->drw_w << 5))
+ ssControl |= HDSCALE_32;
+ else if (info->src_w > (info->drw_w << 6))
+ ssControl |= HDSCALE_64;
+ }
+
+ OUTREG (SSTREAM_CONTROL_REG, ssControl);
+ OUTREG (SSTREAM_STRETCH_REG, (info->src_w << 15) / info->drw_w);
+ OUTREG (SSTREAM_LINES_REG, info->src_h);
+ /* Calculate vertical scale factor. */
+ OUTREG (SSTREAM_VSCALE_REG, VSCALING (info->src_h, info->drw_h));
+ }
+
+ if (info->chip.arch == S3_TRIO64V)
+ OUTREG (STREAMS_FIFO_REG, (6 << 10) | (14 << 5) | 16);
+ else
+ {
+ // FIXME: this should actually be enabled
+ info->pitch = (info->pitch + 7) / 8;
+ VGAOUT8 (vgaCRIndex, 0x92);
+ cr92 = VGAIN8 (vgaCRReg);
+ VGAOUT8 (vgaCRReg, (cr92 & 0x40) | (info->pitch >> 8) | 0x80);
+ VGAOUT8 (vgaCRIndex, 0x93);
+ VGAOUT8 (vgaCRReg, info->pitch);
+ OUTREG (STREAMS_FIFO_REG, 2 | 25 << 5 | 32 << 11);
+ }
+}
+
+static void S3DisplayVideoNew (void)
+{
+ /* not yet */
+}
+
+static void S3DisplayVideo2000 (void)
+{
+ /* not yet */
+}
+
+static void S3InitStreamsOld (void)
+{
+ /*unsigned long jDelta; */
+ unsigned long format = 0;
+
+ /*jDelta = pScrn->displayWidth * (pScrn->bitsPerPixel + 7) / 8; */
+ switch (info->depth)
+ {
+ case 8:
+ format = 0 << 24;
+ break;
+ case 15:
+ format = 3 << 24;
+ break;
+ case 16:
+ format = 5 << 24;
+ break;
+ case 24:
+ format = 7 << 24;
+ break;
+ }
+//#warning enable this again
+ OUTREG (PSTREAM_FBSIZE_REG, info->screen_y * info->screen_x * (info->bpp >> 3));
+ OUTREG (PSTREAM_WINDOW_START_REG, OS_XY (0, 0));
+ OUTREG (PSTREAM_WINDOW_SIZE_REG, OS_WH (info->screen_x, info->screen_y));
+ OUTREG (PSTREAM_FBADDR1_REG, 0);
+ /*OUTREG( PSTREAM_STRIDE_REG, jDelta ); */
+ OUTREG (PSTREAM_CONTROL_REG, format);
+ OUTREG (PSTREAM_FBADDR0_REG, 0);
+
+ OUTREG (COL_CHROMA_KEY_CONTROL_REG, 0);
+ OUTREG (SSTREAM_CONTROL_REG, 0);
+ OUTREG (CHROMA_KEY_UPPER_BOUND_REG, 0);
+ OUTREG (SSTREAM_STRETCH_REG, 0);
+ OUTREG (COLOR_ADJUSTMENT_REG, 0);
+ OUTREG (BLEND_CONTROL_REG, 1 << 24);
+ OUTREG (DOUBLE_BUFFER_REG, 0);
+ OUTREG (SSTREAM_FBADDR0_REG, 0);
+ OUTREG (SSTREAM_FBADDR1_REG, 0);
+ OUTREG (SSTREAM_FBADDR2_REG, 0);
+ OUTREG (SSTREAM_FBSIZE_REG, 0);
+ OUTREG (SSTREAM_STRIDE_REG, 0);
+ OUTREG (SSTREAM_VSCALE_REG, 0);
+ OUTREG (SSTREAM_LINES_REG, 0);
+ OUTREG (SSTREAM_VINITIAL_REG, 0);
+}
+
+static void S3InitStreamsNew (void)
+{
+ /* not yet */
+}
+
+static void S3InitStreams2000 (void)
+{
+ /* not yet */
+}
+
+static void S3StreamsOn (void)
+{
+ unsigned char jStreamsControl;
+
+ VGAOUT8 (vgaCRIndex, EXT_MISC_CTRL2);
+
+ if (S3_SAVAGE_MOBILE_SERIES (info->chip.arch))
+ {
+ jStreamsControl = VGAIN8 (vgaCRReg) | ENABLE_STREAM1;
+ VerticalRetraceWait ();
+ VGAOUT16 (vgaCRIndex, (jStreamsControl << 8) | EXT_MISC_CTRL2);
+
+ S3InitStreams = S3InitStreamsNew;
+ S3SetColor = S3SetColorNew;
+ S3SetColorKey = S3SetColorKeyNew;
+ S3DisplayVideo = S3DisplayVideoNew;
+ }
+ else if (info->chip.arch == S3_SAVAGE2000)
+ {
+ jStreamsControl = VGAIN8 (vgaCRReg) | ENABLE_STREAM1;
+ VerticalRetraceWait ();
+ VGAOUT16 (vgaCRIndex, (jStreamsControl << 8) | EXT_MISC_CTRL2);
+
+ S3InitStreams = S3InitStreams2000;
+ S3SetColor = S3SetColor2000;
+ S3SetColorKey = S3SetColorKey2000;
+ S3DisplayVideo = S3DisplayVideo2000;
+ }
+ else
+ {
+ jStreamsControl = VGAIN8 (vgaCRReg) | ENABLE_STREAMS_OLD;
+ VerticalRetraceWait ();
+ VGAOUT16 (vgaCRIndex, (jStreamsControl << 8) | EXT_MISC_CTRL2);
+
+ S3InitStreams = S3InitStreamsOld;
+ S3SetColor = S3SetColorOld;
+ S3SetColorKey = S3SetColorKeyOld;
+ S3DisplayVideo = S3DisplayVideoOld;
+ }
+
+ S3InitStreams ();
+
+ VerticalRetraceWait ();
+ /* Turn on secondary stream TV flicker filter, once we support TV. */
+ /* SR70 |= 0x10 */
+}
+
+static void S3GetScrProp (struct s3_info *info)
+{
+ unsigned char bpp = 0;
+
+ VGAOUT8 (vgaCRIndex, EXT_MISC_CTRL2);
+ bpp = VGAIN8 (vgaCRReg);
+
+ switch (bpp & 0xf0)
+ {
+ case 0x00:
+ case 0x10:
+ info->depth = 8;
+ info->bpp = 8;
+ break;
+ case 0x20:
+ case 0x30:
+ info->depth = 15;
+ info->bpp = 16;
+ break;
+ case 0x40:
+ case 0x50:
+ info->depth = 16;
+ info->bpp = 16;
+ break;
+ case 0x70:
+ case 0xd0:
+ info->depth = 24;
+ info->bpp = 32;
+ break;
+ }
+
+ VGAOUT8 (vgaCRIndex, 0x1);
+ info->screen_x = (1 + VGAIN8 (vgaCRReg)) << 3;
+ VGAOUT8 (vgaCRIndex, 0x12);
+ info->screen_y = VGAIN8 (vgaCRReg);
+ VGAOUT8 (vgaCRIndex, 0x07);
+ info->screen_y |= (VGAIN8 (vgaCRReg) & 0x02) << 7;
+ info->screen_y |= (VGAIN8 (vgaCRReg) & 0x40) << 3;
+ ++info->screen_y;
+
+ printf ("[s3_vid] x = %d, y = %d, bpp = %d\n", info->screen_x, info->screen_y, info->bpp);
+}
+
+static void S3StreamsOff (void)
+{
+ unsigned char jStreamsControl;
+
+ if (info->chip.arch == S3_TRIO64V)
+ OUTREG (STREAMS_FIFO_REG, (20 << 10));
+
+ VGAOUT8 (vgaCRIndex, EXT_MISC_CTRL2);
+ if (S3_SAVAGE_MOBILE_SERIES (info->chip.arch) ||
+ (info->chip.arch == S3_SUPERSAVAGE) || (info->chip.arch == S3_SAVAGE2000))
+ jStreamsControl = VGAIN8 (vgaCRReg) & NO_STREAMS;
+ else
+ jStreamsControl = VGAIN8 (vgaCRReg) & NO_STREAMS_OLD;
+
+ VerticalRetraceWait ();
+ VGAOUT16 (vgaCRIndex, (jStreamsControl << 8) | EXT_MISC_CTRL2);
+
+ if (S3_SAVAGE_SERIES (info->chip.arch))
+ {
+ VGAOUT16 (vgaCRIndex, 0x0093);
+ VGAOUT8 (vgaCRIndex, 0x92);
+ VGAOUT8 (vgaCRReg, VGAIN8 (vgaCRReg) & 0x40);
+ }
+}
+
+static int find_chip (unsigned chip_id)
+{
+ unsigned i;
+
+ for (i = 0; i < sizeof (s3_card_ids) / sizeof (struct s3_cards); i++)
+ if (chip_id == s3_card_ids[i].chip_id)
+ return i;
+ return -1;
+}
+
+static int s3_probe (int verbose, int force)
+{
+ pciinfo_t lst[MAX_PCI_DEVICES];
+ unsigned i, num_pci;
+ int err;
+
+ if (force)
+ printf ("[s3_vid] Warning: forcing not supported yet!\n");
+ err = pci_scan (lst, &num_pci);
+ if (err)
+ {
+ printf ("[s3_vid] Error occurred during pci scan: %s\n", strerror (err));
+ return err;
+ }
+ else
+ {
+ err = ENXIO;
+ for (i = 0; i < num_pci; i++)
+ {
+ if (lst[i].vendor == VENDOR_S3_INC)
+ {
+ int idx;
+ const char *dname;
+ idx = find_chip (lst[i].device);
+ if (idx == -1)
+ continue;
+ dname = pci_device_name (lst[i].vendor, lst[i].device);
+ dname = dname ? dname : "Unknown chip";
+ printf ("[s3_vid] Found chip: %s\n", dname);
+ // FIXME: whats wrong here?
+ if ((lst[i].command & PCI_COMMAND_IO) == 0)
+ {
+ printf ("[s3_vid] Device is disabled, ignoring\n");
+ continue;
+ }
+ s3_cap.device_id = lst[i].device;
+ err = 0;
+ memcpy (&pci_info, &lst[i], sizeof (pciinfo_t));
+ break;
+ }
+ }
+ }
+ if (err && verbose)
+ printf ("[s3_vid] Can't find chip\n");
+ return err;
+}
+
+static int s3_init (const char *args __attribute__ ((unused)))
+{
+ unsigned char cr36;
+ int mtrr, videoRam;
+ static unsigned char RamTrioVirge[] = { 4, 0, 3, 8, 2, 6, 1, 0 };
+ static unsigned char RamSavage3D[] = { 8, 4, 4, 2 };
+ static unsigned char RamSavage4[] = { 2, 4, 8, 12, 16, 32, 64, 32 };
+ static unsigned char RamSavageMX[] = { 2, 8, 4, 16, 8, 16, 4, 16 };
+ static unsigned char RamSavageNB[] = { 0, 2, 4, 8, 16, 32, 16, 2 };
+
+ enable_app_io ();
+
+ info = calloc (1, sizeof (s3_info));
+
+ info->chip.arch = s3_card_ids[find_chip (pci_info.device)].arch;
+
+ /* Switch to vga registers */
+ OUTPORT8 (0x3c3, INPORT8 (0x3c3) | 0x01);
+ OUTPORT8 (0x3c2, INPORT8 (0x3cc) | 0x01);
+ /* Unlock extended registers */
+ OUTPORT8 (vgaCRIndex, 0x38);
+ OUTPORT8 (vgaCRReg, 0x48);
+ OUTPORT8 (vgaCRIndex, 0x39);
+ OUTPORT8 (vgaCRReg, 0xa0);
+
+ if (info->chip.arch <= S3_VIRGE)
+ {
+ /* TODO: Improve detecting code */
+
+ /* Enable LFB */
+ OUTPORT8 (vgaCRIndex, LIN_ADDR_CTRL);
+ OUTPORT8 (vgaCRReg, INPORT8 (vgaCRReg) | ENABLE_LFB);
+ /* Enable NewMMIO */
+ OUTPORT8 (vgaCRIndex, EXT_MEM_CTRL1);
+ OUTPORT8 (vgaCRReg, INPORT8 (vgaCRReg) | ENABLE_NEWMMIO);
+ }
+
+ if (info->chip.arch < S3_SAVAGE3D)
+ info->control_base = map_phys_mem (pci_info.base0 + S3_NEWMMIO_REGBASE, S3_NEWMMIO_REGSIZE);
+ else if (info->chip.arch == S3_SAVAGE3D)
+ info->control_base = map_phys_mem (pci_info.base0 + S3_NEWMMIO_REGBASE, S3_NEWMMIO_REGSIZE_SAVAGE);
+ else
+ info->control_base = map_phys_mem (pci_info.base0, S3_NEWMMIO_REGSIZE_SAVAGE);
+
+ /* Unlock CRTC[0-7] */
+ VGAOUT8 (vgaCRIndex, 0x11);
+ VGAOUT8 (vgaCRReg, VGAIN8 (vgaCRReg) & 0x7f);
+ /* Unlock sequencer */
+ VGAOUT16 (0x3c4, 0x0608);
+ /* Detect amount of installed ram */
+ VGAOUT8 (vgaCRIndex, 0x36);
+ cr36 = VGAIN8 (vgaCRReg);
+
+ switch (info->chip.arch)
+ {
+ case S3_TRIO64V:
+ case S3_VIRGE:
+ videoRam = RamTrioVirge[(cr36 & 0xE0) >> 5] * 1024;
+ break;
+
+ case S3_SAVAGE3D:
+ videoRam = RamSavage3D[(cr36 & 0xC0) >> 6] * 1024;
+ break;
+
+ case S3_SAVAGE4:
+ /*
+ * The Savage4 has one ugly special case to consider. On
+ * systems with 4 banks of 2Mx32 SDRAM, the BIOS says 4MB
+ * when it really means 8MB. Why do it the same when you
+ * can do it different...
+ */
+ VGAOUT8 (vgaCRIndex, 0x68);
+ if ((VGAIN8 (vgaCRReg) & 0xC0) == (0x01 << 6))
+ RamSavage4[1] = 8;
+
+ case S3_SAVAGE2000:
+ videoRam = RamSavage4[(cr36 & 0xE0) >> 5] * 1024;
+ break;
+
+ case S3_SAVAGE_MX:
+ videoRam = RamSavageMX[(cr36 & 0x0E) >> 1] * 1024;
+ break;
+
+ case S3_PROSAVAGE:
+ videoRam = RamSavageNB[(cr36 & 0xE0) >> 5] * 1024;
+ break;
+
+ default:
+ /* How did we get here? */
+ videoRam = 0;
+ break;
+ }
+
+ printf ("[s3_vid] VideoRam = %d\n", videoRam);
+ info->chip.fbsize = videoRam * 1024;
+
+ if (info->chip.arch <= S3_SAVAGE3D)
+ mtrr = mtrr_set_type (pci_info.base0, info->chip.fbsize, MTRR_TYPE_WRCOMB);
+ else
+ mtrr = mtrr_set_type (pci_info.base1, info->chip.fbsize, MTRR_TYPE_WRCOMB);
+
+ if (mtrr != 0)
+ printf ("[s3_vid] Unable to setup MTRR: %s\n", strerror (mtrr));
+ else
+ printf ("[s3_vid] MTRR set up\n");
+
+ S3GetScrProp (info);
+ S3StreamsOn ();
+
+ return 0;
+}
+
+static void s3_destroy (void)
+{
+ unmap_phys_mem (info->video_base, info->chip.fbsize);
+ if (S3_SAVAGE_SERIES (info->chip.arch))
+ unmap_phys_mem (info->control_base, S3_NEWMMIO_REGSIZE_SAVAGE);
+ else
+ unmap_phys_mem (info->control_base, S3_NEWMMIO_REGSIZE);
+
+ free (info);
+}
+
+static int s3_get_caps (vidix_capability_t * to)
+{
+ memcpy (to, &s3_cap, sizeof (vidix_capability_t));
+ return 0;
+}
+
+static int is_supported_fourcc (uint32_t fourcc)
+{
+ switch (fourcc)
+ {
+//FIXME: Burst Command Interface should be used
+// for planar to packed conversion
+// case IMGFMT_YV12:
+// case IMGFMT_I420:
+ case IMGFMT_UYVY:
+ case IMGFMT_YUY2:
+ case IMGFMT_Y211:
+ case IMGFMT_BGR15:
+ case IMGFMT_BGR16:
+ case IMGFMT_BGR24:
+ case IMGFMT_BGR32:
+ return 1;
+ default:
+ return 0;
+ }
+}
+
+static int s3_query_fourcc (vidix_fourcc_t * to)
+{
+ if (is_supported_fourcc (to->fourcc))
+ {
+ to->depth = VID_DEPTH_ALL;
+ to->flags = VID_CAP_EXPAND | VID_CAP_SHRINK | VID_CAP_COLORKEY;
+ return 0;
+ }
+ else
+ to->depth = to->flags = 0;
+
+ return ENOSYS;
+}
+
+#if 0
+static int s3_get_gkeys (vidix_grkey_t * grkey)
+{
+ return 0;
+}
+#endif
+
+static int s3_set_gkeys (const vidix_grkey_t * grkey)
+{
+ if (grkey->ckey.op == CKEY_FALSE)
+ {
+ info->use_colorkey = 0;
+ info->vidixcolorkey = 0;
+ printf ("[s3_vid] Colorkeying disabled\n");
+ }
+ else
+ {
+ info->use_colorkey = 1;
+ info->vidixcolorkey = ((grkey->ckey.red << 16) | (grkey->ckey.green << 8) | grkey->ckey.blue);
+ printf ("[s3_vid] Set colorkey 0x%x\n", info->vidixcolorkey);
+ }
+ if (S3SetColorKey)
+ S3SetColorKey ();
+ return 0;
+}
+
+static int s3_get_eq (vidix_video_eq_t * eq)
+{
+ memcpy (eq, &(info->eq), sizeof (vidix_video_eq_t));
+ return 0;
+}
+
+static int s3_set_eq (const vidix_video_eq_t * eq)
+{
+ if (eq->cap & VEQ_CAP_BRIGHTNESS)
+ info->eq.brightness = eq->brightness;
+ if (eq->cap & VEQ_CAP_CONTRAST)
+ info->eq.contrast = eq->contrast;
+ if (eq->cap & VEQ_CAP_SATURATION)
+ info->eq.saturation = eq->saturation;
+ if (eq->cap & VEQ_CAP_HUE)
+ info->eq.hue = eq->hue;
+ if (S3SetColor)
+ S3SetColor ();
+ return 0;
+}
+
+static int s3_config_playback (vidix_playback_t * vinfo)
+{
+ unsigned int i, bpp;
+
+ if (!is_supported_fourcc (vinfo->fourcc))
+ return -1;
+
+ info->src_w = vinfo->src.w;
+ info->src_h = vinfo->src.h;
+
+ info->drw_w = vinfo->dest.w;
+ info->drw_h = vinfo->dest.h;
+
+ info->wx = vinfo->dest.x;
+ info->wy = vinfo->dest.y;
+ info->format = vinfo->fourcc;
+
+ info->eq.cap = VEQ_CAP_BRIGHTNESS | VEQ_CAP_CONTRAST |
+ VEQ_CAP_SATURATION | VEQ_CAP_HUE;
+ info->eq.brightness = 0;
+ info->eq.contrast = 0;
+ info->eq.saturation = 0;
+ info->eq.hue = 0;
+
+ vinfo->offset.y = 0;
+ vinfo->offset.v = 0;
+ vinfo->offset.u = 0;
+
+ vinfo->dest.pitch.y = 32;
+ vinfo->dest.pitch.u = 32;
+ vinfo->dest.pitch.v = 32;
+
+ switch (vinfo->fourcc)
+ {
+ case IMGFMT_Y211:
+ bpp = 1;
+ break;
+ case IMGFMT_BGR24:
+ bpp = 3;
+ break;
+ case IMGFMT_BGR32:
+ bpp = 4;
+ break;
+ default:
+ bpp = 2;
+ break;
+ }
+
+ info->pitch = ((info->src_w * bpp) + 15) & ~15;
+ info->pitch |= ((info->pitch / bpp) << 16);
+
+ vinfo->frame_size = (info->pitch & 0xffff) * info->src_h;
+ info->frame_size = vinfo->frame_size;
+
+ info->picture_offset = info->screen_x * info->screen_y * (info->bpp >> 3);
+ if (info->picture_offset > (info->chip.fbsize - vinfo->frame_size))
+ {
+ printf ("[s3_vid] Not enough memory for overlay\n");
+ return -1;
+ }
+
+ if (info->chip.arch <= S3_SAVAGE3D)
+ info->video_base = map_phys_mem (pci_info.base0, info->chip.fbsize);
+ else
+ info->video_base = map_phys_mem (pci_info.base1, info->chip.fbsize);
+
+ if (info->video_base == NULL)
+ {
+ printf ("[s3_vid] errno = %s\n", strerror (errno));
+ return -1;
+ }
+
+ info->picture_base = (uint32_t) info->video_base + info->picture_offset;
+
+ vinfo->dga_addr = (void *) (info->picture_base);
+
+ vinfo->num_frames = (info->chip.fbsize - info->picture_offset) / vinfo->frame_size;
+ if (vinfo->num_frames > VID_PLAY_MAXFRAMES)
+ vinfo->num_frames = VID_PLAY_MAXFRAMES;
+
+ for (i = 0; i < vinfo->num_frames; i++)
+ vinfo->offsets[i] = vinfo->frame_size * i;
+
+ return 0;
+}
+
+static int s3_playback_on (void)
+{
+ S3DisplayVideo ();
+ return 0;
+}
+
+static int s3_playback_off (void)
+{
+ S3StreamsOff ();
+ return 0;
+}
+
+static int s3_frame_sel (unsigned int frame)
+{
+ OUTREG (SSTREAM_FBADDR0_REG, info->picture_offset + (info->frame_size * frame));
+ return 0;
+}
+
+VDXDriver s3_drv = {
+ "s3",
+ NULL,
+ .probe = s3_probe,
+ .get_caps = s3_get_caps,
+ .query_fourcc = s3_query_fourcc,
+ .init = s3_init,
+ .destroy = s3_destroy,
+ .config_playback = s3_config_playback,
+ .playback_on = s3_playback_on,
+ .playback_off = s3_playback_off,
+ .frame_sel = s3_frame_sel,
+ .get_eq = s3_get_eq,
+ .set_eq = s3_set_eq,
+ .set_gkey = s3_set_gkeys,
+};
4
5
r25987 - in trunk: libmpdemux/demux_mkv.c mencoder.c mplayer.c stream/stream_dvd.c stream/stream_dvdnav.c
by nicodvb 01 Mar '08
by nicodvb 01 Mar '08
01 Mar '08
Author: nicodvb
Date: Mon Feb 11 23:03:34 2008
New Revision: 25987
Log:
-chapter is now handled uniformly calling demuxer_seek_chapter() instead
of letting individual demuxers and stream readers do their nasty job
Modified:
trunk/libmpdemux/demux_mkv.c
trunk/mencoder.c
trunk/mplayer.c
trunk/stream/stream_dvd.c
trunk/stream/stream_dvdnav.c
Modified: trunk/libmpdemux/demux_mkv.c
==============================================================================
--- trunk/libmpdemux/demux_mkv.c (original)
+++ trunk/libmpdemux/demux_mkv.c Mon Feb 11 23:03:34 2008
@@ -2526,17 +2526,6 @@ demux_mkv_open (demuxer_t *demuxer)
demuxer->movi_start = s->start_pos;
demuxer->movi_end = s->end_pos;
demuxer->seekable = 1;
- if (demuxer->chapters && dvd_chapter>1 && dvd_chapter<=demuxer->num_chapters)
- {
- if (!mkv_d->has_first_tc)
- {
- mkv_d->first_tc = 0;
- mkv_d->has_first_tc = 1;
- }
- demux_mkv_seek (demuxer,
- demuxer->chapters[dvd_chapter-1].start/1000.0, 0.0,
- SEEK_ABSOLUTE);
- }
}
return DEMUXER_TYPE_MATROSKA;
Modified: trunk/mencoder.c
==============================================================================
--- trunk/mencoder.c (original)
+++ trunk/mencoder.c Mon Feb 11 23:03:34 2008
@@ -603,6 +603,11 @@ if(stream->type==STREAMTYPE_DVDNAV){
mp_msg(MSGT_DEMUXER, MSGL_FATAL, MSGTR_CannotOpenDemuxer);
mencoder_exit(1,NULL);
}
+
+ if(dvd_chapter>1) {
+ float pts;
+ demuxer_seek_chapter(demuxer, dvd_chapter-1, 1, &pts, NULL, NULL);
+ }
d_audio=demuxer2 ? demuxer2->audio : demuxer->audio;
d_video=demuxer->video;
@@ -1098,6 +1103,11 @@ while(!at_eof){
--play_n_frames;
if(play_n_frames<0) break;
}
+ if(dvd_last_chapter>0) {
+ int cur_chapter = demuxer_get_current_chapter(demuxer);
+ if(cur_chapter!=-1 && cur_chapter+1>dvd_last_chapter)
+ break;
+ }
goto_redo_edl:
if (next_edl_record && sh_video && sh_video->pts >= next_edl_record->start_sec) {
Modified: trunk/mplayer.c
==============================================================================
--- trunk/mplayer.c (original)
+++ trunk/mplayer.c Mon Feb 11 23:03:34 2008
@@ -3278,6 +3278,11 @@ if (mpctx->demuxer && mpctx->demuxer->ty
if(!mpctx->demuxer)
goto goto_next_file;
+if(dvd_chapter>1) {
+ float pts;
+ demuxer_seek_chapter(mpctx->demuxer, dvd_chapter-1, 1, &pts, NULL, NULL);
+}
+
inited_flags|=INITED_DEMUXER;
if (mpctx->stream->type != STREAMTYPE_DVD && mpctx->stream->type != STREAMTYPE_DVDNAV) {
@@ -3644,6 +3649,13 @@ if (mpctx->stream->type == STREAMTYPE_DV
while(!mpctx->eof){
float aq_sleep_time=0;
+
+if(dvd_last_chapter>0) {
+ int cur_chapter = demuxer_get_current_chapter(mpctx->demuxer);
+ if(cur_chapter!=-1 && cur_chapter+1>dvd_last_chapter)
+ goto goto_next_file;
+}
+
if(!mpctx->sh_audio && mpctx->d_audio->sh) {
mpctx->sh_audio = mpctx->d_audio->sh;
mpctx->sh_audio->ds = mpctx->d_audio;
Modified: trunk/stream/stream_dvd.c
==============================================================================
--- trunk/stream/stream_dvd.c (original)
+++ trunk/stream/stream_dvd.c Mon Feb 11 23:03:34 2008
@@ -883,22 +883,6 @@ static int open_s(stream_t *stream,int m
mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_DVD_CURRENT_TITLE=%d\n", dvd_title);
--dvd_title; // remap 1.. -> 0..
/**
- * Make sure the chapter number is valid for this title.
- */
- mp_msg(MSGT_OPEN,MSGL_STATUS, MSGTR_DVDnumChapters, tt_srpt->title[dvd_title].nr_of_ptts);
- if(dvd_chapter<1 || dvd_chapter>tt_srpt->title[dvd_title].nr_of_ptts) {
- mp_msg(MSGT_OPEN,MSGL_ERR, MSGTR_DVDinvalidChapter, dvd_chapter);
- goto fail;
- }
- if(dvd_last_chapter>0) {
- if(dvd_last_chapter<dvd_chapter || dvd_last_chapter>tt_srpt->title[dvd_title].nr_of_ptts) {
- mp_msg(MSGT_OPEN,MSGL_ERR, MSGTR_DVDinvalidLastChapter, dvd_last_chapter);
- goto fail;
- }
- }
- --dvd_chapter; // remap 1.. -> 0..
- /* XXX No need to remap dvd_last_chapter */
- /**
* Make sure the angle number is valid for this title.
*/
mp_msg(MSGT_OPEN,MSGL_STATUS, MSGTR_DVDnumAngles, tt_srpt->title[dvd_title].nr_of_angles);
@@ -1041,18 +1025,13 @@ static int open_s(stream_t *stream,int m
* Determine which program chain we want to watch. This is based on the
* chapter number.
*/
- pgc_id = vts_file->vts_ptt_srpt->title[ttn].ptt[dvd_chapter].pgcn; // local
- pgn = vts_file->vts_ptt_srpt->title[ttn].ptt[dvd_chapter].pgn; // local
+ pgc_id = vts_file->vts_ptt_srpt->title[ttn].ptt[0].pgcn; // local
+ pgn = vts_file->vts_ptt_srpt->title[ttn].ptt[0].pgn; // local
d->cur_pgc_idx = pgc_id-1;
d->cur_pgc = vts_file->vts_pgcit->pgci_srp[pgc_id-1].pgc;
d->cur_cell = d->cur_pgc->program_map[pgn-1] - 1; // start playback here
d->packs_left=-1; // for Navi stuff
d->angle_seek=0;
- /* XXX dvd_last_chapter is in the range 1..nr_of_ptts */
- if(dvd_last_chapter > 0 && dvd_last_chapter < tt_srpt->title[dvd_title].nr_of_ptts) {
- pgn=vts_file->vts_ptt_srpt->title[ttn].ptt[dvd_last_chapter].pgn;
- d->last_cell=d->cur_pgc->program_map[pgn-1] - 1;
- } else
d->last_cell=d->cur_pgc->nr_of_cells;
if(d->cur_pgc->cell_playback[d->cur_cell].block_type == BLOCK_TYPE_ANGLE_BLOCK )
Modified: trunk/stream/stream_dvdnav.c
==============================================================================
--- trunk/stream/stream_dvdnav.c (original)
+++ trunk/stream/stream_dvdnav.c Mon Feb 11 23:03:34 2008
@@ -558,17 +558,11 @@ static int open_s(stream_t *stream,int m
}
if(p->track > 0) {
- if(dvd_chapter > 0 && dvd_last_chapter > 0 && dvd_chapter > dvd_last_chapter) {
- mp_msg(MSGT_OPEN,MSGL_FATAL,"dvdnav_stream, invalid chapter range: %d > %d\n", dvd_chapter, dvd_last_chapter);
- return STREAM_UNSUPPORTED;
- }
priv->title = p->track;
if(dvdnav_title_play(priv->dvdnav, p->track) != DVDNAV_STATUS_OK) {
mp_msg(MSGT_OPEN,MSGL_FATAL,"dvdnav_stream, couldn't select title %d, error '%s'\n", p->track, dvdnav_err_to_string(priv->dvdnav));
return STREAM_UNSUPPORTED;
}
- if(dvd_chapter > 0)
- dvdnav_part_play(priv->dvdnav, p->track, dvd_chapter);
} else if (p->track == 0) {
if(dvdnav_menu_call(priv->dvdnav, DVD_MENU_Root) != DVDNAV_STATUS_OK)
dvdnav_menu_call(priv->dvdnav, DVD_MENU_Title);
3
3