DrawInfo.fill_pattern has changes ?

The MagickWand interface is a new high-level C API interface to ImageMagick core methods. We discourage the use of the core methods and encourage the use of this API instead. Post MagickWand questions, bug reports, and suggestions to this forum.
Post Reply
beginner
Posts: 1
Joined: 2016-05-12T18:21:50-07:00
Authentication code: 1151

DrawInfo.fill_pattern has changes ?

Post by beginner » 2016-05-12T19:00:35-07:00

DrawInfo.fill_pattern on the 6.8.9 version of the performance of normal, when I upgraded to 6.9.4, result of the program has changed.

Code: Select all

DrawingWand *d_wand = NewDrawingWand();

//Drawing diamond

DrawPathStart(d_wand);

int x, y; //point
                
x = width / 2;
y = height / 2 - i * step * hScale;  //(x,y)
DrawPathMoveToAbsolute(d_wand, x, y); 

x = width / 2 - i * step;
y = height / 2;  //(x,y)
DrawPathLineToAbsolute(d_wand, x, y);

x = width / 2;
y = height / 2 + i * step * hScale; //(x,y)
DrawPathLineToAbsolute(d_wand, x, y);

x = width / 2 + i * step;
y = height / 2; //(x,y)
DrawPathLineToAbsolute(d_wand, x, y);

x = width / 2;
y = height / 2 - i * step * hScale;  //(x,y)
DrawPathLineToAbsolute(d_wand, x, y);
DrawPathClose(d_wand);
DrawPathFinish(d_wand);


// Now "peek" at the wand
DrawInfo *draw_info = PeekDrawingWand(d_wand);
draw_info->fill_pattern = mw->images; // set fill pattern ******

DrawImage(mw_frame->images, draw_info);
Displayed properly on 6.8.9 version: filled with images displayed in the middle.
Image


On the 6.9.4 version, Show is changed. Pictures displayed filling the position has changed, not centered.
Image

How to modify the code needs to do?
Please advise.
thanks.

Post Reply