+ int lasty = img->height - 1;
+ for(;y<newheight;y++) {
+ for(x=0;x<newwidth;x++) {
+ data[(y*newwidth+x)*4+0] = img->data[lasty*img->width+x].r;
+ data[(y*newwidth+x)*4+1] = img->data[lasty*img->width+x].g;
+ data[(y*newwidth+x)*4+2] = img->data[lasty*img->width+x].b;
+ data[(y*newwidth+x)*4+3] = img->data[lasty*img->width+x].a;
+ }
+ }
+
+ glEnable(GL_TEXTURE_2D);
+ glBindTexture(GL_TEXTURE_2D, i->texID);
+ glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, i->width, i->height, 0, GL_RGBA, GL_UNSIGNED_BYTE, data);
+
+ return i;
+};
+
+void opengl_fillbitmap(struct _gfxdevice*dev, gfxline_t*line, gfximage_t*img, gfxmatrix_t*matrix, gfxcxform_t*cxform)
+{
+ dbg("fillbitmap");
+ internal_t*i = (internal_t*)dev->internal;
+ char running = 0;
+ int len = 0;
+ double*xyz=0;
+ gfxline_t*l=0;
+ glColor4f(1.0,0,0.7,1.0);
+
+ i->currentz ++;
+
+ imgopengl_t* txt = addTexture(img);