Skip to content

Commit 7caa82e

Browse files
committed
Remove debug flag from JPEGImage.cc
1 parent ea8c7c5 commit 7caa82e

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

src/JPEGImage.cc

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
along with this program. If not, see <http://www.gnu.org/licenses/>.
1717
*/
1818

19-
#define JPEG_DEBUG
2019

2120
#include "JPEGImage.h"
2221
#include "Logger.h"
@@ -132,7 +131,7 @@ void JPEGImage::loadImageInfo( int seq, int ang ){
132131
Timer timer;
133132
timer.start();
134133
#endif
135-
134+
136135
// Save first resolution level
137136
image_widths.clear();
138137
image_heights.clear();
@@ -254,7 +253,7 @@ RawTile JPEGImage::getTile( int seq, int ang, unsigned int res, int layers, unsi
254253

255254
unsigned int tw = tile_widths[0];
256255
unsigned int th = tile_heights[0];
257-
256+
258257
// Get the width and height for last row and column tiles
259258
unsigned int rem_x = image_widths[vipsres] % tile_widths[0];
260259
unsigned int rem_y = image_heights[vipsres] % tile_heights[0];
@@ -342,7 +341,7 @@ void JPEGImage::process( unsigned int res, int layers, int xoffset, int yoffset,
342341
// The libjpeg API can perform efficient scaling on the raw DCT co-efficients.
343342
// The supported scaling ratios are M/8 with all M from 1 to 16. In other words
344343
// we can shrink to a max of 1/8.
345-
// Note that 1/8 is the 4th resolution level with index=3 (0=1/1, 1=1/2, 2=1/4, 3=1/8)
344+
// Note that 1/8 is the 4th resolution level with index=3 (0=1/1, 1=1/2, 2=1/4, 3=1/8)
346345
// So calculate which libjpeg scaling to use and what extra scaling, if any, we also need to
347346
// apply ourselves.
348347
unsigned int factor = 1; // Downsampling factor - set it to default value
@@ -362,7 +361,7 @@ void JPEGImage::process( unsigned int res, int layers, int xoffset, int yoffset,
362361
#ifdef JPEG_DEBUG
363362
logfile << "JPEG :: Using sub-resolution at scale 1/8 with position " << x0 << "x" << y0
364363
<< " and size " << w0 << "x" << h0 << endl;
365-
#endif
364+
#endif
366365
}
367366

368367

@@ -375,7 +374,7 @@ void JPEGImage::process( unsigned int res, int layers, int xoffset, int yoffset,
375374
// Set libjpeg scaling (limited to 1/8)
376375
cinfo.scale_num = 1;
377376
cinfo.scale_denom = 1 << vipsres;
378-
377+
379378
// Start decompression
380379
jpeg_start_decompress( &cinfo );
381380

@@ -406,7 +405,7 @@ void JPEGImage::process( unsigned int res, int layers, int xoffset, int yoffset,
406405
// Byte width of the line of pixels we want
407406
unsigned int tile_stride = w0 * cinfo.output_components;
408407

409-
408+
410409
// If we have to perform manual re-scaling, create a temporary buffer large enough for the data
411410
if( factor > 1 ){
412411
buffer = (unsigned char*) malloc( tile_stride * h0 );

0 commit comments

Comments
 (0)