diff options
author | Miguel Freitas <miguelfreitas@users.sourceforge.net> | 2004-09-22 20:29:13 +0000 |
---|---|---|
committer | Miguel Freitas <miguelfreitas@users.sourceforge.net> | 2004-09-22 20:29:13 +0000 |
commit | fa11460bbd06540d43ffe53d047f25639a0a6b83 (patch) | |
tree | 15c95a55bb4fbb9ea3a586f2bc171a33f787033a /src/libmpeg2/header.c | |
parent | e115a32802f4284912a2833c04c06d65270cfdef (diff) | |
download | xine-lib-fa11460bbd06540d43ffe53d047f25639a0a6b83.tar.gz xine-lib-fa11460bbd06540d43ffe53d047f25639a0a6b83.tar.bz2 |
- added cropping capability (thanks James Stembridge)
- some vo drivers support cropping natively.
(only xv and xvmc have been tested)
- add software crop fallback to video_out.c
- skip yuv2rgb processing at xshm for not yet cropped frames
(these frames are never shown)
- libmpeg2 and ffmpeg now may use crop support
- bump vo api. (changes to xvmc/xxmc will follow)
CVS patchset: 6991
CVS date: 2004/09/22 20:29:13
Diffstat (limited to 'src/libmpeg2/header.c')
-rw-r--r-- | src/libmpeg2/header.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/libmpeg2/header.c b/src/libmpeg2/header.c index c68ee5165..0f10588b0 100644 --- a/src/libmpeg2/header.c +++ b/src/libmpeg2/header.c @@ -116,8 +116,11 @@ int mpeg2_header_sequence (picture_t * picture, uint8_t * buffer) height = (buffer[0] << 16) | (buffer[1] << 8) | buffer[2]; - width = ((height >> 12) + 15) & ~15; - height = ((height & 0xfff) + 15) & ~15; + picture->display_width = width = (height >> 12); + picture->display_height = height = (height & 0xfff); + + width = (width + 15) & ~15; + height = (height + 15) & ~15; if ((width > 1920) || (height > 1152)) return 1; /* size restrictions for MP@HL */ |