Am 20.09.2018 um 16:09 schrieb Bald Eagle:
> Though I'm trying to only /initiate/ a loop with the macro - so the #end of the
> for loop is what I need to avoid at the present.
> I have not yet figured out if there's a syntax trick that's possible.
Can't do such a thing. The `#end` directives in a macro must always be
balanced - otherwise, how would the parser be able to figure out where
the macro ends.
>> #declare Format = "png";
>> image_map { FormatKeyword(Format) "foo.png" }
>
> Right - o. That'll be great. Especially since I can just use a string
> function to look at the extension of the filename and avoid the declare
> altogether. :)
If the file type can already be inferred from the extension, Why not let
POV-Ray do that job? Just leave out the file format keyword, like so:
image_map { "foo.png" }
and Bob's your uncle.
Post a reply to this message
|