From patchwork Mon Apr 19 14:09:21 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Almer X-Patchwork-Id: 27014 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:5014:0:0:0:0:0 with SMTP id e20csp557120iob; Mon, 19 Apr 2021 07:13:24 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyuuEBbXxM0nC5z3WWr+Muu+xUOjO+4CoepTPOGz88bQzpZohxQib2bDcL14W/fpr35rICv X-Received: by 2002:a17:907:98ae:: with SMTP id ju14mr22806771ejc.287.1618841604499; Mon, 19 Apr 2021 07:13:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618841604; cv=none; d=google.com; s=arc-20160816; b=Rj+SvVL6WhJuMjowpVOb6jfP9BiXXYHmPf4ZYGmcleEeCyxhtLTshFF0TsKvOdaetn fsuIE+nLAl1WwvLV9TDvjsT4SF03x5KIWbluWApIiggayFErKGd8K20otN1PaYxBuY54 OpzGt0HqSecxgzTp3Zbw9tnM/VzmBAZl3GWXXEgLLLb+lSVfJV8acpmKnfk/M9Fz84Eo PmZH2fnkVWHdv6Gcy25exFOILFwL2+NrKqhy+aYyZT+yrw0zDZNt5AAtqSPCppZz4r0F qmQWVRJX3qgjRFiEeZ2mlArvp4ax76UKQ6Um+xDPYFNcfzGCZrtzAP6wXtZi18gZvURP Klqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:reply-to:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:subject:mime-version:references:in-reply-to:message-id :date:to:from:dkim-signature:delivered-to; bh=QfzxAkove/AStZuvQW/cYqKN2XuAL1EuyyuPANfS/Ok=; b=fkvdVZ6QyZxvLOZ2CjWXJylyKRdcKjv/NNRBtYWvOV8hM4CELFmAEPdzZsTsmvVBKf g7SoEr7CDsXki/v7+SoZX3KDHVLDF/baUAOyEirNI+yqY+EAntChqdT3g+KOpJGoTg9n TMLUZr/TbtRsIc8SZm4hxsEm2wHrFW/CP4LHxCNgd1ZVUKhmOZI3cLSgXe6g0CKIisxu +rn8OwsEnUqc6mABWCYdcGc9KiQ8KEs7itP/haPBCI5Hoo/CmgfatNXaIubBTimhdIso dWSH8e2p6xHbCrG+rWVbccEzrWhihfw3J/+vvM17V0Ot5XP4gLPDeT/TifRoRqtNnC/E qzKg== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=OaNwv0g9; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id m11si10697219edq.183.2021.04.19.07.13.24; Mon, 19 Apr 2021 07:13:24 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=OaNwv0g9; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A5139680C78; Mon, 19 Apr 2021 17:11:34 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-qv1-f54.google.com (mail-qv1-f54.google.com [209.85.219.54]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 9CF60680C47 for ; Mon, 19 Apr 2021 17:11:32 +0300 (EEST) Received: by mail-qv1-f54.google.com with SMTP id ef17so11259008qvb.0 for ; Mon, 19 Apr 2021 07:11:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=ZiDpdVp+OeaSpkm+OjcP+ZRLXTgaDvAn0OtraXPpUIo=; b=OaNwv0g9qbRaJO/7TF4SiXJR21m4yBsCt8IendiohDP+lN2qcHumLfoaqEKNxXGgXG QLyGRxSJZUX+hoChdUaR8oFhXX+yokhkhTT/WGnllin3lofwhXYeWEUsAZl0WB5mdq01 2pFgp2erSnb1nrvwMdgmvzXgeEyIigt2KLqFpI5zOctrBYvzrX8EEey61kowzT0geLPW jvkJX6b6Nei4+CWCFBNX9ohSqR09Ec2trBCarn1z97iTsFFf8N293pvGSnKIr54cocb0 hlWWESvP22WtVf4pHd3MCLorqkxRbChFRa0Qf4hiaXrib3snpx7kmy5D676P1Eiz+bDZ SGRg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZiDpdVp+OeaSpkm+OjcP+ZRLXTgaDvAn0OtraXPpUIo=; b=jqadSiB1ihUoCE+TRQMxVGZ3AliykDe79FBrFyx+vE3hrvqnWLFEcbGJ5YYC5k6qxq CPV80BZrWScSEAXFdg2xrjzjj7gBMCRJ2ahDwnfCl5I8aQHLUXdCs4/YD+2Sh9Hv4xt/ lYjFBbG9WHlXJheyXF8qdL+NXriE0N1lqKiUy9FKI9/KdE9gmS4TfIS9hlSFGCR9rHxe VZ3l37ui9FW2RN3tHdMxugd9rfKJMvdrCQfz4dJ2S7t71df6iLOqYo48wuu2mrfgic25 TBaHfou/4EA1Eb0Q4U46Z8l0sf3JXUDQRJmBhOB8Z7pcwvEM6Ir1/+TPM8sC+8t9MP5+ e7jw== X-Gm-Message-State: AOAM532HE0EvnJBLAdQwj3iUvpQORJeygj+5p3dEIdxcJD4Nedbhx0eo 34QlOOkah3qviFK2d0WXuLKkOBxGAwg= X-Received: by 2002:a0c:c488:: with SMTP id u8mr21275869qvi.47.1618841490976; Mon, 19 Apr 2021 07:11:30 -0700 (PDT) Received: from localhost.localdomain ([191.83.209.133]) by smtp.gmail.com with ESMTPSA id f7sm2049494qtv.53.2021.04.19.07.11.29 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Apr 2021 07:11:30 -0700 (PDT) From: James Almer To: ffmpeg-devel@ffmpeg.org Date: Mon, 19 Apr 2021 11:09:21 -0300 Message-Id: <20210419141024.8174-25-jamrial@gmail.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210419141024.8174-1-jamrial@gmail.com> References: <20210419141024.8174-1-jamrial@gmail.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 24/87] avcodec/vdpau: Remove deprecated av_vdpau_get_profile 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 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 1IIT33PONYmA From: Andreas Rheinhardt Deprecated in b10b6ac7a902f28e09e37a29c392e2f0c19e9526. Signed-off-by: Andreas Rheinhardt --- libavcodec/vdpau.c | 49 -------------------------------------------- libavcodec/vdpau.h | 19 ----------------- libavcodec/version.h | 3 --- 3 files changed, 71 deletions(-) diff --git a/libavcodec/vdpau.c b/libavcodec/vdpau.c index fa10905c75..f20dbd78e2 100644 --- a/libavcodec/vdpau.c +++ b/libavcodec/vdpau.c @@ -397,55 +397,6 @@ int ff_vdpau_add_buffer(struct vdpau_picture_context *pic_ctx, return 0; } -#if FF_API_VDPAU_PROFILE -int av_vdpau_get_profile(AVCodecContext *avctx, VdpDecoderProfile *profile) -{ -#define PROFILE(prof) \ -do { \ - *profile = VDP_DECODER_PROFILE_##prof; \ - return 0; \ -} while (0) - - switch (avctx->codec_id) { - case AV_CODEC_ID_MPEG1VIDEO: PROFILE(MPEG1); - case AV_CODEC_ID_MPEG2VIDEO: - switch (avctx->profile) { - case FF_PROFILE_MPEG2_MAIN: PROFILE(MPEG2_MAIN); - case FF_PROFILE_MPEG2_SIMPLE: PROFILE(MPEG2_SIMPLE); - default: return AVERROR(EINVAL); - } - case AV_CODEC_ID_H263: PROFILE(MPEG4_PART2_ASP); - case AV_CODEC_ID_MPEG4: - switch (avctx->profile) { - case FF_PROFILE_MPEG4_SIMPLE: PROFILE(MPEG4_PART2_SP); - case FF_PROFILE_MPEG4_ADVANCED_SIMPLE: PROFILE(MPEG4_PART2_ASP); - default: return AVERROR(EINVAL); - } - case AV_CODEC_ID_H264: - switch (avctx->profile & ~FF_PROFILE_H264_INTRA) { - case FF_PROFILE_H264_BASELINE: PROFILE(H264_BASELINE); - case FF_PROFILE_H264_CONSTRAINED_BASELINE: - case FF_PROFILE_H264_MAIN: PROFILE(H264_MAIN); - case FF_PROFILE_H264_HIGH: PROFILE(H264_HIGH); -#ifdef VDP_DECODER_PROFILE_H264_EXTENDED - case FF_PROFILE_H264_EXTENDED: PROFILE(H264_EXTENDED); -#endif - default: return AVERROR(EINVAL); - } - case AV_CODEC_ID_WMV3: - case AV_CODEC_ID_VC1: - switch (avctx->profile) { - case FF_PROFILE_VC1_SIMPLE: PROFILE(VC1_SIMPLE); - case FF_PROFILE_VC1_MAIN: PROFILE(VC1_MAIN); - case FF_PROFILE_VC1_ADVANCED: PROFILE(VC1_ADVANCED); - default: return AVERROR(EINVAL); - } - } - return AVERROR(EINVAL); -#undef PROFILE -} -#endif /* FF_API_VDPAU_PROFILE */ - AVVDPAUContext *av_vdpau_alloc_context(void) { return av_mallocz(sizeof(VDPAUHWContext)); diff --git a/libavcodec/vdpau.h b/libavcodec/vdpau.h index 4d99943369..3010094d93 100644 --- a/libavcodec/vdpau.h +++ b/libavcodec/vdpau.h @@ -55,7 +55,6 @@ #include "libavutil/attributes.h" #include "avcodec.h" -#include "version.h" struct AVCodecContext; struct AVFrame; @@ -153,24 +152,6 @@ int av_vdpau_get_surface_parameters(AVCodecContext *avctx, VdpChromaType *type, */ AVVDPAUContext *av_vdpau_alloc_context(void); -#if FF_API_VDPAU_PROFILE -/** - * Get a decoder profile that should be used for initializing a VDPAU decoder. - * Should be called from the AVCodecContext.get_format() callback. - * - * @deprecated Use av_vdpau_bind_context() instead. - * - * @param avctx the codec context being used for decoding the stream - * @param profile a pointer into which the result will be written on success. - * The contents of profile are undefined if this function returns - * an error. - * - * @return 0 on success (non-negative), a negative AVERROR on failure. - */ -attribute_deprecated -int av_vdpau_get_profile(AVCodecContext *avctx, VdpDecoderProfile *profile); -#endif - /* @}*/ #endif /* AVCODEC_VDPAU_H */ diff --git a/libavcodec/version.h b/libavcodec/version.h index 4c1c4b257e..a785e18c9e 100644 --- a/libavcodec/version.h +++ b/libavcodec/version.h @@ -54,9 +54,6 @@ #ifndef FF_API_CODED_FRAME #define FF_API_CODED_FRAME (LIBAVCODEC_VERSION_MAJOR < 59) #endif -#ifndef FF_API_VDPAU_PROFILE -#define FF_API_VDPAU_PROFILE (LIBAVCODEC_VERSION_MAJOR < 59) -#endif #ifndef FF_API_AVPICTURE #define FF_API_AVPICTURE (LIBAVCODEC_VERSION_MAJOR < 59) #endif