I want to scale the top and bottom of a sprite without affecting the vertical axis at all. The sprite height would remain the same and each pixel row stays at the same height. The top and bottom would also need to be able to move left and right independently, basically shear. This is for a pixel art game.
So, very much like draw_sprite_pos but very different in how the final image turns out.
draw_sprite_pos clearly has issues which won't work for this. There are shaders which replace that with full perspective correction, but clearly, I want something different here. Just drawing it with 3D perspective won't work here as it would blow out the top pixels and shrink the bottom of the sprite down to nothing.
If you want to get an idea for the parameters it'd be like draw_sprite_perspective_skew(sprite, img, top_width, bottom_width, height(this one doesn't matter), top_centre_x, bottom_centre_x, top_y)
I think some other shader would be needed with a vertex buffer, however I cannot deal with shaders too well yet. I have no experience writing them.
I'd appreicate any help with this sort of thing.
So, very much like draw_sprite_pos but very different in how the final image turns out.
draw_sprite_pos clearly has issues which won't work for this. There are shaders which replace that with full perspective correction, but clearly, I want something different here. Just drawing it with 3D perspective won't work here as it would blow out the top pixels and shrink the bottom of the sprite down to nothing.
If you want to get an idea for the parameters it'd be like draw_sprite_perspective_skew(sprite, img, top_width, bottom_width, height(this one doesn't matter), top_centre_x, bottom_centre_x, top_y)
I think some other shader would be needed with a vertex buffer, however I cannot deal with shaders too well yet. I have no experience writing them.
I'd appreicate any help with this sort of thing.