From 15d50842081823d2a124f0939cb8595c379c746f Mon Sep 17 00:00:00 2001 From: Daniel Caujolle-Bert Date: Sun, 14 Oct 2001 23:19:59 +0000 Subject: Update xine.h doxygen comments. Use constants for aspect ratio in vo drivers. CVS patchset: 812 CVS date: 2001/10/14 23:19:59 --- src/video_out/video_out_syncfb.c | 10 +++++----- src/video_out/video_out_xshm.c | 14 +++++++------- src/video_out/video_out_xv.c | 14 +++++++------- src/xine-engine/xine_internal.h | 8 +++++++- 4 files changed, 26 insertions(+), 20 deletions(-) (limited to 'src') diff --git a/src/video_out/video_out_syncfb.c b/src/video_out/video_out_syncfb.c index f00362621..645b9f50b 100644 --- a/src/video_out/video_out_syncfb.c +++ b/src/video_out/video_out_syncfb.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: video_out_syncfb.c,v 1.14 2001/10/10 10:06:52 jkeil Exp $ + * $Id: video_out_syncfb.c,v 1.15 2001/10/14 23:19:59 f1rmb Exp $ * * video_out_syncfb.c, Matrox G400 video extension interface for xine * @@ -415,16 +415,16 @@ printf("new frame format width %d height %d ratio %d format %x\n",width,height,r fprintf (stderr, "invalid ratio\n"); exit (1); break; - case 2: + case XINE_ASPECT_RATIO_4_3: aspect_ratio = 4.0 / 3.0; break; - case 3: + case XINE_ASPECT_RATIO_ANAMORPHIC: aspect_ratio = 16.0 / 9.0; break; - case 4: + case XINE_ASPECT_RATIO_211_1: aspect_ratio = 2.11/1.0; break; - case 42: /* some stupid stream => don't touch aspect ratio */ + case XINE_ASPECT_RATIO_DONT_TOUCH: /* some stupid stream => don't touch aspect ratio */ default: xprintf (VIDEO, "unknown aspect ratio (%d) in stream. untouched.\n", _mga_priv.ratio); case 1: /* "square" source pels */ diff --git a/src/video_out/video_out_xshm.c b/src/video_out/video_out_xshm.c index 33e5f97b4..401f84aaf 100644 --- a/src/video_out/video_out_xshm.c +++ b/src/video_out/video_out_xshm.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: video_out_xshm.c,v 1.45 2001/10/11 20:32:08 miguelfreitas Exp $ + * $Id: video_out_xshm.c,v 1.46 2001/10/14 23:19:59 f1rmb Exp $ * * video_out_xshm.c, X11 shared memory extension interface for xine * @@ -456,22 +456,22 @@ static void xshm_calc_output_size (xshm_driver_t *this) { switch (this->user_ratio) { case ASPECT_AUTO: switch (this->delivered_ratio_code) { - case 3: /* anamorphic */ + case XINE_ASPECT_RATIO_ANAMORPHIC: /* anamorphic */ desired_ratio = 16.0 /9.0; break; - case 4: /* 2.11:1 */ + case XINE_ASPECT_RATIO_211_1: /* 2.11:1 */ desired_ratio = 2.11/1.0; break; - case 1: /* square pels */ - case 42: /* probably non-mpeg stream => don't touch aspect ratio */ + case XINE_ASPECT_RATIO_SQUARE: /* square pels */ + case XINE_ASPECT_RATIO_DONT_TOUCH: /* probably non-mpeg stream => don't touch aspect ratio */ desired_ratio = image_ratio; break; - case 0: /* forbidden -> 4:3 */ + case 0: /* forbidden -> 4:3 */ fprintf (stderr, "invalid ratio, using 4:3\n"); default: xprintf (VIDEO, "unknown aspect ratio (%d) in stream => using 4:3\n", this->delivered_ratio_code); - case 2: /* 4:3 */ + case XINE_ASPECT_RATIO_4_3: /* 4:3 */ desired_ratio = 4.0 / 3.0; break; } diff --git a/src/video_out/video_out_xv.c b/src/video_out/video_out_xv.c index e937ce3e0..aec1d141a 100644 --- a/src/video_out/video_out_xv.c +++ b/src/video_out/video_out_xv.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: video_out_xv.c,v 1.67 2001/10/14 20:34:40 guenter Exp $ + * $Id: video_out_xv.c,v 1.68 2001/10/14 23:19:59 f1rmb Exp $ * * video_out_xv.c, X11 video extension interface for xine * @@ -543,22 +543,22 @@ static void xv_calc_format (xv_driver_t *this, switch (this->props[VO_PROP_ASPECT_RATIO].value) { case ASPECT_AUTO: switch (ratio_code) { - case 3: /* anamorphic */ + case XINE_ASPECT_RATIO_ANAMORPHIC: /* anamorphic */ desired_ratio = 16.0 /9.0; break; - case 4: /* 2.11:1 */ + case XINE_ASPECT_RATIO_211_1: /* 2.11:1 */ desired_ratio = 2.11/1.0; break; - case 1: /* "square" source pels */ - case 42: /* probably non-mpeg stream => don't touch aspect ratio */ + case XINE_ASPECT_RATIO_SQUARE: /* "square" source pels */ + case XINE_ASPECT_RATIO_DONT_TOUCH: /* probably non-mpeg stream => don't touch aspect ratio */ desired_ratio = image_ratio; break; - case 0: /* forbidden */ + case 0: /* forbidden */ fprintf (stderr, "invalid ratio, using 4:3\n"); default: xprintf (VIDEO, "unknown aspect ratio (%d) in stream => using 4:3\n", ratio_code); - case 2: /* 4:3 */ + case XINE_ASPECT_RATIO_4_3: /* 4:3 */ desired_ratio = 4.0 / 3.0; break; } diff --git a/src/xine-engine/xine_internal.h b/src/xine-engine/xine_internal.h index 01f0b8d30..4376d4219 100644 --- a/src/xine-engine/xine_internal.h +++ b/src/xine-engine/xine_internal.h @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_internal.h,v 1.48 2001/10/07 17:08:23 guenter Exp $ + * $Id: xine_internal.h,v 1.49 2001/10/14 23:19:59 f1rmb Exp $ * */ @@ -523,6 +523,12 @@ int xine_get_current_frame (xine_t *this, int *width, int *height, uint8_t **y, uint8_t **u, uint8_t **v); +#define XINE_ASPECT_RATIO_SQUARE 1 +#define XINE_ASPECT_RATIO_4_3 2 +#define XINE_ASPECT_RATIO_ANAMORPHIC 3 +#define XINE_ASPECT_RATIO_211_1 4 +#define XINE_ASPECT_RATIO_DONT_TOUCH 42 + #ifdef __cplusplus } #endif -- cgit v1.2.3