~ubuntu-branches/ubuntu/intrepid/digikam/intrepid

« back to all changes in this revision

Viewing changes to digikam/libs/greycstoration/greycstorationiface.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Mark Purcell
  • Date: 2008-07-17 20:25:39 UTC
  • mfrom: (1.3.2 upstream)
  • mto: This revision was merged to the branch mainline in revision 39.
  • Revision ID: james.westby@ubuntu.com-20080717202539-ttj4and3ds1ldgn1
Tags: upstream-0.9.4
ImportĀ upstreamĀ versionĀ 0.9.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
 * Date        : 2007-12-03
7
7
 * Description : Greycstoration interface.
8
8
 *
9
 
 * Copyright (C) 2007 by Gilles Caulier <caulier dot gilles at gmail dot com>
 
9
 * Copyright (C) 2007-2008 by Gilles Caulier <caulier dot gilles at gmail dot com>
10
10
 *
11
11
 * This program is free software; you can redistribute it
12
12
 * and/or modify it under the terms of the GNU General
48
48
#include <pthread.h>
49
49
#endif
50
50
 
51
 
#include "CImg.h"
52
 
using namespace cimg_library;
53
 
 
54
51
/** Number of children threads used to run Greystoration algorithm */ 
55
52
#define COMPUTATION_THREAD 2
56
53
 
63
60
#include "greycstorationsettings.h"
64
61
#include "greycstorationiface.h"
65
62
 
 
63
// CImg includes.
 
64
 
 
65
#include "CImg.h"
 
66
 
 
67
using namespace cimg_library;
 
68
 
66
69
namespace Digikam
67
70
{
68
71
 
378
381
    const bool anchor       = true;   // Anchor original pixels.
379
382
    const unsigned int init = 5;      // Initial estimate (1=block, 3=linear, 5=bicubic).
380
383
 
381
 
    const CImgStats stats(d->img, false);
382
 
    DDebug() << "Resizing image: size " << d->img.width << " x " << d->img.height 
383
 
             << ", value range [" << stats.min << " , " << stats.max << "]" << endl;
384
 
 
385
384
    int w = m_destImage.width();
386
385
    int h = m_destImage.height();
387
386