C++ - How draw an image with the 4 corners?
can i draw an image(entire image) with 4 corners?
the PlgBlt() works only with 3 corners, i can't use the 4 corner :(
According to the Doc:
The fourth vertex of the parallelogram (D) is defined by treating the first three points (A, B, and C ) as vectors and computing D = B +CA.
PlgBlt can only result in a parallelogram.
What do you mean draw an image(entire image) with 4 corners? Could you please provide some screenshots to tell us what you are trying to draw?
And I suggest you could refer to the Doc: Using a Pen to Draw Lines and Shapes
the image have 4 corners. now imagine if i rotate it on X, Y and Z. the distance between the TopLeft and BottomLeft can be more big than the distance between TopRight and BottomRight... unless the PlgBlt() is prepared for that
Whether you want to achieve is something like this : https://stackoverflow.com/questions/9608600/how-can-i-render-a-square-bitmap-to-an-arbitrary-four-sided-polygon-using-gdi
is that possible with PlgBlt()?
PlgBlt is for parallelograms transforms
It can be done with Direct2D
Test with Matrix4x4F :
i'm sorry, but what means 'parallel transforms'?
that's why i did draw a line with pixels calculation, fill with some function(too much wholes, depending on angle lol) and that's why i'm trying the Alphablend\stretch pixels calculation ;)
I meant that the result with PlgBlt is a parallelogram because of the 3 points
With a 4*4 matrix, you can do like the test I posted
thank you so much for all
Sign in to comment