|
|
Cousin Ricky wrote:
> For example, it would be useful to have a texture apply optionally to a
> portion of a union:
>
> #macro Neat_object (Param1, Param2, Texture)
> union
> { object { ... }
> object
> { ...
> #if ( /* Texture is really a texture and not the float value 0 */ )
> texture { Texture }
> #end
> }
> }
> #end
You could use the following workaround:
#macro Neat_object (Param1, Param2, Texture, UseTexture)
union
{ object { ... }
object
{ ...
#if (UseTexture)
texture { Texture }
#end
}
}
#end
Neat_object(Foo, Bar, MightBeATexture, defined(MightBeATexture)
HTH,
Florian
Post a reply to this message
|
|