Vladimir, As Peter pointed out to me you were speaking of a video card with built-in capture. This _does_ require, as you stated a way to get the video, out of the video ram and into system ram, my apologies for the misunderstanding.
My point should still hold. The DRM should allow you to map an video area into a client accessible memory location. Your client could then read directly from the video memory and output the result to disk. This would require some sort of synchronization to make sure you are not reading a buffer that is being updated. If the DMA copy from the Video card to system memory is very fast compared to the PCI read then you wouldn't want this anyway, perhaps you already know the answer to this and that's why you want to drmAddMap()/drmMap() system memory which I don't think is possible. Couldn't you just use a shared memory area? For what it is worth my thought was something like this: Without capture: Allocate video memory for frames Set the capture to use this video memory (either a separate card or an on-chip capture) Set the overlay display hardware to display these buffers. With Capture: Allocate video memory for frames Set the capture to use this video memory Use the DRM to map these into client memory After a frame is captured the client reads the data and stores it to disk. The client then does an XvMCPutSurface to display the frame on the overlay, since it is already in Video memory no copy is needed. Again, some sync between the frame reading and the capture would have to be done. For cc then you could just write to the cc area of the frame. This all comes down to how bad the mmap'd read is compared to a DMA write from the Video card to system memory plus the extra read from the system memory in order to write it to disk. _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
