~ubuntu-branches/ubuntu/wily/qgis/wily

« back to all changes in this revision

Viewing changes to src/core/raster/qgsfreakoutshader.h

  • Committer: Bazaar Package Importer
  • Author(s): Johan Van de Wauw
  • Date: 2010-07-11 20:23:24 UTC
  • mfrom: (3.1.4 squeeze)
  • Revision ID: james.westby@ubuntu.com-20100711202324-5ktghxa7hracohmr
Tags: 1.4.0+12730-3ubuntu1
* Merge from Debian unstable (LP: #540941).
* Fix compilation issues with QT 4.7
* Add build-depends on libqt4-webkit-dev 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* **************************************************************************
 
2
                qgsfreakoutshader.h -  description
 
3
                       -------------------
 
4
begin                : Fri Dec 28 2007
 
5
copyright            : (C) 2007 by Peter J. Ersts
 
6
email                : ersts@amnh.org
 
7
 
 
8
This class contains code that was originally part of the larger QgsRasterLayer
 
9
class originally created circa 2004 by T.Sutton, Gary E.Sherman, Steve Halasz
 
10
****************************************************************************/
 
11
 
 
12
/* **************************************************************************
 
13
 *                                                                         *
 
14
 *   This program is free software; you can redistribute it and/or modify  *
 
15
 *   it under the terms of the GNU General Public License as published by  *
 
16
 *   the Free Software Foundation; either version 2 of the License, or     *
 
17
 *   (at your option) any later version.                                   *
 
18
 *                                                                         *
 
19
 ***************************************************************************/
 
20
 
 
21
#ifndef QGSFREAKOUTSHADER_H
 
22
#define QGSFREAKOUTSHADER_H
 
23
 
 
24
#include "qgsrastershaderfunction.h"
 
25
 
 
26
/** \ingroup core
 
27
  * A colorful false color shader that will frighten your granny and make your dogs howl.
 
28
  */
 
29
class CORE_EXPORT QgsFreakOutShader : public QgsRasterShaderFunction
 
30
{
 
31
 
 
32
  public:
 
33
    QgsFreakOutShader( double theMinimumValue = 0.0, double theMaximumValue = 255.0 );
 
34
 
 
35
    /** \brief generates and new RGB value based on one input value */
 
36
    bool shade( double, int*, int*, int* );
 
37
 
 
38
    /** \brief generates and new RGB value based on original RGB value */
 
39
    bool shade( double, double, double, int*, int*, int* );
 
40
 
 
41
    /** \brief Set the maximum value */
 
42
    void setMaximumValue( double );
 
43
 
 
44
    /** \brief Return the minimum value */
 
45
    void setMinimumValue( double );
 
46
 
 
47
  private:
 
48
    void setClassBreaks();
 
49
 
 
50
    double mBreakSize;
 
51
    double mClassBreakMin1;
 
52
    double mClassBreakMax1;
 
53
    double mClassBreakMin2;
 
54
    double mClassBreakMax2;
 
55
    double mClassBreakMin3;
 
56
};
 
57
 
 
58
#endif