We recommend a three phase implementation strategy, based on how an application could be written to take advantage of scaling:
The XCopyAreaScaled extension should be implemented, since this is the ideal solution for applications like VNC, and since making use of this extension will require minimal changes to applications that already use XPutImage or XCopyArea.
The initial implementation work would include the design of the X protocol extension, writing this up in the usual format for extension documentation, implementation of the protocol transport pieces in XFree86, implementation of a software fall-back in XFree86 and DMX, one example hardware implementation for XFree86, and implementation of support for this extension in DMX.
We suggest implementing the extension first on the ATI Radeon cards. However, since these cards do not provide a 2D scaled blit primitive, the implementation would have to make use of the 3D texture engine to emulate a scaled blit. This is recommended, since other modern graphics cards also do not provide a simple 2D scaled blit operation and an example of the more difficult implementation pathway would be helpful to others.
Until XCopyAreaScaled is widely supported, applications that require scaling will have to fall back to another scaling method. We suggest OpenGL as the first fall-back method because it is widely available and supported by DMX.
A project centered around OpenGL-based scaling would
implement this scaling in VNC as an example. This work
would include re-writing the vncviewer
rendering engine to cache a master copy of the desktop
image for all operations.
Since OpenGL is not implemented everywhere, and may not provide hardware-assisted performance in every implementation, an application that requires scaling should also fall back to using the X Video Extension.
This project would add support for the X Video Extension
to DMX and would add support to VNC to take advantage of
this extension without introducing artifacts. This
would require modifying the vncviewer
rendering
engine to cache a master copy of the desktop image for
all operations. This project should also add support
for the RGB format to at least one XFree86 driver (e.g.,
ATI Radeon).
The X Video Extension is one of the few popular extensions that DMX does not support. We recommend implementing the X Video Extension even if scaling is the specific goal of that work.
We do not recommend implementation of the XCreateScaledWindow extension because of the complexity involved. We do not recommend implementation of the XPutImageScaled extension because it requires the same amount of work as the XCopyAreaScaled extension, but provides less functionality. Further, server-side scaling with a large frame buffer is not recommended because of the performance implications.
The back-end scaling, especially with disconnect/reconnect support should be explored in the future after disconnect/reconnect is implemented, but not at the present time.