Bug with @{file_name} attribute and convert
Posted: 2011-09-15T10:13:48-07:00
there is a problem using the @{filename} attribute when drawing text using convert
we have been using it to generate bitmap fonts from a list of characters to be drawn in a text file. As some characters are outside of the ascii scope. i.e unicode, we found it the only way to do it was to draw from a text fiel containing the character to be drawn.
The BUG:
the script we had been using generates a text file which is named as follows
{font_name}_{char_code}-{actual_character_if_valid_filename_char}.txt
we then use imagemagick to then draw the character using from the text file using a command such as:
convert -size 27x31 xc:black -font Arial-Bold-Italic -pointsize 19 -fill gradient:yellow-DarkOrange -gravity Center -annotate 0 @imagesets/in/menu_360/gametext/gametext_202-Ê.txt imagesets/in/menu_360/gametext/gametext_202-Ê.png
I have found that using the following windows binary:
ImageMagick-6.7.2-1-Q16-windows-x64-dll
this now results in the whole filename being drawn instead of the character in the file for all characters that cannot be typed normally using the keyboard (i.e not using the ALT modifier)
it was working fine with previous version 32bit version
ImageMagick-6.6.3-0-Q8-windows-dll
as a workaround we have modified the text filenaming such that the following now works with the 64 bit binary:
convert.exe -size 27x31 xc:black -font Arial-Bold-Italic -pointsize 19 -fill gradient:yellow-DarkOrange -gravity Center -annotate 0 @imagesets/in/menu_360/gametext/gametext_202-u00CA.txt imagesets/in/menu_360/gametext/gametext_202-Ê.png
Regards
Laurence
we have been using it to generate bitmap fonts from a list of characters to be drawn in a text file. As some characters are outside of the ascii scope. i.e unicode, we found it the only way to do it was to draw from a text fiel containing the character to be drawn.
The BUG:
the script we had been using generates a text file which is named as follows
{font_name}_{char_code}-{actual_character_if_valid_filename_char}.txt
we then use imagemagick to then draw the character using from the text file using a command such as:
convert -size 27x31 xc:black -font Arial-Bold-Italic -pointsize 19 -fill gradient:yellow-DarkOrange -gravity Center -annotate 0 @imagesets/in/menu_360/gametext/gametext_202-Ê.txt imagesets/in/menu_360/gametext/gametext_202-Ê.png
I have found that using the following windows binary:
ImageMagick-6.7.2-1-Q16-windows-x64-dll
this now results in the whole filename being drawn instead of the character in the file for all characters that cannot be typed normally using the keyboard (i.e not using the ALT modifier)
it was working fine with previous version 32bit version
ImageMagick-6.6.3-0-Q8-windows-dll
as a workaround we have modified the text filenaming such that the following now works with the 64 bit binary:
convert.exe -size 27x31 xc:black -font Arial-Bold-Italic -pointsize 19 -fill gradient:yellow-DarkOrange -gravity Center -annotate 0 @imagesets/in/menu_360/gametext/gametext_202-u00CA.txt imagesets/in/menu_360/gametext/gametext_202-Ê.png
Regards
Laurence