diff options
author | Petri Hintukainen <phintuka@users.sourceforge.net> | 2012-02-14 22:26:28 +0200 |
---|---|---|
committer | Petri Hintukainen <phintuka@users.sourceforge.net> | 2012-02-14 22:26:28 +0200 |
commit | c7b56e4119bc8870fc4f35ac38159414cfe54ff1 (patch) | |
tree | daa4a41dde50a45b5a14a98bd8c4a231a6345a94 /src | |
parent | 428214feb6e7f8ac24e64d9c6d8fbd5382bf539a (diff) | |
parent | 8104053a5d71f7ca8c673469d81fc961542e7560 (diff) | |
download | xine-lib-c7b56e4119bc8870fc4f35ac38159414cfe54ff1.tar.gz xine-lib-c7b56e4119bc8870fc4f35ac38159414cfe54ff1.tar.bz2 |
Merge from 1.1
--HG--
rename : src/xine-utils/xineutils.h => include/xine/xineutils.h
Diffstat (limited to 'src')
-rw-r--r-- | src/demuxers/demux_asf.c | 4 | ||||
-rw-r--r-- | src/video_out/video_out_vidix.c | 8 | ||||
-rw-r--r-- | src/video_out/video_out_xcbxv.c | 9 | ||||
-rw-r--r-- | src/video_out/video_out_xv.c | 9 | ||||
-rw-r--r-- | src/video_out/video_out_xvmc.c | 8 | ||||
-rw-r--r-- | src/video_out/video_out_xxmc.c | 8 | ||||
-rw-r--r-- | src/xine-utils/color.c | 3 |
7 files changed, 48 insertions, 1 deletions
diff --git a/src/demuxers/demux_asf.c b/src/demuxers/demux_asf.c index b33c83b18..71fc2b22a 100644 --- a/src/demuxers/demux_asf.c +++ b/src/demuxers/demux_asf.c @@ -1039,6 +1039,10 @@ static int asf_parse_packet_payload_header(demux_asf_t *this, uint32_t p_hdr_siz #ifdef LOG timestamp = get_le32(this); p_hdr_size += 4; duration = get_le16(this); p_hdr_size += 2; +#else + /* skip the above bytes */ + this->input->seek (this->input, 6, SEEK_CUR); + p_hdr_size += 6; #endif lprintf ("timestamp=%"PRId64", duration=%"PRId64"\n", timestamp, duration); diff --git a/src/video_out/video_out_vidix.c b/src/video_out/video_out_vidix.c index 41406fb58..81ae8e01a 100644 --- a/src/video_out/video_out_vidix.c +++ b/src/video_out/video_out_vidix.c @@ -697,6 +697,8 @@ static int vidix_get_property (vo_driver_t *this_gen, int property) { vidix_driver_t *this = (vidix_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + switch (property) { case VO_PROP_WINDOW_WIDTH: this->props[property].value = this->sc.gui_width; @@ -731,6 +733,8 @@ static int vidix_set_property (vo_driver_t *this_gen, vidix_driver_t *this = (vidix_driver_t *) this_gen; int err; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + if ((value >= this->props[property].min) && (value <= this->props[property].max)) { @@ -853,6 +857,10 @@ static void vidix_get_property_min_max (vo_driver_t *this_gen, vidix_driver_t *this = (vidix_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) { + *min = *max = 0; + return; + } *min = this->props[property].min; *max = this->props[property].max; } diff --git a/src/video_out/video_out_xcbxv.c b/src/video_out/video_out_xcbxv.c index f098ceed8..b6e272d37 100644 --- a/src/video_out/video_out_xcbxv.c +++ b/src/video_out/video_out_xcbxv.c @@ -640,6 +640,8 @@ static void xv_display_frame (vo_driver_t *this_gen, vo_frame_t *frame_gen) { static int xv_get_property (vo_driver_t *this_gen, int property) { xv_driver_t *this = (xv_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return (0); + switch (property) { case VO_PROP_WINDOW_WIDTH: this->props[property].value = this->sc.gui_width; @@ -680,6 +682,8 @@ static int xv_set_property (vo_driver_t *this_gen, int property, int value) { xv_driver_t *this = (xv_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + if (this->props[property].atom != XCB_NONE) { xcb_xv_get_port_attribute_cookie_t get_attribute_cookie; xcb_xv_get_port_attribute_reply_t *get_attribute_reply; @@ -757,6 +761,11 @@ static void xv_get_property_min_max (vo_driver_t *this_gen, int property, int *min, int *max) { xv_driver_t *this = (xv_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) { + *min = *max = 0; + return; + } + *min = this->props[property].min; *max = this->props[property].max; } diff --git a/src/video_out/video_out_xv.c b/src/video_out/video_out_xv.c index edff2905a..2d709c599 100644 --- a/src/video_out/video_out_xv.c +++ b/src/video_out/video_out_xv.c @@ -741,6 +741,8 @@ static void xv_display_frame (vo_driver_t *this_gen, vo_frame_t *frame_gen) { static int xv_get_property (vo_driver_t *this_gen, int property) { xv_driver_t *this = (xv_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return (0); + switch (property) { case VO_PROP_WINDOW_WIDTH: this->props[property].value = this->sc.gui_width; @@ -784,6 +786,8 @@ static int xv_set_property (vo_driver_t *this_gen, printf("xv_set_property: property=%d, value=%d\n", property, value ); + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + if (this->props[property].atom != None) { /* value is out of bound */ @@ -857,6 +861,11 @@ static void xv_get_property_min_max (vo_driver_t *this_gen, int property, int *min, int *max) { xv_driver_t *this = (xv_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) { + *min = *max = 0; + return; + } + *min = this->props[property].min; *max = this->props[property].max; } diff --git a/src/video_out/video_out_xvmc.c b/src/video_out/video_out_xvmc.c index 3158840a0..554609dee 100644 --- a/src/video_out/video_out_xvmc.c +++ b/src/video_out/video_out_xvmc.c @@ -991,6 +991,8 @@ static int xvmc_get_property (vo_driver_t *this_gen, int property) { lprintf ("xvmc_get_property\n"); + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + switch (property) { case VO_PROP_WINDOW_WIDTH: this->props[property].value = this->sc.gui_width; @@ -1033,6 +1035,8 @@ static int xvmc_set_property (vo_driver_t *this_gen, lprintf ("xvmc_set_property %d value %d\n",property,value); + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + if (this->props[property].atom != None) { /* value is out of bound */ if((value < this->props[property].min) || (value > this->props[property].max)) @@ -1101,6 +1105,10 @@ static void xvmc_get_property_min_max (vo_driver_t *this_gen, lprintf ("xvmc_get_property_min_max\n"); + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) { + *min = *max = 0; + return; + } *min = this->props[property].min; *max = this->props[property].max; } diff --git a/src/video_out/video_out_xxmc.c b/src/video_out/video_out_xxmc.c index 14fcbce97..d8571e74a 100644 --- a/src/video_out/video_out_xxmc.c +++ b/src/video_out/video_out_xxmc.c @@ -1794,6 +1794,8 @@ static void xxmc_display_frame (vo_driver_t *this_gen, vo_frame_t *frame_gen) static int xxmc_get_property (vo_driver_t *this_gen, int property) { xxmc_driver_t *this = (xxmc_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + switch (property) { case VO_PROP_WINDOW_WIDTH: this->props[property].value = this->sc.gui_width; @@ -1844,6 +1846,8 @@ static int xxmc_set_property (vo_driver_t *this_gen, int property, int value) { xxmc_driver_t *this = (xxmc_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) return 0; + if (this->props[property].atom != None) { /* value is out of bound */ @@ -1932,6 +1936,10 @@ static void xxmc_get_property_min_max (vo_driver_t *this_gen, int property, int *min, int *max) { xxmc_driver_t *this = (xxmc_driver_t *) this_gen; + if ((property < 0) || (property >= VO_NUM_PROPERTIES)) { + *min = *max = 0; + return; + } *min = this->props[property].min; *max = this->props[property].max; } diff --git a/src/xine-utils/color.c b/src/xine-utils/color.c index 930fb77d0..b9b007c7a 100644 --- a/src/xine-utils/color.c +++ b/src/xine-utils/color.c @@ -77,7 +77,8 @@ * next 9 defines. */ -#if 1 +/* convert full range rgb to mpeg range yuv */ +#if 0 #define Y_R (SCALEFACTOR * 0.29900) #define Y_G (SCALEFACTOR * 0.58700) |