Changeset 115 for abuse/trunk/src/imlib/glread.cpp
- Timestamp:
- Mar 16, 2008, 10:51:54 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
abuse/trunk/src/imlib/glread.cpp
r56 r115 41 41 while (first<=last) 42 42 { 43 sub->lock(); 43 44 for (y=0;(int)y<(int)height;y++) 44 45 { … … 46 47 sub->unpack_scanline(y); 47 48 } 49 sub->unlock(); 48 50 sub->put_image(im,(first%32)*width,(first/32)*height); 49 51 first++; … … 55 57 image *read_pic(char *fn, palette *&pal) 56 58 { 57 image *im ;59 image *im = NULL; 58 60 char x[4],bpp; 59 61 uint8_t *sl=NULL,esc,c,n,marker,vmode; … … 61 63 int xx,yy; 62 64 FILE *fp; 63 im=NULL;64 65 fp=fopen(fn,"rb"); 65 66 … … 74 75 { fclose(fp); set_error(imFILE_CORRUPTED); return NULL; } 75 76 76 im =new image(w,h);77 im = new image(w, h); 77 78 78 79 fread(&vmode,1,1,fp); … … 92 93 93 94 yy=h; xx=w; 95 96 im->lock(); 94 97 95 98 while (blocks-- && w>=1 && yy>=0) … … 137 140 } 138 141 } 142 143 im->unlock(); 144 139 145 fclose(fp); 140 146 return im;
Note: See TracChangeset
for help on using the changeset viewer.