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 30DBD4780D for ; Fri, 22 Sep 2023 22:46:29 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A3D2568C92F; Sat, 23 Sep 2023 01:46:27 +0300 (EEST) Received: from mail-vs1-f51.google.com (mail-vs1-f51.google.com [209.85.217.51]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 7758D68C68D for ; Sat, 23 Sep 2023 01:46:21 +0300 (EEST) Received: by mail-vs1-f51.google.com with SMTP id ada2fe7eead31-452962769bdso1458840137.3 for ; Fri, 22 Sep 2023 15:46:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695422780; x=1696027580; darn=ffmpeg.org; h=to:subject:message-id:date:from:references:in-reply-to:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=9k5ydt0j47DIq+xSnahMHsvxFlGXX3/Xv0h7By6HlbE=; b=NHB5sujnvdwwxJflYJUm1PGc+IaAikObXUfrX73keB8Y+/k8Untr5vq39IKbZc0H2H 4gkjQtviouz3kxbgksrBgL1EO8ei22QLqyMScxv0yijjdsWGroMIY4awyJfpGVKMa36/ qDoWxyGjkPLCszCz10bmwLepwebIelMrXiQTBFOILR1fbZlXXnHuGqJljDC739Y+t0NK h1CUX3C6f987DkfaEx95mwmf0YhuYfyTwar5HqaiCHCETHSWmENhZytgpPy9FfJDoLDO y68nqu6vI3codRX7wm1okz9b2WV8NOcPGpv5iZo/DIQFA73BjDSjz1Osv98DODnlltRI BVOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695422780; x=1696027580; h=to:subject:message-id:date:from:references:in-reply-to:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=9k5ydt0j47DIq+xSnahMHsvxFlGXX3/Xv0h7By6HlbE=; b=sDsuFG3VJQ0SXbdabPjM/sCqjelsauNq3uAvPGDo8jZG4RgwlXoSWBz1pCRifuHItD sE3NNPjh9iVjY64pP6JrkMkolBLl68zhxigZNHawLh4Ggol8REGT+H0u05rl4davIam2 GnpucQxhm7Pk89pMPyGLPqg+3kYGJx7lTQkoOSFj72baiNcgz+AVfJZZu0cj2eYax1jb 6EarxTKTtAtQ5+lycEgGhagLzEFR8swpwsQlqVE2thmJcX+vKNb+4ycO0cCOiKOQijzQ vXSuQmnq9vBu7R5iS7GDZUvHddg4bW/nyXlnMkUUmpy1dDf4vO92IVw4KFj871/qMg0f RFUQ== X-Gm-Message-State: AOJu0YwEgE9rc6ZTbjIizSSmyWHx0B/L/kqq5wP3Bs67pex1otm2uRQi zeqmLp1BsfLOcWgMzfw08iq8yJEw9ClLnva9M/X+CCsrvmA= X-Google-Smtp-Source: AGHT+IEjFtspLFgoh+nrrSDXerTk2AVE2deEbUToGZ0Pp1Uad1e22dEbd9MD0lUNuKir8CsVwTy76f5KwzMX9tZed6Q= X-Received: by 2002:a67:f842:0:b0:452:5c6d:78c9 with SMTP id b2-20020a67f842000000b004525c6d78c9mr968054vsp.12.1695422779902; Fri, 22 Sep 2023 15:46:19 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a59:9f50:0:b0:3eb:b4c:bd4f with HTTP; Fri, 22 Sep 2023 15:46:19 -0700 (PDT) In-Reply-To: <20230922223336.GB3543730@pb2> References: <20230726235916.30058-1-michael@niedermayer.cc> <20230922192204.GC8640@pb2> <20230922212616.GH8640@pb2> <20230922215215.GA3543730@pb2> <20230922223336.GB3543730@pb2> From: Paul B Mahol Date: Sat, 23 Sep 2023 00:46:19 +0200 Message-ID: To: FFmpeg development discussions and patches Subject: Re: [FFmpeg-devel] [PATCH 1/4] avcodec/rtv1: Check if the minimal size is available in decode_rtv1() 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 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: On 9/23/23, Michael Niedermayer wrote: > On Sat, Sep 23, 2023 at 12:01:17AM +0200, Paul B Mahol wrote: >> On 9/22/23, Michael Niedermayer wrote: >> > On Fri, Sep 22, 2023 at 11:30:37PM +0200, Paul B Mahol wrote: >> >> On 9/22/23, Michael Niedermayer wrote: >> >> > On Fri, Sep 22, 2023 at 09:32:47PM +0200, Paul B Mahol wrote: >> >> >> On 9/22/23, Michael Niedermayer wrote: >> >> >> > On Thu, Jul 27, 2023 at 01:59:13AM +0200, Michael Niedermayer >> >> >> > wrote: >> >> >> >> Signed-off-by: Michael Niedermayer >> >> >> >> --- >> >> >> >> libavcodec/rtv1.c | 6 +++++- >> >> >> >> 1 file changed, 5 insertions(+), 1 deletion(-) >> >> >> > >> >> >> > will apply 1-3 of this patchset >> >> >> >> >> >> Are you sure this does not break decoding? >> >> > >> >> > Well, its a loop over 4x4 blocks, a 16bit "skip" run so the minimum >> >> > check looks correct. >> >> > There are 2 end of bitstream checks for early exit but they look >> >> > like >> >> > error handling not some normal exit as they leave the frame >> >> > uninitialized >> >> > >> >> >> >> FFmpeg default initialization code for AVFrame's buffers does it >> >> twice, so they are always zeroed or previous values of previous >> >> buffers in pool. >> > >> > its rare that correct frame decoding depends on internal AVFrame buffer >> > ordering >> > >> >> Users are supposed to use error checking. And I think decoder returns >> error on missing frame data. > > yes, the rtv1 decoder looks a bit sloppy written, not returning error > codes on what looks like error checks. > Its not the only code doing that, ive seen this in other files too You are last person here to call some decoder(s) are sloppy written. > > >> >> When we lost interest in preserving all decoded frame pixels as much >> as possible? > > when patches using discard_damaged_percentage where getting blocked in > review > while simpler but less ideal solutions made all reviewers happy > > > I can implement this using discard_damaged_percentage, then the user can > decide at which point a frame would be too damaged to decode/return > and also to drop none or all with damage as the user prefers > > thx > > [...] > -- > Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB > > Homeopathy is like voting while filling the ballot out with transparent > ink. > Sometimes the outcome one wanted occurs. Rarely its worse than filling out > a ballot properly. > _______________________________________________ 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".