[Mplayer-cvslog] CVS: main/libvo vo_vesa.c,1.15,1.16
Nick Kurshev
nick at mplayer.dev.hu
Sun Oct 21 16:31:01 CEST 2001
Update of /cvsroot/mplayer/main/libvo
In directory mplayer:/var/tmp.root/cvs-serv16217/main/libvo
Modified Files:
vo_vesa.c
Log Message:
Again changed logic:
-screenw, -screenh - force user video mode
-x, -y - force userdefined prescaling
-bpp - forces userdefined bpp
-zoom - enables prescaling (-x, -y)
-fs - scales image to fullscreen (same as ATI's divx/dvd player)
-zoom -fs - (together) scales userdefined prescaling to fullscreen
So full command line should be:
mplayer -vo vesa -screenw WWW -screenh HHH -bpp BPP -x XXX -y YYY -zoom -fs filename
And you will be able to watch movies in 16:9 format with bold black
border at top and bottom of screen.
Index: vo_vesa.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_vesa.c,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- vo_vesa.c 21 Oct 2001 14:02:09 -0000 1.15
+++ vo_vesa.c 21 Oct 2001 14:30:36 -0000 1.16
@@ -354,15 +354,20 @@
uint32_t w,h;
unsigned short *mode_ptr,win_seg;
unsigned bpp,best_x = UINT_MAX,best_y=UINT_MAX,best_mode_idx = UINT_MAX;
- int err;
+ int err,fs_mode;
image_width = width;
image_height = height;
+ fs_mode = 0;
if(flags & 0x8)
{
printf("vo_vesa: switch -flip is not supported\n");
}
if(flags & 0x04) vesa_zoom = 1;
- if(flags & 0x01 && vesa_zoom) vesa_zoom = 2;
+ if(flags & 0x01)
+ {
+ if(vesa_zoom) vesa_zoom = 2;
+ else fs_mode = 1;
+ }
if((err=vbeInit()) != VBE_OK) { PRINT_VBE_ERR("vbeInit",err); return -1; }
memcpy(vib.VESASignature,"VBE2",4);
if((err=vbeGetControllerInfo(&vib)) != VBE_OK)
@@ -498,7 +503,7 @@
printf("vo_vesa: Using VESA mode (%u) = %x [%ux%u@%u]\n"
,best_mode_idx,video_mode,video_mode_info.XResolution
,video_mode_info.YResolution,video_mode_info.BitsPerPixel);
- if( vesa_zoom )
+ if( vesa_zoom || fs_mode )
{
if( format==IMGFMT_YV12 )
{
@@ -507,8 +512,13 @@
vesa_aspect(image_width,image_height,
video_mode_info.XResolution,video_mode_info.YResolution,
&image_width,&image_height);
-/* image_width = video_mode_info.XResolution;
- image_height = video_mode_info.YResolution;*/
+ else
+ if(fs_mode)
+ {
+ image_width = video_mode_info.XResolution;
+ image_height = video_mode_info.YResolution;
+ vesa_zoom = 1;
+ }
scale_xinc=(width << 16) / image_width - 2; /* needed for proper rounding */
scale_yinc=(height << 16) / image_height + 2;
SwScale_Init();
More information about the MPlayer-cvslog
mailing list