[FFmpeg-devel] [PATCH] lavu/eval: add ifzero() and ifnonzero() expression

Stefano Sabatini stefasab at gmail.com
Tue Jan 17 12:18:26 CET 2012


On date Monday 2012-01-16 15:01:50 +0100, Nicolas George encoded:
> Le septidi 27 nivôse, an CCXX, Stefano Sabatini a écrit :
> > It may complicate the code in eval.c (infix notation is *evil*), but
> 
> This is flamebait. Can we agree on that at least: infix notation is evil for
> those who implement, those who do theory and those who want to manipulate
> expressions automatically, but they are much simpler for simple users who
> want to write simple expressions.

Eehe, I just wanted to gauge the reaction of a mathematician ;-).

> > I'm not against it, just I ask, is this related to the patch?
> 
> It is loosely related since "ifzero(x)" could be just written "x==0", but
> "Un tien vaut, ce dit-on, mieux que deux tu l’auras"
> (sorry, no translation), so this is not an objection to the patch, unless
> someone (not me!) can submit a rewrite of eval.c in the next few minutes.

Uhm, this still looks unrelated, indeed with the if() expression the
following expressions would be equivalent:
if(x==0, y)
if(eq(x,0), y)
ifnot(x, y)
-- 
FFmpeg = Fast Fiendish Minimal Picky Esoteric Gnome


More information about the ffmpeg-devel mailing list