|
|
Again, looking in the code I spotted this MACRO that seems to me
wrong:
-> File: objects.h Line: 55-56
* Copy_Flag (Object1, Object2, Flag) : Set the Flag in Object1 to the
* value of the Flag in Object2.
-> File: objects.h Line: 108-111
#define Copy_Flag(Object1, Object2, Flag) \
{ (Object1)->Flags = (((Object1)->Flags) & (!Flag)) | \
(((Object2)->Flags) & (Flag)); }
I think ~ is correct instead of !
#define Copy_Flag(Object1, Object2, Flag) \
{ (Object1)->Flags = (((Object1)->Flags) & (~Flag)) | \
(((Object2)->Flags) & (Flag)); }
HTH Massimo
Post a reply to this message
|
|
|
|
In article <3d81cb77@news.povray.org> , "Massimo Valentini"
<six### [at] inwindit> wrote:
> Again, looking in the code I spotted this MACRO that seems to me
> wrong:
>
> -> File: objects.h Line: 55-56
> * Copy_Flag (Object1, Object2, Flag) : Set the Flag in Object1 to the
> * value of the Flag in Object2.
>
> -> File: objects.h Line: 108-111
> #define Copy_Flag(Object1, Object2, Flag) \
> { (Object1)->Flags = (((Object1)->Flags) & (!Flag)) | \
> (((Object2)->Flags) & (Flag)); }
>
> I think ~ is correct instead of !
I agree. However, s it is only used in Copy_Poly (the function that copies
declared poly objects), I guess nobody noticed yet in years...
Thorsten
____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde
Visit POV-Ray on the web: http://mac.povray.org
Post a reply to this message
|
|