mirror of
				https://github.com/libsdl-org/SDL.git
				synced 2025-11-04 01:34:38 +00:00 
			
		
		
		
	wayland: Note that setting the damage region in the frame callback is explicitly to work around a driver bug
This commit is contained in:
		@@ -637,9 +637,9 @@ static void surface_frame_done(void *data, struct wl_callback *cb, uint32_t time
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
    SDL_WindowData *wind = (SDL_WindowData *)data;
 | 
					    SDL_WindowData *wind = (SDL_WindowData *)data;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*
 | 
					    /* XXX: This is needed to work around an Nvidia egl-wayland bug due to buffer coordinates
 | 
				
			||||||
     * wl_surface.damage_buffer is the preferred method of setting the damage region
 | 
					     *      being used with wl_surface_damage, which causes part of the output to not be
 | 
				
			||||||
     * on compositor version 4 and above.
 | 
					     *      updated when using a viewport with an output region larger than the source region.
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    if (wl_compositor_get_version(wind->waylandData->compositor) >= WL_SURFACE_DAMAGE_BUFFER_SINCE_VERSION) {
 | 
					    if (wl_compositor_get_version(wind->waylandData->compositor) >= WL_SURFACE_DAMAGE_BUFFER_SINCE_VERSION) {
 | 
				
			||||||
        wl_surface_damage_buffer(wind->surface, 0, 0, SDL_MAX_SINT32, SDL_MAX_SINT32);
 | 
					        wl_surface_damage_buffer(wind->surface, 0, 0, SDL_MAX_SINT32, SDL_MAX_SINT32);
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user