[Resent as my previous email didn't make it to the list] Hi Chris,
On Tue, 2004-11-30 at 22:42, [EMAIL PROTECTED] wrote: > I've been implementing MythTV using Xbox as frontend, and have run > into a problem that I believe (after searching google and the various > lists) needs to be fixed with a new configuration option. I am > planning to add a new 'MonitorAspect' option to the appearance setup > section that can be switched between '4:3' and '16:9'. to tell MythTV > that pixels are not displayed as squares. I've run into the same kind of problems. Although the canonical way to fix this is to set the screen size in the X server config file, I've found that there are rounding errors introduced with this. I've got a couple of patches that I'm attaching which, although they don't quite do what you are talking about, are solving the problem for me. The first patch enables some configuration options which had been commented out. These allow you to manually specify the screen dimensions. The second patch adds the code required to use these options to videoout_xv.cpp & videoout_xvmc.cpp. These work for me (I'm specifying my display dimension as 1024x576 for my 16:9 TV), but I haven't posted them yet as I'm having some problems with 4:3 material not being scaled properly. I don't think this is related to these patches, but wanted to track it down to be sure. The patches are against a fairly old CVS checkout but are quite simple so shouldn't need much adjustment if they don't apply cleanly. I'm not sure if this is a good long term solution nor whether specifying the size or an aspect ratio makes more sense from a usability point of view. It'd be good to get something to the point where it can be submitted, though. Let me know if this works for you or not. Robert
diff -Naur mythtv/programs/mythfrontend/globalsettings.cpp mythtv.new/programs/mythfrontend/globalsettings.cpp --- mythtv/programs/mythfrontend/globalsettings.cpp 2004-09-24 03:37:54.000000000 +0100 +++ mythtv.new/programs/mythfrontend/globalsettings.cpp 2004-11-13 23:47:47.028981592 +0000 @@ -2589,8 +2589,8 @@ screen->addChild(XineramaScreen()); screen->addChild(GuiWidth()); screen->addChild(GuiHeight()); -// screen->addChild(DisplaySizeHeight()); -// screen->addChild(DisplaySizeWidth()); + screen->addChild(DisplaySizeHeight()); + screen->addChild(DisplaySizeWidth()); screen->addChild(GuiOffsetX()); screen->addChild(GuiOffsetY()); screen->addChild(GuiSizeForTV());
diff -Naur mythtv/libs/libmythtv/videoout_xv.cpp mythtv.new/libs/libmythtv/videoout_xv.cpp --- mythtv/libs/libmythtv/videoout_xv.cpp 2004-09-07 00:58:32.000000000 +0100 +++ mythtv.new/libs/libmythtv/videoout_xv.cpp 2004-11-16 22:12:28.700184384 +0000 @@ -170,8 +170,16 @@ dispx = dispy = 0; dispw = display_res->Width(); disph = display_res->Height(); - w_mm = display_res->Width_mm(); - h_mm = display_res->Height_mm(); + + if (myth_dsw != 0) + w_mm = myth_dsw; + else + w_mm = display_res->Width_mm(); + + if (myth_dsh != 0) + h_mm = myth_dsh; + else + h_mm = display_res->Height_mm(); data->display_aspect = static_cast<float>(w_mm/h_mm); @@ -276,8 +284,16 @@ // Make a note of the new size dispw = display_res->Width(); disph = display_res->Height(); - w_mm = display_res->Width_mm(); - h_mm = display_res->Height_mm(); + + if (myth_dsw != 0) + w_mm = myth_dsw; + else + w_mm = display_res->Width_mm(); + + if (myth_dsh != 0) + h_mm = myth_dsh; + else + h_mm = display_res->Height_mm(); // Resize X window to fill new resolution XMoveResizeWindow(data->XJ_disp, winid, 0, 0, dispw, disph); diff -Naur mythtv/libs/libmythtv/videoout_xvmc.cpp mythtv.new/libs/libmythtv/videoout_xvmc.cpp --- mythtv/libs/libmythtv/videoout_xvmc.cpp 2004-11-15 00:13:51.249876640 +0000 +++ mythtv.new/libs/libmythtv/videoout_xvmc.cpp 2004-11-16 21:38:06.065752480 +0000 @@ -196,8 +196,16 @@ dispx = dispy = 0; dispw = display_res->Width(); disph = display_res->Height(); - w_mm = display_res->Width_mm(); - h_mm = display_res->Height_mm(); + + if (myth_dsw != 0) + w_mm = myth_dsw; + else + w_mm = display_res->Width_mm(); + + if (myth_dsh != 0) + h_mm = myth_dsh; + else + h_mm = display_res->Height_mm(); data->display_aspect = (float)(w_mm/h_mm); @@ -291,8 +299,16 @@ // Make a note of the new size dispw = display_res->Width(); disph = display_res->Height(); - w_mm = display_res->Width_mm(); - h_mm = display_res->Height_mm(); + + if (myth_dsw != 0) + w_mm = myth_dsw; + else + w_mm = display_res->Width_mm(); + + if (myth_dsh != 0) + h_mm = myth_dsh; + else + h_mm = display_res->Height_mm(); // Resize X window to fill new resolution XMoveResizeWindow(data->XJ_disp, winid, 0, 0, dispw, disph);
_______________________________________________ mythtv-dev mailing list [EMAIL PROTECTED] http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev