Xpra: Ticket #365: don't copy pixmap data to ram: avoid the round-trips and stay on the GPU if we can

EXT_texture_from_pixmap should allow us to use the pixels on the GPU for doing CSC and/or encoding without first needing to copy them to RAM (via XShmGetImage or XGetImage as we do now)


XShmGetImage is pretty fast but then we have to upload the data again to the graphics card (assuming we do csc on the GPU - which is the fastest option) and then download the results. Quite wasteful, especially at high res.



Thu, 12 Dec 2013 06:37:23 GMT - Antoine Martin: owner, status, milestone changed

Here's how I think this can work. Note: it might be easier to test this using "xpra shadow" and a full display copy since the "root window" never goes away, and we already have code to override behaviour for the root window (see GTKRootWindowModel).



Obviously, we'll also need fallback code for dealing with non-nvenc encoders, and lots of other little details I can't foresee..


Links:


Tue, 19 Aug 2014 04:13:07 GMT - Antoine Martin: milestone changed

Scheduling for 0.16


Tue, 19 Aug 2014 10:00:55 GMT - Antoine Martin:

Another API we could potentially use (maybe just on win32?) is NvIFROpenGL, for which there is zero documentation... Only this entry in the 319.49 driver changelog: Added the NVIDIA OpenGL-based Inband Frame Readback (NvIFROpenGL) library to the Linux driver package. This library provides a high performance, low latency interface to capture and optionally encode an individual OpenGL framebuffer. NvIFROpenGL captures pixels rendered by OpenGL only and is ideally suited to application capture and remoting.

Although DRC seems to think it's not worth it: I determined that the IFR stuff is not any faster than using PBOs


Fri, 23 Oct 2015 07:04:45 GMT - Antoine Martin: milestone changed

Re-scheduling.


Wed, 16 Mar 2016 05:28:09 GMT - Antoine Martin: milestone changed


Tue, 12 Jul 2016 16:51:50 GMT - Antoine Martin: milestone changed

Milestone renamed


Sun, 21 Aug 2016 09:55:49 GMT - Antoine Martin: milestone changed

Milestone renamed


Tue, 27 Sep 2016 09:41:16 GMT - Antoine Martin:

For win32 we now have an API we can use #1317 "nvidia capture sdk support"


Sun, 19 Feb 2017 06:29:14 GMT - Antoine Martin: milestone changed


Fri, 28 Apr 2017 04:54:49 GMT - Antoine Martin: milestone changed


Sun, 18 Jun 2017 13:34:52 GMT - Antoine Martin:

See ticket:1552#comment:1.


Sat, 22 Jul 2017 13:10:21 GMT - Antoine Martin: milestone changed

Boom! Done for NVFBC (#1317) + NVENC v8 (#1552) in r16458! Improved in r16459, made the default in r16476.

Still TODO:


Sun, 23 Jul 2017 13:23:12 GMT - Antoine Martin: status changed; resolution set

Will follow up in #1597. Closing at last!


Mon, 24 Jul 2017 13:13:39 GMT - Antoine Martin:

Also done for Linux in r16492: needed new NVENC kernels as Linux uses a different pixel format (XRGB vs BGRX).


Mon, 05 Feb 2018 03:47:38 GMT - Antoine Martin:

Regression: #1763


Sat, 23 Jan 2021 04:52:52 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/365