I would like to draw line, just like the graphics API, only that it will be assembled of chunks of a given texture (“lineChunk.png”)
The chunk would be small to allow rotating it when needed, by the line’s path.
The purpose is to let the user, using mouseMove, create a textured line.
I’ve tried to make it ‘manually’, but when drawing fast, the distance between two point is vast, and therefore there was a need to close the gap using a while loop, which slowed things down significantly.
The ‘graphics.lineBitmapStyle’ wasn’t helpful as well as it doesn’t serve this purpose.
Any suggestions ?
Ok, so the best way is to create a single Bitmap instance of the sample texture, and create another empty Bitmap which will be your canvas.
Do the regular drill with looping to fill the missing gaps between 2 points, and use Bitmap.Draw to draw in each time the single texture Bitmap after it was transformed of course.
It works pretty well.