Commit 371bf3395c076f4d36e6bcc1b2a0f81301ab701a

Authored by David Mayerich
1 parent 5a5359da

added a progress bar to generating band images

Showing 1 changed file with 4 additions and 1 deletions   Show diff stats
stim/envi/binary.h
... ... @@ -274,8 +274,10 @@ public:
274 274 for(unsigned int i = 0; i<N; i++){
275 275 file.read((char*)(p+i), sizeof(T));
276 276 file.seekg(jump, std::ios::cur);
  277 + thread_data = (double)i / N * 100;
277 278 }
278 279  
  280 + thread_data = 100;
279 281 return true;
280 282  
281 283  
... ... @@ -297,12 +299,13 @@ public:
297 299  
298 300 file.seekg(R[0] * n * sizeof(T), std::ios::beg);
299 301 for (unsigned i = 0; i < R[2]; i++){
300   -
  302 + thread_data = (double)i / R[2] * 100;
301 303 file.read((char *)(p + i * R[0]), L);
302 304 file.seekg( jump, std::ios::cur);
303 305 std::cout<<i<<" ";
304 306 }
305 307  
  308 + thread_data = 100;
306 309 return true;
307 310 }
308 311  
... ...