Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-23 Thread Moritz Barsnick
On Mon, Jun 22, 2020 at 14:24:19 +0200, Valery Kot wrote: > On Mon, Jun 22, 2020 at 12:54 PM Moritz Barsnick wrote: > > NOT of a logical OR can be inverted, so this *may* be more readable as: > >if ((i && i != w - 1 && j && j != h - 1) && > Indeed, those three are equivalent. Compl

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Valery Kot
On Mon, Jun 22, 2020 at 4:56 PM Andriy Gelman wrote: > It should be enough to change the hashes in two files. > Please resend with these changes. > > diff --git a/tests/ref/fate/filter-edgedetect > b/tests/ref/fate/filter-edgedetect > index 23c9953e61..e49639afac 100644 > --- a/tests/ref/fate/fil

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Andriy Gelman
On Mon, 22. Jun 09:58, Valery Kot wrote: > On Mon, Jun 22, 2020 at 7:58 AM Andriy Gelman wrote: > > > > Hi Valery, > > > > Thanks for the patch. > > > > Please also update the fate test: > > https://patchwork.ffmpeg.org/project/ffmpeg/patch/cagtf1mncx2joo-vmtucdkjcp76y5jslnhubzat4mf48c2hf...@mail.

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Valery Kot
On Mon, Jun 22, 2020 at 12:57 PM Moritz Barsnick wrote: > > On Mon, Jun 22, 2020 at 09:58:42 +0200, Valery Kot wrote: > > Thanks for feedback. Updating FATE tests is a bridge too far for me. I > > can't even build FFmpeg itself at the moment, say nothing about > > setting up the test environment a

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Valery Kot
On Mon, Jun 22, 2020 at 12:54 PM Moritz Barsnick wrote: > > On Fri, Jun 19, 2020 at 17:15:06 +0200, Valery Kot wrote: > > -if ((!i || i == w - 1 || !j || j == h - 1) && > > +if (!(!i || i == w - 1 || !j || j == h - 1) && > > NOT of a logical OR can be inverted, so this *may

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Moritz Barsnick
On Mon, Jun 22, 2020 at 09:58:42 +0200, Valery Kot wrote: > Thanks for feedback. Updating FATE tests is a bridge too far for me. I > can't even build FFmpeg itself at the moment, say nothing about > setting up the test environment and finding out how it works. Could > you please do this update for

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Moritz Barsnick
On Fri, Jun 19, 2020 at 17:15:06 +0200, Valery Kot wrote: > -if ((!i || i == w - 1 || !j || j == h - 1) && > +if (!(!i || i == w - 1 || !j || j == h - 1) && NOT of a logical OR can be inverted, so this *may* be more readable as: if ((i && i != w - 1 && j && j

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-22 Thread Valery Kot
On Mon, Jun 22, 2020 at 7:58 AM Andriy Gelman wrote: > > Hi Valery, > > Thanks for the patch. > > Please also update the fate test: > https://patchwork.ffmpeg.org/project/ffmpeg/patch/cagtf1mncx2joo-vmtucdkjcp76y5jslnhubzat4mf48c2hf...@mail.gmail.com/ Thanks for feedback. Updating FATE tests is a

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-21 Thread Andriy Gelman
Hi Valery, Thanks for the patch. Please also update the fate test: https://patchwork.ffmpeg.org/project/ffmpeg/patch/cagtf1mncx2joo-vmtucdkjcp76y5jslnhubzat4mf48c2hf...@mail.gmail.com/ On Fri, 19. Jun 17:15, Valery Kot wrote: > vf_edgedetect video filter implements Canny algorithm > (https://e

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-19 Thread Valery Kot
> > > vf_edgedetect video filter implements Canny algorithm > > (https://en.wikipedia.org/wiki/Canny_edge_detector) > > > > Important part of this algo is the double threshold step: pixels above > > "high" threshold being kept, pixels below "low" threshold dropped, > > pixels in between kept if the

Re: [FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-19 Thread Alexander Strasser
Hi Valery! On 2020-06-19 17:15 +0200, Valery Kot wrote: > vf_edgedetect video filter implements Canny algorithm > (https://en.wikipedia.org/wiki/Canny_edge_detector) > > Important part of this algo is the double threshold step: pixels above > "high" threshold being kept, pixels below "low" thresho

[FFmpeg-devel] [Patch] vf_edgedetect: properly implement double_threshold()

2020-06-19 Thread Valery Kot
vf_edgedetect video filter implements Canny algorithm (https://en.wikipedia.org/wiki/Canny_edge_detector) Important part of this algo is the double threshold step: pixels above "high" threshold being kept, pixels below "low" threshold dropped, pixels in between kept if they are attached to "high"