d3_event_init(&d3_l);
#endif
+#ifdef USE_DFB_API
strcpy(a_txt,"args:");
sprintf(s_txt,"steps: %d",my_info.steps);
sprintf(r_txt,"pressure range: %d",my_info.range);
arg_v[22]=cd_txt;
arg_v[23]=cd2_txt;
arg_v[24]=dr_txt;
+#endif
if(!strcmp(l_file,""))
{
z_c=get_rand_lgp(d3_l.max_z,my_info.a_el,my_info.b_el);
distrib_c(&d3_l,my_info.d_r,my_info.a_cd,my_info.b_cd);
process_cell(&d3_l,x_c,y_c,z_c,my_info.range,my_info.a_ap,my_info.b_ap,&(my_info.cc));
+#ifdef USE_DFB_API
if(i%refresh==0)
{
sprintf(x_txt,"x: %d",x+1);
sprintf(conc_txt,"conc: %d",*(d3_l.extra+x+y*d3_l.max_x+z*d3_l.max_x*d3_l.max_y));
sprintf(steps_txt,"step: %d",i);
sprintf(cc_txt,"total c: %d",my_info.cc);
-#ifdef USE_DFB_API
d3_lattice_draw(&d3_l,x,y,z,24,arg_v);
-#endif
- // scan_event(&d3_l,&x,&y,&z,&quit,&escape);
}
+#endif
if(i%resave==0 && strcmp(s_file,"") && resave!=0)
{
sprintf(s_file_tmp,"%s_%d_of_%d",s_file,i,my_info.steps);
save_to_file(s_file_tmp,&d3_l,&my_info);
+#ifdef NODFB
+ printf("saved %s\n",s_file_tmp);
+#endif
}
i++;
}
}
- if(strcmp(s_file,"")) save_to_file(s_file,&d3_l,&my_info);
+ if(strcmp(s_file,""))
+ {
+ printf("saved %s\n",s_file);
+ save_to_file(s_file,&d3_l,&my_info);
+ }
+#ifdef USE_DFB_API
while((quit==0) && (escape==0) && (nowait==0))
{
sprintf(x_txt,"x: %d",x+1);
sprintf(conc_txt,"conc: %d",*(d3_l.extra+x+y*d3_l.max_x+z*d3_l.max_x*d3_l.max_y));
strcpy(steps_txt,"step: end!");
sprintf(cc_txt,"total c: %d",my_info.cc);
-#ifdef USE_DFB_API
d3_lattice_draw(&d3_l,x,y,z,24,arg_v);
scan_event(&d3_l,&x,&y,&z,&quit,&escape);
-#endif
}
-#ifdef USE_DFB_API
d3_lattice_release(&d3_l);
#endif