StrokeWidth and StrokeLineCap Bug

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
lanortha
Posts: 1
Joined: 2011-09-15T11:43:29-07:00
Authentication code: 8675308

StrokeWidth and StrokeLineCap Bug

Post by lanortha »

Hi,

I'm using the ImageMagick-6.7.2-Q16 API in Windows 7 with VisualStudio 2010, and having trouble with StrokeWidth and StrokeLineCap.
When StrokeWidth is set to a constant value, lines are rendered with thicknesses not equal to the specified value. StrokeLineCap parameters
are being ignored.

The code I'm using is:

Code: Select all

	drawList.push_back( DrawableStrokeColor( rgb ) );
	drawList.push_back( DrawableStrokeOpacity( 1.0 ) );
	drawList.push_back( DrawableStrokeAntialias( true ) );
	drawList.push_back( DrawableStrokeLineCap( LineCap::RoundCap ) );
	drawList.push_back( DrawableStrokeWidth( 50 ) );
	drawList.push_back( DrawableLine( strokes[i].knots[0].x, strokes[i].knots[0].y, 
	  						     strokes[i].knots[1].x, strokes[i].knots[1].y ) );	
	activeCanvas->draw( drawList );
But the image which is produced has lines whose width does not equal 50.
http://postimage.org/image/17fzujdr8/

Any thoughts?

Thanks.
Post Reply