xpra icon
Bug tracker and wiki

This bug tracker and wiki are being discontinued
please use https://github.com/Xpra-org/xpra instead.

Version 15 (modified by Antoine Martin, 8 years ago) (diff)

add OpenCL-Intel on dual Xeon+K1

Colourspace conversion step - CSC

Before passing the pixels to the video encoder, we may or may not include a colourspace conversion step. (some newer versions of x264 support BGRA pixels as input directly)

Information and Diagnostics

The pixel format used as input as well as the CSC module chosen to do this conversion work can be found via "xpra info". These should be chosen automatically based on the desired speed/quality settings. Note that the CSC step may degrade the quality of the picture (YUV444P mode does not, but YUV422P and YUV420P do).

CSC Modules

On the server side we currently support three modules for doing this step:

See below for some performance samples.

On the client side, if a CSC step is needed, it will use swscale. The OpenGL mode does not need a CSC step as it can display YUV pixels directly on screen.


As part of the colourspace conversion step, we can also downscale the frame if the XPRA_SCALING environment variable is unset or set to "1", and either:

  • the application requests scaling using the _XPRA_SCALING X11 window property (specified as a 32-bit fraction, 16-bits for each)
  • the XPRA_SCALING_HARDCODED environment variable is set on the server, using one of those 2 forms (the second one is preferred):
    • XPRA_SCALING_HARDCODED=N to downscale by N
    • XPRA_SCALING_HARDCODED=M:N to downscale by the fraction M/N
  • automatically, if the frame size is bigger than 1MPixels and the quality is low whilst the speed is high

Note: if the automatic heuristics turn on frame downscaling, this may introduce a colourspace conversion step where none was necessary before (when the encoder was previously handling RGB directly).

CSC Performance

You can get your own figures by running the tests:

Measured with r4272 (results are in MPixels/s):

  • 1920x1080 RGB to YUV???P:
Module CPU/GPU YUV420P YUV422P YUV444P
swscaleIntel Core i3164229181
swscaleAMD 945120165131
swscale2xIntel Xeon E5-2670 / 2xK1215322253
CUDA-NVidiaAMD 945 + GTS 450366341290
CUDA-NVidia2xIntel Xeon E5-2670 / 2xK1173177160
OpenCL-NVidiaAMD 945 + GTS 450357303260
OpenCL-NVidia2xIntel Xeon E5-2670 / 2xK1210211192
OpenCL-IntelIntel Core i31419253
OpenCL-Intel2xIntel Xeon E5-2670 / 2xK1472412263
OpenCL-AMDAMD 945635453
OpenCL-AMDIntel Core i3715863
  • 1920x1080 RGB to GBR (simple byte swapping):
Module CPU/GPU MPixels/s
swscaleAMD 945524
swscaleIntel Core i3550
swscale2xIntel Xeon E5-2670 / 2xK1758
  • 1920x1080 YUV???P to BGR(X):
Module CPU/GPU YUV420P YUV422P YUV444P
swscaleIntel Core i3350309310
swscaleAMD 945369323237
swscale2xIntel Xeon E5-2670 / 2xK1177168163
CUDA-NVidiaAMD 945 + GTS 450202191180
CUDA-NVidia2xIntel Xeon E5-2670 / 2xK1180155151
OpenCL-NVidiaAMD 945 + GTS 450473476349
OpenCL-NVidia2xIntel Xeon E5-2670 / 2xK1190165148
OpenCL-IntelIntel Core i3828887
OpenCL-Intel2xIntel Xeon E5-2670 / 2xK1265271268
OpenCL-AMDAMD 945545150
OpenCL-AMDIntel Core i3605658