Implementing RandR

George Wright gwright at
Thu Sep 18 12:04:50 PDT 2008

On Thursday 18 September 2008 06:41:51 Jacob Welsh wrote:
> > I'm currently working on implementing RandR support in the Xvnc server
> > along with an extension protocol for the client to request that Xvnc
> > changes its framebuffer size on demand.
> What version of RandR are you aiming to support? I don't know if you
> know enough about X and VNC -- I certainly don't -- to implement RandR
> 1.2 support, but that would be really nifty.

I'm only working on having VNC sessions that can be resized for the moment. I 
don't know enough about RandR to implement anything else. Rotations are all 
hardcoded at the moment to use a 0 degree rotation (ie - normal) as we don't 
see much point in implementing rotations. Depth switching can already be done 
as part of the RFB protocol, so the only other thing in RandR that seems to 
make sense is multi-head support.

> I'm imagining that multiple rfb clients connecting to a single Xvnc
> could be registered as separate monitors, with their own modes as
> determined by the client. Monitors and modes can be added and removed
> dynamically via the existing XRandR 1.2 extension. And you could switch
> between traditional "clone" mode and Xinerama-style with "xrandr" or a
> 1.2-capable GUI. So basically you could turn two neighboring thin
> clients into a "dual-head" setup effortlessly. Also it would presumably
> solve your present mode weirdness problem.

That sounds like an incredibly complex and insane project. I pity anyone who 
tries to implement that ;)

> I'm sure that's a lot more work than you set out to do... and even RandR
> 1.1 support in tightvnc will be much appreciated :)

Thanks. I'm most of the way there now. The only problems I've got now are the 
one I detailed at the start of this thread, and that resizing to a desktop 
larger than the initial VNC desktop results in a segfault. I'm pretty sure 
it's because of a memory allocation problem (I don't think the framebuffer is 
reallocated when it's resized).

Today I'm working on getting vncviewer's window to be resizable and to send a 
RFB request to the server to resize the framebuffer when it does so. I've 
implemented a new extension to the RFB protocol to allow the client to 
request desktop resizes.

I hope to release my initial patches early next week, so I'll keep you in the 
loop if you want.



George Wright,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
URL: <>

More information about the xorg mailing list