This is a patch I made to add options to control mergedfb behaviour, using options similar to those present in radeon driver. MergedXineramaSecondIsScreen0 swaps the logical Xinerama screen in mergedfb mode. MergedNonRectangular allows to have different resolutions. MergedMouseRestriction restrict mouse movement to display size when using non rectangular framebuffer. I tried to use naming conventions similar to other options. Patch is against 1.7.2 version, but it's suitable also for 1.7.3 and 1.7.4 versions.. Bye --- a/src/i830_driver.c +++ b/src/i830_driver.c @@ -268,6 +268,9 @@ OPTION_SECONDHSYNC, OPTION_SECONDVREFRESH, OPTION_SECONDPOSITION, + OPTION_SECONDISSCRN0, + OPTION_MERGEDFBNONRECT, + OPTION_MERGEDFBMOUSER, OPTION_INTELXINERAMA } I830Opts; @@ -292,6 +295,9 @@ {OPTION_LINEARALLOC, "LinearAlloc", OPTV_INTEGER, {0}, FALSE}, {OPTION_MERGEDFB, "MergedFB", OPTV_BOOLEAN, {0}, FALSE}, {OPTION_METAMODES, "MetaModes", OPTV_STRING, {0}, FALSE}, + {OPTION_SECONDISSCRN0,"MergedXineramaSecondIsScreen0", OPTV_BOOLEAN, {0}, FALSE }, + {OPTION_MERGEDFBNONRECT,"MergedNonRectangular",OPTV_BOOLEAN, {0}, FALSE}, + {OPTION_MERGEDFBMOUSER,"MergedMouseRestriction",OPTV_BOOLEAN, {0}, FALSE}, {OPTION_SECONDHSYNC, "SecondMonitorHorizSync",OPTV_STRING, {0}, FALSE }, {OPTION_SECONDVREFRESH,"SecondMonitorVertRefresh",OPTV_STRING,{0}, FALSE }, {OPTION_SECONDPOSITION,"SecondPosition",OPTV_STRING, {0}, FALSE }, @@ -4685,6 +4691,25 @@ } xfree(tempstr); } + + /* If OPTION_SECONDISSCRN0 is true then swap screens */ + if(xf86GetOptValBool(pI830->Options, OPTION_SECONDISSCRN0, TRUE)) { + if (pI830->SecondIsScrn0) pI830->SecondIsScrn0= FALSE; + else pI830->SecondIsScrn0= TRUE; + } + + /* Set pI830->NonRect according to OPTION_MERGEDFBNONRECT */ + if(xf86GetOptValBool(pI830->Options, OPTION_MERGEDFBNONRECT, TRUE)) + pI830->NonRect = TRUE; + else + pI830->NonRect = FALSE; + + /* Set pI830->MouseRestrictions according to OPTION_MERGEDFBMOUSER */ + if(xf86GetOptValBool(pI830->Options, OPTION_MERGEDFBMOUSER, TRUE)) + pI830->MouseRestrictions = TRUE; + else + pI830->MouseRestrictions = FALSE; + if((s = (char *)xf86GetOptValString(pI830->Options, OPTION_METAMODES))) { pI830->MetaModes = xalloc(strlen(s) + 1); if(pI830->MetaModes)
Can you use the "Create a New Attachment" feature and attach this as an actual patch rather than inlining it. Thanks.
Created attachment 8402 [details] [review] patch to control mergedfb options
(In reply to comment #2) > Created an attachment (id=8402) [edit] > patch to control mergedfb options > Sorry I didn't know these bugzilla features about patches... there is always something new to learn!
Applied. Closing.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.