Page 1 of 4

Idea - Distorting Sprites

Posted: Mon Mar 09, 2009 12:03 pm
by Jammang
Hopefully for the next release of love we can distort our sprites like in the pictures below. Lots of potential for doing simple 3d things like the classic gta1 buildings. :)

Image
Image

Re: Idea - Distorting Sprites

Posted: Mon Mar 09, 2009 2:34 pm
by Kaze
Good idea.

Re: Idea - Distorting Sprites

Posted: Mon Mar 09, 2009 5:46 pm
by Xcmd
Well there's already been some talk of taking the image and slicing it up and scaling the individual rows. Which might be effective for now. But this would be an interesting feature. Please add it to the feature tracker:

http://love2d.org/forum/tracker.php?p=2

Re: Idea - Distorting Sprites

Posted: Mon Mar 09, 2009 8:30 pm
by Skofo
Yes! ^^

Re: Idea - Distorting Sprites

Posted: Tue Mar 17, 2009 11:45 pm
by hdon
One of those images was from GTA 1 or 2 which uses an ordinary 3D rasterizer to render its scene. Why on earth would you want to have an image distortion API to achieve the same effect with much more code and much slower performance whenever OpenGL itself will do the rasterization for you if you just express your scene in actual 3D geometry?

Re: Idea - Distorting Sprites

Posted: Wed Mar 18, 2009 3:11 pm
by qubodup
hdon wrote:One of those images was from GTA 1 or 2 which uses an ordinary 3D rasterizer to render its scene. Why on earth would you want to have an image distortion API to achieve the same effect with much more code and much slower performance whenever OpenGL itself will do the rasterization for you if you just express your scene in actual 3D geometry?
Uh, so I guess you're talking with OP?

LOVE uses OpenGL...

Re: Idea - Distorting Sprites

Posted: Wed Mar 18, 2009 11:35 pm
by hdon
qubodup wrote:LOVE uses OpenGL...
Yes, it does, and that's my *point.* Why would you want to write your own vertex rasterizer using a 2D image transformation API, only to send those vertices off to OpenGL anyway? It would be slower and more complicated!

Re: Idea - Distorting Sprites

Posted: Thu Mar 19, 2009 12:27 am
by Xcmd
hdon wrote:
qubodup wrote:LOVE uses OpenGL...
Yes, it does, and that's my *point.* Why would you want to write your own vertex rasterizer using a 2D image transformation API, only to send those vertices off to OpenGL anyway? It would be slower and more complicated!
Care to show how it's done quickly?

Re: Idea - Distorting Sprites

Posted: Thu Mar 19, 2009 9:00 am
by qubodup
hdon wrote:Yes, it does, and that's my *point.* Why would you want to write your own vertex rasterizer using a 2D image transformation API, only to send those vertices off to OpenGL anyway? It would be slower and more complicated!
Because LOVE doesn't support it.

Re: Idea - Distorting Sprites

Posted: Thu Mar 19, 2009 10:58 am
by hdon
qubodup wrote:
hdon wrote:Yes, it does, and that's my *point.* Why would you want to write your own vertex rasterizer using a 2D image transformation API, only to send those vertices off to OpenGL anyway? It would be slower and more complicated!
Because LOVE doesn't support it.
I'm saying this is a flaw in LOVE. I do get it. I see the attraction of focusing on a 2D graphics API, I really do. But people are going to want to make 3D games. Using a 2D deformation API to regain the powers you would have if OpenGL were just exposed to you directly is what we call a reach around and in my experience (because FOSS tends to give users what they actually want as opposed to what some executive thinks they should have) I have found that this is something people only tolerate because their boss has told them they have to write code for some crappy proprietary platform.
Xcmd wrote:Care to show how it's done quickly?
Just use ordinary OpenGL! To achieve 2D graphics with OpenGL, LOVE simply uses an orthogonal projection matrix and more or less ignores the Z component of OpenGL vertex coordinates. See how Processing handles this.