From c257b8a909f04ede65d79b09ca8c0ac452825f1a Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 22 Jul 2024 05:10:39 +0200 Subject: Use modifiers in kms capture on amd too --- src/capture/kms.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/capture/kms.c b/src/capture/kms.c index 16d7254..7fa69c6 100644 --- a/src/capture/kms.c +++ b/src/capture/kms.c @@ -311,7 +311,6 @@ static bool is_plane_compressed(uint64_t modifier) { static int gsr_capture_kms_capture(gsr_capture *cap, AVStream *video_stream, AVFrame *frame, gsr_color_conversion *color_conversion) { gsr_capture_kms *self = cap->priv; - const bool screen_plane_use_modifiers = self->params.egl->gpu_info.vendor != GSR_GPU_VENDOR_AMD; const bool cursor_texture_id_is_external = self->params.egl->gpu_info.vendor == GSR_GPU_VENDOR_NVIDIA; //egl->glClearColor(0.0f, 0.0f, 0.0f, 1.0f); @@ -402,7 +401,7 @@ static int gsr_capture_kms_capture(gsr_capture *cap, AVStream *video_stream, AVF intptr_t img_attr[44]; setup_dma_buf_attrs(img_attr, drm_fd->pixel_format, drm_fd->width, drm_fd->height, - fds, offsets, pitches, modifiers, drm_fd->num_dma_bufs, screen_plane_use_modifiers); + fds, offsets, pitches, modifiers, drm_fd->num_dma_bufs, true); EGLImage image = self->params.egl->eglCreateImage(self->params.egl->egl_display, 0, EGL_LINUX_DMA_BUF_EXT, NULL, img_attr); self->params.egl->glBindTexture(GL_TEXTURE_2D, self->input_texture_id); -- cgit v1.2.3