diff options
author | alex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-11-30 16:59:02 +0000 |
---|---|---|
committer | alex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2001-11-30 16:59:02 +0000 |
commit | 855f5990e561aa55a9d628dfc5b531a02c0d206f (patch) | |
tree | 38d1b52d1dc97ff80ca1be6bdde97adea10e2dca /libmpdemux | |
parent | d38ab4b67a686d1025f50309761d2511cefbd017 (diff) |
update
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@3221 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r-- | libmpdemux/tvi_v4l.c | 38 |
1 files changed, 10 insertions, 28 deletions
diff --git a/libmpdemux/tvi_v4l.c b/libmpdemux/tvi_v4l.c index 0e6491a1a7..7f9ae1e08a 100644 --- a/libmpdemux/tvi_v4l.c +++ b/libmpdemux/tvi_v4l.c @@ -88,6 +88,7 @@ static int palette2depth(int palette) { switch(palette) { + /* component */ case VIDEO_PALETTE_RGB555: return(15); case VIDEO_PALETTE_RGB565: @@ -96,10 +97,18 @@ static int palette2depth(int palette) return(24); case VIDEO_PALETTE_RGB32: return(32); + /* planar */ + case VIDEO_PALETTE_YUV422P: + case VIDEO_PALETTE_YUV411P: case VIDEO_PALETTE_YUV420P: + case VIDEO_PALETTE_YUV410P: return(12); + /* packed */ case VIDEO_PALETTE_YUV422: + case VIDEO_PALETTE_YUYV: case VIDEO_PALETTE_UYVY: + case VIDEO_PALETTE_YUV420: + case VIDEO_PALETTE_YUV411: return(16); } return(-1); @@ -479,33 +488,6 @@ static int control(priv_t *priv, int cmd, void *arg) { int output_fmt = -1; -#if 0 - switch(priv->palette) - { - case VIDEO_PALETTE_RGB555: - output_fmt = IMGFMT_RGB15; - break; - case VIDEO_PALETTE_RGB565: - output_fmt = IMGFMT_RGB16; - break; - case VIDEO_PALETTE_RGB24: - output_fmt = IMGFMT_RGB24; - break; - case VIDEO_PALETTE_RGB32: - output_fmt = IMGFMT_RGB32; - break; - case VIDEO_PALETTE_UYVY: - output_fmt = IMGFMT_UYVY; - break; - case VIDEO_PALETTE_YUV420P: - output_fmt = IMGFMT_YV12; - break; - default: - mp_msg(MSGT_TV, MSGL_ERR, "no suitable output format found (%s)\n", - PALETTE(priv->palette)); - return(TVI_CONTROL_FALSE); - } -#endif output_fmt = priv->format; (int)*(void **)arg = output_fmt; mp_msg(MSGT_TV, MSGL_INFO, "Output format: %s\n", vo_format_name(output_fmt)); @@ -515,7 +497,7 @@ static int control(priv_t *priv, int cmd, void *arg) priv->format = (int)*(void **)arg; return(TVI_CONTROL_TRUE); case TVI_CONTROL_VID_GET_PLANES: - (int)*(void **)arg = 1; + (int)*(void **)arg = 1; /* FIXME, also not needed at this time */ return(TVI_CONTROL_TRUE); case TVI_CONTROL_VID_GET_BITS: (int)*(void **)arg = palette2depth(format2palette(priv->format)); |