From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 926EB49519 for ; Wed, 13 Mar 2024 19:14:00 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 5E4E168CF01; Wed, 13 Mar 2024 21:13:56 +0200 (EET) Received: from btbn.de (btbn.de [144.76.60.213]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6DFA468CAF7 for ; Wed, 13 Mar 2024 21:13:50 +0200 (EET) Received: from [authenticated] by btbn.de (Postfix) with ESMTPSA id 478DA28A8E33E; Wed, 13 Mar 2024 20:13:49 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rothenpieler.org; s=mail; t=1710357229; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=YD/1dvgU32kwn0htzgOYjGhUSTdwAY/htYNBygUmRqI=; b=C7Zzn3E7zZ0jmYKulzta2Rp7ymrGDEFU0SIeftyLuRjN4LLZYynyMOwJcxIikYOwGyabsf n4QSN+fYdzM5e4mxmFXeTLYYMU92/ZAWBW2eihh7mKpvX7a54ViTLy0IPABZCFarKZ32w0 O3hGv8OsMZEAhiO8nioklxJk0wV/c/Fqe/lqRqthcebVqHckgi0OesM4e3ophacCtxxSwA UsP9wnyZMt41w0JBhZ+nUFgs9eO7iFpRONbyj8kHs54+Dm0G68kZxMD4q3lT6GJNp5ty2I NRs/fsw0klHWSFzWYCCfUBYQ3mGjb0ublO5f3KsukHyzLGqahN6iB2YwE+QaAQ== From: Timo Rothenpieler To: ffmpeg-devel@ffmpeg.org Date: Wed, 13 Mar 2024 20:13:41 +0100 Message-Id: <20240313191341.12479-1-timo@rothenpieler.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH] avutil/hwcontext_d3d11va: prefer DXGI 1.1 factory when available X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Timo Rothenpieler Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: A lot of modern stuff straight up fails on the old 1.0 factory, which is masked by the fact that it's only used when an explicit adapter is specified. --- libavutil/hwcontext_d3d11va.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavutil/hwcontext_d3d11va.c b/libavutil/hwcontext_d3d11va.c index 24b3546e7b..cf793a2f48 100644 --- a/libavutil/hwcontext_d3d11va.c +++ b/libavutil/hwcontext_d3d11va.c @@ -62,7 +62,9 @@ static av_cold void load_functions(void) return; mD3D11CreateDevice = (PFN_D3D11_CREATE_DEVICE) GetProcAddress(d3dlib, "D3D11CreateDevice"); - mCreateDXGIFactory = (PFN_CREATE_DXGI_FACTORY) GetProcAddress(dxgilib, "CreateDXGIFactory"); + mCreateDXGIFactory = (PFN_CREATE_DXGI_FACTORY) GetProcAddress(dxgilib, "CreateDXGIFactory1"); + if (!mCreateDXGIFactory) + mCreateDXGIFactory = (PFN_CREATE_DXGI_FACTORY) GetProcAddress(dxgilib, "CreateDXGIFactory"); #else // In UWP (which lacks LoadLibrary), CreateDXGIFactory isn't available, // only CreateDXGIFactory1 -- 2.34.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".