I'm trying to find out why I can't get a PAL mode that works on my TV with xrandr.
I can set a nice 16:9-adapted PAL modeline in Windows PowerStrip with
modeline "960x576" 20.348 960 1050 1098 1294 576 592 600 627 interlace +hsync +vsync
just results in a black screen on my TV (no sync). Changing +hsync to -hsync gives me horisontal sync (a vertically rolling picture), but -vsync does not give me vertical sync. Neither -csync nor +csync works at all; gives no sync at all on the TV.
xrandr --newmode "960x576_50i" 20.348 960 1050 1098 1294 576 592 600 627 +hsync +vsync interlace
xrandr --addmode DVI-1 960x576_50i
xrandr --output DVI-1 --mode 960x576_50i
I'm trying to trace the xrandr call through X to see what happens when xrandr --addmode is called. The xrandr application is implemented in xrandr.c in the xrandr-1.3.2 package on my machine. This code calls XRRCreateMode which is implemented in XrrMode.c in the libXrandr-1.3.0 package.
Here's where I'm losing the trail; XRRCreateMode() calls GetReq(RRCreateMode, req), fills in the data structure req, then calls Data() and _XReply(). I'm guessing conrol is handled over to the X Server here? Where can I find the code where the request is handled/implemented?
BTW, I found a probable bug at xrandr.c:2025: the return type of check_strtod() is declared as int, but should probably be double:
As is, this declaration discards the fraction from the pixel clock value in MHz.
double result = strtod(s, &endptr);
if (s == endptr)