|
|
@ -786,7 +786,7 @@ void gen_jpegfile(char *fname,int32_t quality,uint8_t *bitmap,int32_t width,int3 |
|
|
|
if ( (outfile= fopen(fname,"wb")) == NULL) |
|
|
|
{ |
|
|
|
fprintf(stderr, "can't open %s\n", fname); |
|
|
|
iguana_exit(0,0); |
|
|
|
return; |
|
|
|
} |
|
|
|
jpeg_stdio_dest(&cinfo, outfile); |
|
|
|
cinfo.image_width = width; /* image width and height, in pixels */ |
|
|
@ -874,8 +874,8 @@ char *stats_prices(char *symbol,char *dest,struct DEXstats_disp *prices,int32_t |
|
|
|
if ( i != 2048 ) |
|
|
|
i++; |
|
|
|
sum /= i; |
|
|
|
uint32_t height = 400,*bitmap = calloc(sizeof(*bitmap),3 * height * numdates*24); |
|
|
|
output_line(0,sum,output,i,0xff00ff,bitmap,numdates*24,height) |
|
|
|
uint32_t height = 400; uint8_t *bitmap = calloc(sizeof(*bitmap),3 * height * numdates*24); |
|
|
|
output_line(0,sum,output,i,0xff00ff,bitmap,numdates*24,height); |
|
|
|
sprintf(fname,"%s/bitmaps/%s_%s.jpg",STATS_DEST,symbol,dest), OS_portable_path(fname); |
|
|
|
gen_jpegfile(fname,1,bitmap,numdates*24,height); |
|
|
|
free(bitmap); |
|
|
|