Cause a window to display content visible on another display
#include <screen/screen.h>
int screen_share_display_buffers(screen_window_t win, screen_display_t share, int count)
Function Type: Flushing Execution
This function creates a count number of buffers with the size defined by the SCREEN_PROPERTY_BUFFER_SIZE window property of win. These buffers are rendered by Screen. The display is used to generate content for the (window) buffers. Once there is a post for the window win, the content of the buffers is displayed on the display share. To share display buffers, you need to be working within a privileged context. Therefore, a context that was created with the type SCREEN_DISPLAY_MANAGER_CONTEXT must be used.
If the display has a framebuffer, then screen_share_display_buffers() is similar to screen_share_window_buffers().
0 if successful, or -1 if an error occurred (errno is set; refer to errno.h for more details).