[MPlayer-dev-eng] rgb<->yuv convertion question

Tuukka Toivonen tuukkat at ee.oulu.fi
Thu Jan 15 10:54:45 CET 2004


On Thu, 15 Jan 2004, mayaray wrote:

>i put my Clamp function:
>unsigned char Clamp(float i) {
>	if (i>256.0f)
              ^^^ should be 255.0
>		return 256;
                       ^^^ should be 255
>	if (i<0.0f)
>		return 0;
>	return (unsigned char)i;
>}

How were you able to add bugs in such a small piece of code?-)




More information about the MPlayer-dev-eng mailing list