If you are having performance issues I would also look at trying to convert your immediate-mode rendering into vertex arrays or vertex buffers. Also I would get rid of that GL_POLYGON and make it a triangle strip instead.
Immediate mode is slower full-stop but right now you are putting down to opengl 32 floats for each polygon.
+ 6 for translate/scale
+16 for the shear matrix.
So right now ignoring everything else you are sending down 54 floats per polygon, plus some additional overhead for pushing and popping matrices, setting polygon mode, etc...
Now just sending down floats isn't necessarily the big deal but it is an indicator.
First off you can combine the translate/scale/shear into a single matrix so you only need 16 floats to specify the modelview matrix transform.
Secondly if you go back to using 1 texture per image, then you can make a single vertex buffer object that works for all your stuff:
uv=(0,1) uv=(1,1)
vt=(0,1) vt=(0,1)
uv=(0,0) uv=(1,0)
vt=(0,0) vt=(0,0)
Set it up like this:
Then render it like this:
Do this once per frame:
glBindBuffer(GL_ARRAY_BUFFER, floatBufferOfVerts);
glVertexPointer(2, GL_FLOAT, 0, 0);
glBindBuffer(GL_ARRAY_BUFFER, floatBufferOfUvs);
glTexCoordPointer(2, GL_FLOAT, 0, 0);
glActiveTexture(GL_TEXTURE0);
glClientActiveTexture(GL_TEXTURE0);
glEnableClientState(GL_TEXTURE_COORD_ARRAY);
for each of your visible textures, do this:
glBindTexture(GL_TEXTURE_2D, textured)
for each of the quads of that texture, do this:
glLoadMatrix(...)
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
.
.
That way you end up with a far more optimized render strategy. You only send down 16 floats per quad, + the glDrawArrays() command.
Furthermore, if your vegetables are all blowing the same way in the wind (the shear matrix is identical), you could get try loading that matrix at the beginning of the frame and then just translating/scaling against it for each quad.
This is all just pseudocode off the top of my head but I think it is a more performant way to render what you are doing. An important feature of what I wrote is that you have sorted all your renders by texture in advance so you only have as many texture binds as you have textures, no wasted effort there. Hope that helps.
At the very least try just converting your immediate-mode renders to vertex buffers and see if that helps.
JW