Drawing with MSL does not work

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
hotspur

Drawing with MSL does not work

Post by hotspur »

Hi,
a while ago I asked how to draw with MSL but no one seemed to know the answer. Today, I looked into the sources and found that although drawing method is called in msl.c (around line 2550), no primitive is defined (and thus nothing is drawn).
However, adding new attribute (primitive) does the trick (added under parsing poinsize atribute):

Code: Select all

if (LocaleCompare(keyword,"primitive") == 0)
{  
  CloneString(&draw_info->primitive,value);
  break;
}
because now drawing via

Code: Select all

<draw pointsize="40" fill="blue" primitive="text 30,30 Hullo" />
<draw pointsize="40" fill="blue" primitive="line 30,30,20,20" />
works. Or was my idea worthless because this is already possible?
Bye
- Vojta
Post Reply