Re: [Mesa-dev] [PATCH kmscube] texturator: Use !! for boolean assignment

2020-03-31 Thread Fabio Estevam
Hi Jason and Ian, On Tue, Mar 31, 2020 at 5:39 PM Jason Ekstrand wrote: > My feelings aren't usually all that strong on this point though I > generally prefer !=. That said, this is a float. I very strongly > prefer != 0.0f. Thanks for the feedback. I did as suggested: https://gitlab.freedesk

Re: [Mesa-dev] [PATCH kmscube] texturator: Use !! for boolean assignment

2020-03-31 Thread Jason Ekstrand
On Tue, Mar 31, 2020 at 3:00 PM Ian Romanick wrote: > > On 3/31/20 12:25 PM, Fabio Estevam wrote: > > The 'complemented' variable is a pointer to boolean. Use the !! operator > > to fix the following build warning: > > > > ../texturator.c:603:45: warning: '*' in boolean context, suggest '&&' > >

Re: [Mesa-dev] [PATCH kmscube] texturator: Use !! for boolean assignment

2020-03-31 Thread Ian Romanick
On 3/31/20 12:25 PM, Fabio Estevam wrote: > The 'complemented' variable is a pointer to boolean. Use the !! operator > to fix the following build warning: > > ../texturator.c:603:45: warning: '*' in boolean context, suggest '&&' instead > [-Wint-in-bool-context] > *complemented = (((float)rgba[

[Mesa-dev] [PATCH kmscube] texturator: Use !! for boolean assignment

2020-03-31 Thread Fabio Estevam
The 'complemented' variable is a pointer to boolean. Use the !! operator to fix the following build warning: ../texturator.c:603:45: warning: '*' in boolean context, suggest '&&' instead [-Wint-in-bool-context] *complemented = (((float)rgba[2]) / 255.0) / 0.25; Signed-off-by: Fabio Estevam --