I use xrandr for scaling to make a small netbook screen able to display apps that don't fit in 1024x600 and noticed this regression over the last year in 1.11. I finally decided to look closer since 1.12 didn't seem to fix the issue and came across this report.
I looked at the revert commit to get idea of area that could possibly be fixed and it seems like crtc_bounds() is probably a function that should be returning a value related to panning/scaling.
I traced were xrandr output is querying the panning/scaling values it displays and looks like comes from ProcRRGetCrtcInfo() and that function makes use of RRCrtcGetScanoutSize() to scaling width/height to correct size. Panning uses rrGetPanning().
To test the idea, I modified crtc_bounds to handle scaling case by adding ProcRRGetCrtcInfo() call. It does seem to work and I've not noticed a negative in limitted testing.
I patched a source RPM so I can't offer a real patch right now but here is my modified version of function to get an idea:
static void
crtc_bounds(RRCrtcPtr crtc, int *left, int *right, int *top, int *bottom)
{
int width, height;
RRCrtcGetScanoutSize (crtc, &width, &height);
*left = crtc->x;
*top = crtc->y;
switch (crtc->rotation) {
case RR_Rotate_0:
case RR_Rotate_180:
default:
*right = crtc->x + width;
*bottom = crtc->y + height;
return;
case RR_Rotate_90:
case RR_Rotate_270:
*right = crtc->x + height;
*bottom = crtc->y + width;
return;
}
}
I use xrandr for scaling to make a small netbook screen able to display apps that don't fit in 1024x600 and noticed this regression over the last year in 1.11. I finally decided to look closer since 1.12 didn't seem to fix the issue and came across this report.
I looked at the revert commit to get idea of area that could possibly be fixed and it seems like crtc_bounds() is probably a function that should be returning a value related to panning/scaling.
I traced were xrandr output is querying the panning/scaling values it displays and looks like comes from ProcRRGetCrtcInfo() and that function makes use of RRCrtcGetScanou tSize() to scaling width/height to correct size. Panning uses rrGetPanning().
To test the idea, I modified crtc_bounds to handle scaling case by adding ProcRRGetCrtcInfo() call. It does seem to work and I've not noticed a negative in limitted testing.
I patched a source RPM so I can't offer a real patch right now but here is my modified version of function to get an idea:
static void RRCrtcPtr crtc, int *left, int *right, int *top, int *bottom) anoutSize (crtc, &width, &height);
crtc_bounds(
{
int width, height;
RRCrtcGetSc
*left = crtc->x;
*top = crtc->y;
switch (crtc->rotation) {
case RR_Rotate_0:
case RR_Rotate_180:
default:
*right = crtc->x + width;
*bottom = crtc->y + height;
return;
case RR_Rotate_90:
case RR_Rotate_270:
*right = crtc->x + height;
*bottom = crtc->y + width;
return;
}
}