From patchwork Thu Oct 10 02:58:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: martin schitter X-Patchwork-Id: 52177 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a59:ac52:0:b0:48e:c0f8:d0de with SMTP id x18csp80927vqg; Wed, 9 Oct 2024 20:09:02 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXIvMavbqQNzD6JQfhv615dnf/BMPOoSMs/po2KIF5dPYliwwX3EDcfFE34Yvkvd5fDM6o9Ld+HhKffVPvzgNAT@gmail.com X-Google-Smtp-Source: AGHT+IEcojcRCYtnGrV8JtOaptWhuyBbje2yzup8MA0CE+Y0/wt380LxoDkQUqURjszYdv7Y/pLZ X-Received: by 2002:a2e:71a:0:b0:2ef:24a0:c176 with SMTP id 38308e7fff4ca-2fb187bd59bmr21489161fa.28.1728529742247; Wed, 09 Oct 2024 20:09:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1728529742; cv=none; d=google.com; s=arc-20240605; b=b+qrm525ggOP9G46x1RuSc/skjpD4Se/q65/bkGske2u33iKAssJvb8TRP1kXvkK6b ThY+ZyPnKRq91DE367DFyal0z8Nc8y+mE8/IF4W2d/DR06g3xg4amNkl165f8nf5ZF10 gdevrexxnX0Kc7Z4Ry8vfnnOprdVtKcSzLndjldC+7qxdkJ1lAoelGUri1Za5TjKAjXt g9YBxH05YiWt4fWMMfq8SO6i2xHNTEjJIlfLQwn7UHxnsGHEktcwOPzn+ktzaWIn1jjF nsziizoBiiaQtIm8W2tYEqek/j2sJwzH+brrjU8iqSi0RNMhYZJJT+Vxtiw5Wsy1R5yN T+Qw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:content-transfer-encoding:cc: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=EycSMiFWvzzc7xm/55o+NDBOBo8Mm1WzMv9p0Ooni9I=; fh=SY+A8HDvCKivsvOlugO0byaDvZLxc2A9PIXlqXmaPLE=; b=OggTgyOrB+48fkm3KcTrcM07X00vHej9k1iXUIt0Uwpa/0KEHV6Fgh+q7q1AVMIdpJ VbqcVawbAvWtQnYOzsJ5sumwD1C6z8bupb6fJKggRNf+JZKXjvohsJ25XojzGZqOx6td OsQNx5zxvo8BnQFQwkMfU4x0Hcp8HIh2hM2YDtpmLwPGPORTt2M+FBO7fpQI8C4T9HVG PJxS5wHj1jCPes5rc+CvSxeEhPJhzYDhvpXdi5XFtU5ivCUfz2qPQoz2Z37YtRvduEP+ ASiZ/Sg/Du55sKNLkwXs9D/7RmgZOTsOJ0cLmPdjWIXQiBR0zBwgazs8BJPNVl08OCIY Ituw==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@mur.at header.s=dkim2 header.b=hrNCHeHk; 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=NONE dis=NONE) header.from=mur.at Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id 38308e7fff4ca-2fb24783675si680391fa.645.2024.10.09.20.09.01; Wed, 09 Oct 2024 20:09:02 -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=@mur.at header.s=dkim2 header.b=hrNCHeHk; 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=NONE dis=NONE) header.from=mur.at Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 41BEC68DE86; Thu, 10 Oct 2024 06:08:35 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from efeu.mur.at (efeu.mur.at [89.106.208.42]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6B16068DE50 for ; Thu, 10 Oct 2024 06:08:24 +0300 (EEST) Received: from localhost.localdomain (lan1.raspi.ma39.ffgraz.net [10.12.1.243]) by efeu.mur.at (Postfix) with ESMTPSA id BD3984635A; Thu, 10 Oct 2024 05:08:23 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mur.at; s=dkim2; t=1728529703; bh=GiTgGhCQueljnK4x4aSfm6fQlJNo5JqU6st5WCagSpU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hrNCHeHkGBJGKrGDgbvwTKMhLsunufbkGI4S8j2e0dVmHylMTuN5Hgx0IpDlK5jAm li6pVmF2hQswaS0vFXr7eiHz7jFi0vchpSdajOYLhSh91hD6Az8izInrQlc4RDvVfJ wuND22JA0jZy6fWHI+daDUAJejFFR/ZaANkea/c354O7iJvE4INwPiUFaU+whn53Ra kIgkdyC5GfEUV9spxq+undPQo87snXoMpgLy82XW4x8tMfp0W1IjtXxfd1D5fwaPfX LtKneTc37KZCh/+N7Sxr4slUgOIZMCDReJbvWLxR1jWTudSadOQmtxNhutZfhtbwEd bi8CtsmnC12jJeck4X9cWpN3ck7yUSUMUZWg6Og38zcqSqx2LhraqY6D2CbPpP5XFa rIGSZDsnJcpwONVE1D75BytG/9joeSsRvPKLnXF2MTHk1HJW6vEkEr9qlTvGK0z4u/ Tt9cv8d/VfVxZ6qidBXicoq1BLFkE1SaebOBdOUljQgkQdKCpDF From: Martin Schitter To: ffmpeg-devel@ffmpeg.org Date: Thu, 10 Oct 2024 04:58:40 +0200 Message-ID: <20241010025841.531321-3-ms+git@mur.at> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241010025841.531321-2-ms+git@mur.at> References: <20241010025841.531321-2-ms+git@mur.at> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v11 1/3] libavcodec/dnxucdec: DNxUncompressed decoder 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: michael@niedermayer.cc, Martin Schitter Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: w7ctZYqpdiem --- libavcodec/Makefile | 1 + libavcodec/allcodecs.c | 1 + libavcodec/dnxucdec.c | 385 +++++++++++++++++++++++++++++++++++++++++ 3 files changed, 387 insertions(+) create mode 100644 libavcodec/dnxucdec.c diff --git a/libavcodec/Makefile b/libavcodec/Makefile index 5df4b7c..90ee089 100644 --- a/libavcodec/Makefile +++ b/libavcodec/Makefile @@ -327,6 +327,7 @@ OBJS-$(CONFIG_DFPWM_DECODER) += dfpwmdec.o OBJS-$(CONFIG_DFPWM_ENCODER) += dfpwmenc.o OBJS-$(CONFIG_DNXHD_DECODER) += dnxhddec.o dnxhddata.o OBJS-$(CONFIG_DNXHD_ENCODER) += dnxhdenc.o dnxhddata.o +OBJS-$(CONFIG_DNXUC_DECODER) += dnxucdec.o OBJS-$(CONFIG_DOLBY_E_DECODER) += dolby_e.o dolby_e_parse.o kbdwin.o OBJS-$(CONFIG_DPX_DECODER) += dpx.o OBJS-$(CONFIG_DPX_ENCODER) += dpxenc.o diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c index f531761..dcb2545 100644 --- a/libavcodec/allcodecs.c +++ b/libavcodec/allcodecs.c @@ -93,6 +93,7 @@ extern const FFCodec ff_dfa_decoder; extern const FFCodec ff_dirac_decoder; extern const FFCodec ff_dnxhd_encoder; extern const FFCodec ff_dnxhd_decoder; +extern const FFCodec ff_dnxuc_decoder; extern const FFCodec ff_dpx_encoder; extern const FFCodec ff_dpx_decoder; extern const FFCodec ff_dsicinvideo_decoder; diff --git a/libavcodec/dnxucdec.c b/libavcodec/dnxucdec.c new file mode 100644 index 0000000..d2c27db --- /dev/null +++ b/libavcodec/dnxucdec.c @@ -0,0 +1,385 @@ +/* + * Avid DNxUncomressed / SMPTE RDD 50 decoder + * Copyright (c) 2024 Martin Schitter + * + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * FFmpeg is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with FFmpeg; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + +/* + This decoder for DNxUncompressed video data is mostly based on + reverse engineering of output generated by DaVinci Resolve 19 + but was later also checked against the SMPTE RDD 50 specification. + + Not all DNxUncompressed pixel format variants are supported, + but at least an elementary base set is already usable: + + - YUV 4:2:2 8/10/12bit + - RGB 8/10/12bit/half/float + +*/ + +#include "avcodec.h" +#include "codec_internal.h" +#include "decode.h" +#include "libavutil/imgutils.h" +#include "libavutil/intreadwrite.h" +#include "thread.h" + +static int pass_though(AVCodecContext *avctx, AVFrame *frame, const AVPacket *avpkt) +{ + /* there is no need to copy as the data already match + * a known pixel format */ + + frame->buf[0] = av_buffer_ref(avpkt->buf); + + if (!frame->buf[0]) { + return AVERROR(ENOMEM); + } + + return av_image_fill_arrays(frame->data, frame->linesize, avpkt->data, + avctx->pix_fmt, avctx->width, avctx->height, 1); +} + +static int float2planes(AVCodecContext *avctx, AVFrame *frame, const AVPacket *pkt) +{ + int lw; + const size_t sof = 4; + + lw = frame->width; + + for(int y = 0; y < frame->height; y++){ + for(int x = 0; x < frame->width; x++){ + memcpy(&frame->data[2][sof*(lw*y + x)], &pkt->data[sof* 3*(lw*y + x)], sof); + memcpy(&frame->data[0][sof*(lw*y + x)], &pkt->data[sof*(3*(lw*y + x) + 1)], sof); + memcpy(&frame->data[1][sof*(lw*y + x)], &pkt->data[sof*(3*(lw*y + x) + 2)], sof); + } + } + return pkt->size; +} + +static int half_add_alpha(AVCodecContext *avctx, AVFrame *frame, const AVPacket *pkt) +{ + /* ffmpeg doesn't provide any Float16 RGB pixel format without alpha channel + * right now. As workaround we simply add an opaque alpha layer. */ + + int lw; + const size_t soh = 2; + const uint16_t opaque = 0x3c00; + + lw = frame->width; + + for(int y = 0; y < frame->height; y++){ + for(int x = 0; x < frame->width; x++){ + memcpy(&frame->data[0][soh*4*(lw*y + x)], &pkt->data[soh*3*(lw*y + x)], soh*3); + AV_WL16(&frame->data[0][soh*(4*(lw*y + x) + 3)], opaque); + } + } + return pkt->size; +} + +/* DNxUncompressed utilizes a very dense bitpack representation of 10bit and 12bit pixel data. + +Lines of Image data, which look like in their ordinary 8bit counterpart, contain the most +significant upper bits of the pixel data. These sections alternate with shorter segments in +which the complementary least significant bits of information get packed in a gapless sequence. + ++----------------------+ +----------------------+ +------------------------+ +----------~ +| 8 m.s.bits of R[1] | | 8 m.s.bits of G[1] | | 8 m.s.bits of B[1] | | msb R[2] ... one line ++----------------------+ +----------------------+ +------------------------+ +----------~ + ++---------------------------------------------------------------+ +-----------~ +| +------------+ +------------+ +------------+ +--------------+ | | +--------~ +| | 2 lsb R[2] | | 2 lsb B[1] | | 2 lsb G[1] | | 2 lsb R[1] | | | | G[3]lsb ... LSB bits for line +| +------------+ +------------+ +------------+ +--------------+ | | +--------~ ++---------------------------- one byte ------------------------ + +-----------~ + +next line of MSB bytes... */ + +static int unpack_rg10(AVCodecContext *avctx, AVFrame *frame, const AVPacket *pkt) +{ + int lw, msp, pack, lsp, p_off; + uint16_t r,g,b; + + lw = frame->width; + + for(int y = 0; y < frame->height; y++){ + for(int x = 0; x < frame->width; x++){ + msp = pkt->data[y*3*(lw + lw/4) + 3*x]; + p_off = y*(3*(lw + lw/4)) + 3*lw + 3*x/4; + pack = pkt->data[p_off]; + lsp = (pack >> (3*x & 0x3)*2) & 0x3; + r = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, "r: %04x, %02x, %02x, %02x, %d\n", + // r, msp, lsp, pack, p_off); + + msp = pkt->data[y*3*(lw + lw/4) + 3*x + 1]; + p_off = y*(3*(lw + lw/4)) + 3*lw + (3*x+1)/4; + pack = pkt->data[p_off]; + lsp = (pack >> ((3*x+1) & 0x3)*2) & 0x3; + g = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, "g: %04x, %02x, %02x, %02x, %d\n", + // g, msp, lsp, pack, p_off); + + msp = pkt->data[y*3*(lw + lw/4) + 3*x + 2]; + p_off = y*(3*(lw + lw/4)) + 3*lw + (3*x+2)/4; + pack = pkt->data[p_off]; + lsp = (pack >> ((3*x+2) & 0x3)*2) & 0x3; + b = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, "b: %04x, %02x, %02x, %02x, %d\n\n", + // b, msp, lsp, pack, p_off); + + AV_WL16(&frame->data[2][2*(y*lw + x)], r); + AV_WL16(&frame->data[0][2*(y*lw + x)], g); + AV_WL16(&frame->data[1][2*(y*lw + x)], b); + } + } + return pkt->size; +} + +static int unpack_rg12(AVCodecContext *avctx, AVFrame *frame, const AVPacket *pkt) +{ + int lw, msp, pack, lsp, p_off; + uint16_t r,g,b; + + lw = frame->width; + + for(int y = 0; y < frame->height; y++){ + for(int x = 0; x < frame->width; x++){ + msp = pkt->data[y*3*(lw + lw/2) + 3*x]; + p_off = y*(3*(lw + lw/2)) + 3*lw + 3*x/2; + pack = pkt->data[p_off]; + lsp = (pack >> (3*x & 0x1)*4) & 0xf; + r = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, "r: %04x, %02x, %02x, %02x, %d\n", + // r, msp, lsp, pack, p_off); + + msp = pkt->data[y*3*(lw + lw/2) + 3*x + 1]; + p_off =y*(3*(lw + lw/2)) + 3*lw + (3*x+1)/2; + pack = pkt->data[p_off]; + lsp = (pack >> ((3*x+1) & 0x1)*4) & 0xf; + g = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, "g: %04x, %02x, %02x, %02x, %d\n", + // g, msp, lsp, pack, p_off); + + msp = pkt->data[y*3*(lw + lw/2) + 3*x + 2]; + p_off = y*(3*(lw + lw/2)) + 3*lw + (3*x+2)/2; + pack = pkt->data[p_off]; + lsp = (pack >> ((3*x+2) & 0x1)*4) & 0xf; + b = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, "b: %04x, %02x, %02x, %02x, %d\n\n", + // b, msp, lsp, pack, p_off); + + AV_WL16(&frame->data[2][2*(y*lw + x)], r); + AV_WL16(&frame->data[0][2*(y*lw + x)], g); + AV_WL16(&frame->data[1][2*(y*lw + x)], b); + } + } + return pkt->size; +} + + +static int unpack_y210(AVCodecContext *avctx, AVFrame *frame, const AVPacket *pkt) +{ + int lw, msp, pack, lsp, p_off; + uint16_t y1, y2, u, v; + + lw = frame->width; + + for(int y = 0; y < frame->height; y++){ + for(int x = 0; x < frame->width; x += 2){ + + p_off = y*(2*(lw + lw/4)) + 2*lw + x/2; + pack = pkt->data[p_off]; + + msp = pkt->data[y*2*(lw + lw/4) + 2*x]; + lsp = pack & 0x3; + u = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, " u: %04x, %02x, %02x, %02x, %d\n", + // u, msp, lsp, pack, p_off); + + msp = pkt->data[y*2*(lw + lw/4) + 2*x + 1]; + lsp = (pack >> 2) & 0x3; + y1 = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, "y1: %04x, %02x, %02x, %02x, %d\n", + // y1, msp, lsp, pack, p_off); + + msp = pkt->data[y*2*(lw + lw/4) + 2*x + 2]; + lsp = (pack >> 4) & 0x3; + v = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, " v: %04x, %02x, %02x, %02x, %d\n", + // v, msp, lsp, pack, p_off); + + msp = pkt->data[y*2*(lw + lw/4) + 2*x + 3]; + lsp = (pack >> 6) & 0x3; + y2 = (msp << 2) + lsp; + // av_log(0, AV_LOG_DEBUG, "y2: %04x, %02x, %02x, %02x, %d\n\n", + // y2, msp, lsp, pack, p_off); + + AV_WL16(&frame->data[0][2*(y*lw + x)], y1); + AV_WL16(&frame->data[0][2*(y*lw + x+1)], y2); + AV_WL16(&frame->data[1][2*(y*lw/2 + x/2)], u); + AV_WL16(&frame->data[2][2*(y*lw/2 + x/2)], v); + } + } + return pkt->size; +} + + +static int unpack_y212(AVCodecContext *avctx, AVFrame *frame, const AVPacket *pkt) +{ + int lw, msp, pack, lsp, p_off; + uint16_t y1, y2, u, v; + + lw = frame->width; + + for(int y = 0; y < frame->height; y++){ + for(int x = 0; x < frame->width; x += 2){ + + p_off = y*(2*(lw + lw/2)) + 2*lw + x; + pack = pkt->data[p_off]; + + msp = pkt->data[y*2*(lw + lw/2) + 2*x]; + lsp = pack & 0xf; + u = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, " u: %04x, %02x, %02x, %02x, %d\n", + // u, msp, lsp, pack, p_off); + + msp = pkt->data[y*2*(lw + lw/2) + 2*x + 1]; + lsp = (pack >> 4) & 0xf; + y1 = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, "y1: %04x, %02x, %02x, %02x, %d\n", + // y1, msp, lsp, pack, p_off); + + p_off = y*(2*(lw + lw/2)) + 2*lw + x+1; + pack = pkt->data[p_off]; + + msp = pkt->data[y*2*(lw + lw/2) + 2*x + 2]; + lsp = pack & 0xf; + v = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, " v: %04x, %02x, %02x, %02x, %d\n", + // v, msp, lsp, pack, p_off); + + msp = pkt->data[y*2*(lw + lw/2) + 2*x + 3]; + lsp = (pack >> 4) & 0xf; + y2 = (msp << 4) + lsp; + // av_log(0, AV_LOG_DEBUG, "y2: %04x, %02x, %02x, %02x, %d\n\n", + // y2, msp, lsp, pack, p_off); + + AV_WL16(&frame->data[0][2*(y*lw + x)], y1); + AV_WL16(&frame->data[0][2*(y*lw + x+1)], y2); + AV_WL16(&frame->data[1][2*(y*lw/2 + x/2)], u); + AV_WL16(&frame->data[2][2*(y*lw/2 + x/2)], v); + } + } + return pkt->size; +} + +static int check_pkt_size(AVCodecContext *avctx, AVPacket *avpkt, int bpp) +{ + int needed = ((avctx->width * bpp + 7) / 8) * avctx->height; + if (avpkt->size < needed){ + av_log(avctx, AV_LOG_ERROR, + "Insufficient size of AVPacket data (pkg size: %d needed: %d)\n", avpkt->size, needed); + return AVERROR_INVALIDDATA; + } + return 0; +} + +static int fmt_frame(AVCodecContext *avctx, AVFrame *frame, AVPacket *avpkt, + enum AVPixelFormat pix_fmt, int src_bpp, + int (*frame_handler)(AVCodecContext *avctx, AVFrame *frame, const AVPacket *avpkt)) +{ + int ret; + avctx->pix_fmt = pix_fmt; + + ret = check_pkt_size(avctx, avpkt, src_bpp); + if (ret) + return ret; + + ret = ff_thread_get_buffer(avctx, frame, 0); + if (ret < 0) + return ret; + + return frame_handler(avctx, frame, avpkt); +} + +static int dnxuc_decode_frame(AVCodecContext *avctx, AVFrame *frame, + int *got_frame, AVPacket *avpkt) +{ + char fourcc_buf[5]; + int ret; + + av_fourcc_make_string(fourcc_buf, avctx->codec_tag); + if ((avctx->width % 2) && ((fourcc_buf[0] == 'y' && fourcc_buf[1] == '2') + ||(fourcc_buf[1] == 'y' && fourcc_buf[2] == '2'))){ + av_log(avctx, AV_LOG_ERROR, + "Image width must be a multiple of 2 for YUV 4:2:2 DNxUncompressed!\n"); + return AVERROR_INVALIDDATA; + } + + switch (avctx->codec_tag) { + case MKTAG('r','g','0','8'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_RGB24, 24, pass_though); + break; + case MKTAG('r','g','1','0'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_GBRP10LE, 30, unpack_rg10); + break; + case MKTAG('r','g','1','2'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_GBRP12LE, 36, unpack_rg12); + break; + case MKTAG(' ','r','g','h'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_RGBAF16LE, 48, half_add_alpha); + break; + case MKTAG(' ','r','g','f'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_GBRPF32LE, 96, float2planes); + break; + + case MKTAG('y','2','0','8'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_UYVY422, 16, pass_though); + break; + case MKTAG('y','2','1','0'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_YUV422P10LE, 20, unpack_y210); + break; + case MKTAG('y','2','1','2'): + ret = fmt_frame(avctx, frame, avpkt, AV_PIX_FMT_YUV422P12LE, 24, unpack_y212); + break; + + default: + av_log(avctx, AV_LOG_ERROR, + "Unsupported DNxUncompressed pixel format variant: '%s'\n", + fourcc_buf); + return AVERROR_PATCHWELCOME; + } + + if (ret < 0) { + av_buffer_unref(&frame->buf[0]); + return ret; + } + + *got_frame = 1; + + return avpkt->size; +} + +const FFCodec ff_dnxuc_decoder = { + .p.name = "dnxuc", + CODEC_LONG_NAME("DNxUncompressed (SMPTE RDD 50)"), + .p.type = AVMEDIA_TYPE_VIDEO, + .p.id = AV_CODEC_ID_DNXUC, + FF_CODEC_DECODE_CB(dnxuc_decode_frame), + .p.capabilities = AV_CODEC_CAP_FRAME_THREADS, +}; From patchwork Thu Oct 10 02:58:41 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: martin schitter X-Patchwork-Id: 52178 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a59:ac52:0:b0:48e:c0f8:d0de with SMTP id x18csp82971vqg; Wed, 9 Oct 2024 20:16:09 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVdZFTLeahr5kGPzLsX5eXHxigebZMX9uXK25rDpot+XoJcTVvoQYmN6KvX02skxgfg0e7vawVrEHWjdvZUU5w5@gmail.com X-Google-Smtp-Source: AGHT+IEjASYND4RlkeaSbzE4djPykfx1QQ8qHZ8Ls+16AdQ88d/EzWR0zmxUYNddQjYXVzt36SnR X-Received: by 2002:a05:6512:238b:b0:52c:adc4:137c with SMTP id 2adb3069b0e04-539c489988emr2901846e87.20.1728530168892; Wed, 09 Oct 2024 20:16:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1728530168; cv=none; d=google.com; s=arc-20240605; b=a55uKpcurV0Ct4p65vY8+OPI3KWHwS08WlvJuU5x5PjZuLPPwIYQ/xKbXCcWmqWkva /rIf1XQ2wuXjXKeN+gdT/niNzd31NttZigIGAv0lOBbfp+TornICXIUUEY9uXbhfALvT xRSOaUYSquFzo6Sa/eyy6qK83uJ43PXa4sNcqu4XeUMdVn46Z5rm3fDm6/YTp5hGNw1p iuEliV8qDD8/tiTSzwyhSgRmvESiVovZW+4ut14H7CbqIQ/6rvcabjWZLnpZ0SnWATyN J0iCiJJpZs66lVkid2MascBf5bChEsp5bhH/rvm96Xga8g3rC938mFGo/LZ1PfECByC7 J+GQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:content-transfer-encoding:cc: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=WKp3iPr/b9Ej94ahA1MrFm/MvSlrRMxPHLxbae36CwU=; fh=SY+A8HDvCKivsvOlugO0byaDvZLxc2A9PIXlqXmaPLE=; b=TGJzsNPOXJgpwFNCS8UX85lkNVvTQTz7xhl5cgqo4r6mdERPQE8lZrYlglFNjWuht7 CREFrH8UavUaJvBeSULa8zcSMtDIaGtHjgGAKV2aKiwdh5u/yoiQ0heK8Z0romFU49YC uVZrE+cNICrUF/XgMUPhcQhoKB5FnJuxliV6ewzE1mAUXZgCK7QI+pghVulf8wuxt1nj JX1ugbUSVhD38JphCVhyDNFaFDNBYo1upf8NdabG40aVumzkkljhgF8F8zYbSG+3n5hA ZmLoD13W2eM/SdwFk7PlB58MQp1gtxTo+1Xr4OZsroz3VaWMqSjpEtMwgXyYGCPhEUdS rKcA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@mur.at header.s=dkim2 header.b=m4KpJLZt; 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=NONE dis=NONE) header.from=mur.at Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id 2adb3069b0e04-539cb6c94dbsi115778e87.148.2024.10.09.20.16.08; Wed, 09 Oct 2024 20:16:08 -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=@mur.at header.s=dkim2 header.b=m4KpJLZt; 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=NONE dis=NONE) header.from=mur.at Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 7092068DE7B; Thu, 10 Oct 2024 06:08:32 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from efeu.mur.at (efeu.mur.at [89.106.208.42]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6E1F768DE6E for ; Thu, 10 Oct 2024 06:08:24 +0300 (EEST) Received: from localhost.localdomain (lan1.raspi.ma39.ffgraz.net [10.12.1.243]) by efeu.mur.at (Postfix) with ESMTPSA id DD4E146374; Thu, 10 Oct 2024 05:08:23 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mur.at; s=dkim2; t=1728529703; bh=YkP6N8TMvaf82hBLWDRmVHh701fymy/CCb5+0AdOxcc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=m4KpJLZtOU2kdyST0UkKu4EDaXzg46NCiIMRIx2CieFehWTnm5UvtIR/Z7IRtMuMN Mj9oCtajguAgXJfRaXE0LGt8jILZCGQOUabff4wY3NXDYRhQVGy4swagdbe1NpWOBR LiOj8c0V8V6R4Pws2DcDCuVElXIElxMj1R5C2Lec3pZ+ksgN6uycGsPMZSR6vOh45t xJCEi6h29FQJ/In+WQ3J97RGp37edcCixi09dfmQSbsMuq4EMNXVKz0E1Hbfb/zpgZ uYemGwIPL/KYzsGfIII038MMLWuPqr653QWrdkVKLQwlYkC7ncLscAwXT+ZWewYLqK L9UO2R2gaYCkSMw0wC4+27+UNe6NDt9lWNe4RJLBzufyMm/70zIovh6nPyP7n7Imxm ov8hzmVDCf0RbdrLLdhqPvZm+HWD3oHMX9+7JgerKHcItuoKbvRx7PNZ5GDi3pPtJc FkkuNMC3ATHGQhfLTFX5ouOuFwnovHu+nI4KbZXeB8cNz54j+VR From: Martin Schitter To: ffmpeg-devel@ffmpeg.org Date: Thu, 10 Oct 2024 04:58:41 +0200 Message-ID: <20241010025841.531321-4-ms+git@mur.at> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241010025841.531321-2-ms+git@mur.at> References: <20241010025841.531321-2-ms+git@mur.at> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v11 2/3] doc: DNxUncompressed Changelog and doc entries 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: michael@niedermayer.cc, Martin Schitter Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: dlvjOn45sIif --- Changelog | 2 ++ doc/general_contents.texi | 1 + 2 files changed, 3 insertions(+) diff --git a/Changelog b/Changelog index 7963e09..75b8e15 100644 --- a/Changelog +++ b/Changelog @@ -3,6 +3,8 @@ releases are sorted from youngest to oldest. version : - yasm support dropped, users need to use nasm +- DNxUncompressed (SMPTE RDD 50) decoder + version 7.1: - Raw Captions with Time (RCWT) closed caption demuxer diff --git a/doc/general_contents.texi b/doc/general_contents.texi index 5980ac6..76e1d34 100644 --- a/doc/general_contents.texi +++ b/doc/general_contents.texi @@ -632,6 +632,7 @@ library: @item raw DFPWM @tab X @tab X @item raw Dirac @tab X @tab X @item raw DNxHD @tab X @tab X +@item raw DNxUncompressed @tab @tab X @item raw DTS @tab X @tab X @item raw DTS-HD @tab @tab X @item raw E-AC-3 @tab X @tab X From patchwork Thu Oct 10 02:58:42 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: martin schitter X-Patchwork-Id: 52181 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a59:ac52:0:b0:48e:c0f8:d0de with SMTP id x18csp126264vqg; Wed, 9 Oct 2024 22:36:09 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCVLOCh6uSfSN/O5qCWZk9UMAI9srw4d/WLYtzLdZeW4xpSX9NnCjhTXk5vmR7nj+1g0rx/TdRkGQ3RzhAB+BxeB@gmail.com X-Google-Smtp-Source: AGHT+IFRqPZMMBAa2PnBkgKqm3lsVg37a0nn9YmKzVVxOPrCcErrj2B0XYu/NgxDJVomPjhAgkCY X-Received: by 2002:a05:6512:238d:b0:530:aa3e:f3c with SMTP id 2adb3069b0e04-539c48c347bmr3104968e87.14.1728538568954; Wed, 09 Oct 2024 22:36:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1728538568; cv=none; d=google.com; s=arc-20240605; b=gpgZjUqByBdH+Dk4GDpUOiW1FKXZWzbekVR2r7l6x1unhd4XtOtBvC8TLw+JddzThz n3BYSlxtSZZlqztuQpp0bDyaLg6oq5GYKMx68ZA9qhxFGIaSuJ3lnDNiune3dQPFAVK2 7BYH3drHA0nTgtbTR3WohCMEw0fgEyu2HgWVGOoLKDMqtC2D/w4Jumc+Y1ox8+2u43uU iRnu15mJJ16J761xX+6W069IgKdgzqXe6H7NhxAXI+UyOKSg5LJhMXt/Vj4K4VfgFwyj SsjLbuYjBz9+/GbqN6nRiHXbHsO0QAj6VtBz2nk6yYc0p7OB4xahOFxsc4c6G+lF1Xax 4E6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:content-transfer-encoding:cc: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=pey2AwJ+DsxmADe7OqPy4+dVP0EbUo6BC8VSyMfbzMk=; fh=SY+A8HDvCKivsvOlugO0byaDvZLxc2A9PIXlqXmaPLE=; b=HjIeSnVwPUMQRoOIR3wLnEVGPkeiLopFsa86LvHwMkpC12R6Xrr1DPgOZ8YxZAtE/p lb7ZVK5Fb3vIEJFDwJ3PcNCdztSkxKu27s4cpSQZLilJAuS7Q3UCjjWjpSbgfuguzl7G FVAXxv//QQtRrWf9LcUoYw/G2TTzzK5OOpSZAB4jp4Jxmgd/wpG0g6xTCTmRwvDSQnKT kfINtdVGvcp7x/y3odi0ZwOqu116DyGdUguEhYi1ignOGiflE6RkZFUor1Ze/6Yp258r VZ8JxCOyc3uQO2IbCOAQaZNrSDAmbRIfjFkThnTOnj2mRk+6bgW+GS8vUJjG1AvgE5yC nd9w==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@mur.at header.s=dkim2 header.b=jDTtkbKh; 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=NONE dis=NONE) header.from=mur.at Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id 2adb3069b0e04-539cb6c4b0asi216214e87.46.2024.10.09.22.36.08; Wed, 09 Oct 2024 22:36:08 -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=@mur.at header.s=dkim2 header.b=jDTtkbKh; 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=NONE dis=NONE) header.from=mur.at Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id BCFAF68DE80; Thu, 10 Oct 2024 06:08:33 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from efeu.mur.at (efeu.mur.at [89.106.208.42]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 725C268DE6F for ; Thu, 10 Oct 2024 06:08:24 +0300 (EEST) Received: from localhost.localdomain (lan1.raspi.ma39.ffgraz.net [10.12.1.243]) by efeu.mur.at (Postfix) with ESMTPSA id 0459346378; Thu, 10 Oct 2024 05:08:24 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mur.at; s=dkim2; t=1728529704; bh=Rn86jL2r2TdU2N7aIViIEKKnXO5wma1k7Fpc7CAQuMU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=jDTtkbKhKHAmLwHO2zFrFSF2Psh6GKnY2gn+19UZ2z/7wVpEysKdiQgDalrG0+l3H gX6TTCVc0Iw3oujJjlwD/7iZLJdpwJCZ/iE/UFK4sPjF6YKBBy1pbA5HJlHnD07Zv+ 66L9UlMVPBLuFZau8jsy/cynu5QpIVFuEtkypoZ6Nu60XiROCKLaB2Na6+g7xCALhV IM0tmBDOKfiFrh9p3bc1cMSOKKxnH9uW8RKaA27kSYXH1/YOEgCloU41TDnNWI8ppo nQsUeVohdQYzzBxXyintoDJhj9tBobwmRvLiNrEyOz0jnFWLSDN6Nx7zHHeZzAFcCh 8V+TFqWnZcQ2rtMYxzmbYJAXCytz4/QJ0f5T6QF2OmvVv5Yb8BgSUb+XN5qLf7B1K8 aOv1sDuFPr1TnaILzlHoyGnxep1NQlEGJWaDYpm4EdGgMc+F8EVUADdYCvWiZsZN9w W/YJEc9w5fGe2PAFEVEUOXWkXtLyrhP7yI6tMKVFcPml+EAvARL From: Martin Schitter To: ffmpeg-devel@ffmpeg.org Date: Thu, 10 Oct 2024 04:58:42 +0200 Message-ID: <20241010025841.531321-5-ms+git@mur.at> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241010025841.531321-2-ms+git@mur.at> References: <20241010025841.531321-2-ms+git@mur.at> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v11 3/3] tests: Fate sample tests for DNxUncompressed 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: michael@niedermayer.cc, Martin Schitter Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: V4Z3YWE0xspx --- tests/Makefile | 1 + tests/fate/dnxuc.mak | 40 +++++++++++++++++++++++++++++ tests/ref/fate/dnxuc-cb-rgb-10 | 8 ++++++ tests/ref/fate/dnxuc-cb-rgb-12 | 8 ++++++ tests/ref/fate/dnxuc-cb-rgb-8 | 8 ++++++ tests/ref/fate/dnxuc-cb-rgb-float | 8 ++++++ tests/ref/fate/dnxuc-cb-rgb-half | 8 ++++++ tests/ref/fate/dnxuc-cb-yuv422-10 | 8 ++++++ tests/ref/fate/dnxuc-cb-yuv422-12 | 8 ++++++ tests/ref/fate/dnxuc-cb-yuv422-8 | 8 ++++++ tests/ref/fate/dnxuc-ramp-rgb-10 | 8 ++++++ tests/ref/fate/dnxuc-ramp-rgb-12 | 8 ++++++ tests/ref/fate/dnxuc-ramp-rgb-8 | 8 ++++++ tests/ref/fate/dnxuc-ramp-rgb-float | 8 ++++++ tests/ref/fate/dnxuc-ramp-rgb-half | 8 ++++++ tests/ref/fate/dnxuc-ramp-yuv422-10 | 8 ++++++ tests/ref/fate/dnxuc-ramp-yuv422-12 | 8 ++++++ tests/ref/fate/dnxuc-ramp-yuv422-8 | 8 ++++++ 18 files changed, 169 insertions(+) create mode 100644 tests/fate/dnxuc.mak create mode 100644 tests/ref/fate/dnxuc-cb-rgb-10 create mode 100644 tests/ref/fate/dnxuc-cb-rgb-12 create mode 100644 tests/ref/fate/dnxuc-cb-rgb-8 create mode 100644 tests/ref/fate/dnxuc-cb-rgb-float create mode 100644 tests/ref/fate/dnxuc-cb-rgb-half create mode 100644 tests/ref/fate/dnxuc-cb-yuv422-10 create mode 100644 tests/ref/fate/dnxuc-cb-yuv422-12 create mode 100644 tests/ref/fate/dnxuc-cb-yuv422-8 create mode 100644 tests/ref/fate/dnxuc-ramp-rgb-10 create mode 100644 tests/ref/fate/dnxuc-ramp-rgb-12 create mode 100644 tests/ref/fate/dnxuc-ramp-rgb-8 create mode 100644 tests/ref/fate/dnxuc-ramp-rgb-float create mode 100644 tests/ref/fate/dnxuc-ramp-rgb-half create mode 100644 tests/ref/fate/dnxuc-ramp-yuv422-10 create mode 100644 tests/ref/fate/dnxuc-ramp-yuv422-12 create mode 100644 tests/ref/fate/dnxuc-ramp-yuv422-8 diff --git a/tests/Makefile b/tests/Makefile index 9b70145..e073915 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -172,6 +172,7 @@ include $(SRC_PATH)/tests/fate/dca.mak include $(SRC_PATH)/tests/fate/demux.mak include $(SRC_PATH)/tests/fate/dfa.mak include $(SRC_PATH)/tests/fate/dnxhd.mak +include $(SRC_PATH)/tests/fate/dnxuc.mak include $(SRC_PATH)/tests/fate/dpcm.mak include $(SRC_PATH)/tests/fate/dvvideo.mak include $(SRC_PATH)/tests/fate/ea.mak diff --git a/tests/fate/dnxuc.mak b/tests/fate/dnxuc.mak new file mode 100644 index 0000000..80ff0e9 --- /dev/null +++ b/tests/fate/dnxuc.mak @@ -0,0 +1,40 @@ +FATE_DNXUC_CB = fate-dnxuc-cb-rgb-8 \ + fate-dnxuc-cb-rgb-10 \ + fate-dnxuc-cb-rgb-12 \ + fate-dnxuc-cb-rgb-half \ + fate-dnxuc-cb-rgb-float \ + fate-dnxuc-cb-yuv422-8 \ + fate-dnxuc-cb-yuv422-10 \ + fate-dnxuc-cb-yuv422-12 + +FATE_DNXUC_RAMP = fate-dnxuc-ramp-rgb-8 \ + fate-dnxuc-ramp-rgb-10 \ + fate-dnxuc-ramp-rgb-12 \ + fate-dnxuc-ramp-rgb-half \ + fate-dnxuc-ramp-rgb-float \ + fate-dnxuc-ramp-yuv422-8 \ + fate-dnxuc-ramp-yuv422-10 \ + fate-dnxuc-ramp-yuv422-12 + +FATE_DNXUC-$(call FRAMECRC, MXF, DNXUC) += $(FATE_DNXUC_CB) $(FATE_DNXUC_RAMP) + +FATE_SAMPLES_FFMPEG += $(FATE_DNXUC-yes) +fate-dnxuc: $(FATE_DNXUC-yes) + +fate-dnxuc-cb-rgb-8: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_rgb_8.mxf +fate-dnxuc-cb-rgb-10: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_rgb_10.mxf +fate-dnxuc-cb-rgb-12: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_rgb_12.mxf +fate-dnxuc-cb-rgb-half: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_rgb_half.mxf +fate-dnxuc-cb-rgb-float: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_rgb_float.mxf +fate-dnxuc-cb-yuv422-8: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_yuv422_8.mxf +fate-dnxuc-cb-yuv422-10: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_yuv422_10.mxf +fate-dnxuc-cb-yuv422-12: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/cb_yuv422_12.mxf + +fate-dnxuc-ramp-rgb-8: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_rgb_8.mxf +fate-dnxuc-ramp-rgb-10: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_rgb_10.mxf +fate-dnxuc-ramp-rgb-12: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_rgb_12.mxf +fate-dnxuc-ramp-rgb-half: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_rgb_half.mxf +fate-dnxuc-ramp-rgb-float: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_rgb_float.mxf +fate-dnxuc-ramp-yuv422-8: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_yuv422_8.mxf +fate-dnxuc-ramp-yuv422-10: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_yuv422_10.mxf +fate-dnxuc-ramp-yuv422-12: CMD = framecrc -flags +bitexact -i $(TARGET_SAMPLES)/dnxuc/ramp_yuv422_12.mxf diff --git a/tests/ref/fate/dnxuc-cb-rgb-10 b/tests/ref/fate/dnxuc-cb-rgb-10 new file mode 100644 index 0000000..398e0da --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-rgb-10 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 786432, 0x2e402ec2 +0, 1, 1, 1, 786432, 0x2e402ec2 +0, 2, 2, 1, 786432, 0x2e402ec2 diff --git a/tests/ref/fate/dnxuc-cb-rgb-12 b/tests/ref/fate/dnxuc-cb-rgb-12 new file mode 100644 index 0000000..4e3235f --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-rgb-12 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 786432, 0x6fb11356 +0, 1, 1, 1, 786432, 0x6fb11356 +0, 2, 2, 1, 786432, 0x6fb11356 diff --git a/tests/ref/fate/dnxuc-cb-rgb-8 b/tests/ref/fate/dnxuc-cb-rgb-8 new file mode 100644 index 0000000..189babc --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-rgb-8 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 393216, 0xc1f6a4cc +0, 1, 1, 1, 393216, 0xc1f6a4cc +0, 2, 2, 1, 393216, 0xc1f6a4cc diff --git a/tests/ref/fate/dnxuc-cb-rgb-float b/tests/ref/fate/dnxuc-cb-rgb-float new file mode 100644 index 0000000..95ab4e5 --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-rgb-float @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 1572864, 0x88241923 +0, 1, 1, 1, 1572864, 0x88241923 +0, 2, 2, 1, 1572864, 0x88241923 diff --git a/tests/ref/fate/dnxuc-cb-rgb-half b/tests/ref/fate/dnxuc-cb-rgb-half new file mode 100644 index 0000000..b7e9406 --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-rgb-half @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 1048576, 0xfc459149 +0, 1, 1, 1, 1048576, 0xfc459149 +0, 2, 2, 1, 1048576, 0xfc459149 diff --git a/tests/ref/fate/dnxuc-cb-yuv422-10 b/tests/ref/fate/dnxuc-cb-yuv422-10 new file mode 100644 index 0000000..6e7c537 --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-yuv422-10 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 524288, 0xad829843 +0, 1, 1, 1, 524288, 0xad829843 +0, 2, 2, 1, 524288, 0xad829843 diff --git a/tests/ref/fate/dnxuc-cb-yuv422-12 b/tests/ref/fate/dnxuc-cb-yuv422-12 new file mode 100644 index 0000000..01e5976 --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-yuv422-12 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 524288, 0x70277284 +0, 1, 1, 1, 524288, 0x70277284 +0, 2, 2, 1, 524288, 0x70277284 diff --git a/tests/ref/fate/dnxuc-cb-yuv422-8 b/tests/ref/fate/dnxuc-cb-yuv422-8 new file mode 100644 index 0000000..1e4bb3e --- /dev/null +++ b/tests/ref/fate/dnxuc-cb-yuv422-8 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 262144, 0x12299f3f +0, 1, 1, 1, 262144, 0x12299f3f +0, 2, 2, 1, 262144, 0x12299f3f diff --git a/tests/ref/fate/dnxuc-ramp-rgb-10 b/tests/ref/fate/dnxuc-ramp-rgb-10 new file mode 100644 index 0000000..99a2eb9 --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-rgb-10 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 786432, 0xe4d06700 +0, 1, 1, 1, 786432, 0xe4d06700 +0, 2, 2, 1, 786432, 0xe4d06700 diff --git a/tests/ref/fate/dnxuc-ramp-rgb-12 b/tests/ref/fate/dnxuc-ramp-rgb-12 new file mode 100644 index 0000000..19eb687 --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-rgb-12 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 786432, 0xb8c802a4 +0, 1, 1, 1, 786432, 0xb8c802a4 +0, 2, 2, 1, 786432, 0xb8c802a4 diff --git a/tests/ref/fate/dnxuc-ramp-rgb-8 b/tests/ref/fate/dnxuc-ramp-rgb-8 new file mode 100644 index 0000000..2c1caae --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-rgb-8 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 393216, 0xd1f001f2 +0, 1, 1, 1, 393216, 0xd1f001f2 +0, 2, 2, 1, 393216, 0xd1f001f2 diff --git a/tests/ref/fate/dnxuc-ramp-rgb-float b/tests/ref/fate/dnxuc-ramp-rgb-float new file mode 100644 index 0000000..c35172c --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-rgb-float @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 1572864, 0xda4a5914 +0, 1, 1, 1, 1572864, 0xda4a5914 +0, 2, 2, 1, 1572864, 0xda4a5914 diff --git a/tests/ref/fate/dnxuc-ramp-rgb-half b/tests/ref/fate/dnxuc-ramp-rgb-half new file mode 100644 index 0000000..eee882a --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-rgb-half @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 1048576, 0x0dda0807 +0, 1, 1, 1, 1048576, 0x0dda0807 +0, 2, 2, 1, 1048576, 0x0dda0807 diff --git a/tests/ref/fate/dnxuc-ramp-yuv422-10 b/tests/ref/fate/dnxuc-ramp-yuv422-10 new file mode 100644 index 0000000..ef158a5 --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-yuv422-10 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 524288, 0xb86e482d +0, 1, 1, 1, 524288, 0xb86e482d +0, 2, 2, 1, 524288, 0xb86e482d diff --git a/tests/ref/fate/dnxuc-ramp-yuv422-12 b/tests/ref/fate/dnxuc-ramp-yuv422-12 new file mode 100644 index 0000000..4596dc8 --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-yuv422-12 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 524288, 0x9bbd5677 +0, 1, 1, 1, 524288, 0x9bbd5677 +0, 2, 2, 1, 524288, 0x9bbd5677 diff --git a/tests/ref/fate/dnxuc-ramp-yuv422-8 b/tests/ref/fate/dnxuc-ramp-yuv422-8 new file mode 100644 index 0000000..bb6fd38 --- /dev/null +++ b/tests/ref/fate/dnxuc-ramp-yuv422-8 @@ -0,0 +1,8 @@ +#tb 0: 1/24 +#media_type 0: video +#codec_id 0: rawvideo +#dimensions 0: 512x256 +#sar 0: 1/1 +0, 0, 0, 1, 262144, 0x386e0fa6 +0, 1, 1, 1, 262144, 0x386e0fa6 +0, 2, 2, 1, 262144, 0x386e0fa6