[QGIS Commit] r8668 - trunk/qgis/src/core/raster

svn_qgis at osgeo.org svn_qgis at osgeo.org
Sat Jun 21 15:08:35 EDT 2008


Author: jef
Date: 2008-06-21 15:08:34 -0400 (Sat, 21 Jun 2008)
New Revision: 8668

Modified:
   trunk/qgis/src/core/raster/qgsrasterlayer.h
Log:
fix a few comment typos

Modified: trunk/qgis/src/core/raster/qgsrasterlayer.h
===================================================================
--- trunk/qgis/src/core/raster/qgsrasterlayer.h	2008-06-21 17:27:28 UTC (rev 8667)
+++ trunk/qgis/src/core/raster/qgsrasterlayer.h	2008-06-21 19:08:34 UTC (rev 8668)
@@ -21,7 +21,7 @@
  *  onto the mapcanvas
  *
  *  The qgsrasterlayer class makes use of gdal for data io, and thus supports
- *  any gdal supported format. The constructor attemtps to infer what type of
+ *  any gdal supported format. The constructor attempts to infer what type of
  *  file (RASTER_LAYER_TYPE) is being opened - not in terms of the file format (tif, ascii grid etc.)
  *  but rather in terms of whether the image is a GRAYSCALE, PALETTED or MULTIBAND,
  *
@@ -31,18 +31,18 @@
  *
  *  SINGLE_BAND_GRAY -> a GRAYSCALE layer drawn as a range of gray colors (0-255)
  *  SINGLE_BAND_PSEUDO_COLOR -> a GRAYSCALE layer drawn using a pseudocolor algorithm
- *  PALETTED_SINGLE_BAND_GRAY -> a PALLETED layer drawn in gray scale (using only one of the color components)
- *  PALETTED_SINGLE_BAND_PSEUDO_COLOR -> a PALLETED layer having only one of its color components rendered as psuedo color
- *  PALETTED_MULTI_BAND_COLOR -> a PALLETED image where the bands contains 24bit color info and 8 bits is pulled out per color
+ *  PALETTED_SINGLE_BAND_GRAY -> a PALETTED layer drawn in gray scale (using only one of the color components)
+ *  PALETTED_SINGLE_BAND_PSEUDO_COLOR -> a PALETTED layer having only one of its color components rendered as psuedo color
+ *  PALETTED_MULTI_BAND_COLOR -> a PALETTED image where the bands contains 24bit color info and 8 bits is pulled out per color
  *  MULTI_BAND_SINGLE_BAND_GRAY -> a layer containing 2 or more bands, but using only one band to produce a grayscale image
  *  MULTI_BAND_SINGLE_BAND_PSEUDO_COLOR -> a layer containing 2 or more bands, but using only one band to produce a pseudocolor image
  *  MULTI_BAND_COLOR -> a layer containing 2 or more bands, mapped to the three RGBcolors. In the case of a multiband with only two bands, one band will have to be mapped to more than one color
  *
  *  Each of the above mentioned drawing styles is implemented in its own draw* function.
  *  Some of the drawing styles listed above require statistics about the layer such 
- *  as the min / max / mean / stddev etc. Statics for a band can be gathered using the 
+ *  as the min / max / mean / stddev etc. statistics for a band can be gathered using the 
  *  getRasterBandStats function. Note that statistics gathering is a slow process and 
- *  evey effort should be made to call this function as few times as possible. For this
+ *  every effort should be made to call this function as few times as possible. For this
  *  reason, qgsraster has a vector class member to store stats for each band. The 
  *  constructor initialises this vector on startup, but only populates the band name and
  *  number fields.
@@ -52,10 +52,10 @@
  *  applied to undefined layers to normalise the data into the 0-255 range.
  *
  *  A qgsrasterlayer band can be referred to either by name or by number (base=1). It
- *  should be noted that band names as stored in datafiles may not be uniqe, and 
+ *  should be noted that band names as stored in datafiles may not be unique, and 
  *  so the rasterlayer class appends the band number in brackets behind each band name.
  *  
- *  Sample useage of the QgsRasterLayer class:
+ *  Sample usage of the QgsRasterLayer class:
  *
  *     QString myFileNameQString = "/path/to/file";
  *     QFileInfo myFileInfo(myFileNameQString);
@@ -86,7 +86,7 @@
  *    }
  *
  * You can combine layer type detection with the setDrawingStyle method to override the default drawing style assigned
- * when a layer is loaded.:
+ * when a layer is loaded:
  *
  *    if (rasterLayer->getRasterLayerType()==QgsRasterLayer::MULTIBAND)
  *    {
@@ -101,18 +101,18 @@
  *      myRasterLayer->setDrawingStyle(QgsRasterLayer::SINGLE_BAND_PSEUDO_COLOR);
  *    }
  * 
- *  Raster layers can also have an aribitary level of transparency defined, and have their
- *  colour palettes inverted using the setTransparency and setInvertHistogramFlag methods. 
+ *  Raster layers can also have an arbitary level of transparency defined, and have their
+ *  color palettes inverted using the setTransparency and setInvertHistogramFlag methods. 
  * 
- *  Pseudocolour images can have their output adjusted to a given number of standard
+ *  Pseudocolor images can have their output adjusted to a given number of standard
  *  deviations using the setStdDevsToPlot method.
  * 
  *  The final area of functionality you may be interested in is band mapping. Band mapping
- *  allows you to choose arbitary band -> colour mappings and is applicable only to PALETTE
- *  and MULTIBAND rasters, There are four mappings that can be made : red, green, blue and gray.
- *  Mappings are non exclusive. That is a given band can be assigned to no, some or all 
- *  colour mappings. The constructor sets sensible defaults for band mappings but these can be
- *  overridden at run time using the setRedBandName,setGreenBandName,setBlueBandName and setGrayBandName 
+ *  allows you to choose arbitary band -> color mappings and is applicable only to PALETTE
+ *  and MULTIBAND rasters, There are four mappings that can be made: red, green, blue and gray.
+ *  Mappings are non-exclusive. That is a given band can be assigned to no, some or all 
+ *  color mappings. The constructor sets sensible defaults for band mappings but these can be
+ *  overridden at run time using the setRedBandName, setGreenBandName, setBlueBandName and setGrayBandName 
  *  methods.
  */
  
@@ -207,7 +207,7 @@
      *
      * -Determine whether the layer is gray, paletted or multiband.
      *
-     * -Assign sensible defaults for the red,green, blue and gray bands.
+     * -Assign sensible defaults for the red, green, blue and gray bands.
      *
      * -
      * */
@@ -215,11 +215,11 @@
                    const QString &  baseName = QString::null,
                    bool loadDefaultStyleFlag = true );
 
-    /** \brief The destuctor.  */
+    /** \brief The destructor.  */
     ~QgsRasterLayer();
 
     /** \brief  A list containing one RasterBandStats struct per raster band in this raster layer.
-     * Note that while very RasterBandStats element will have the name and number of its associated
+     * Note that while every RasterBandStats element will have the name and number of its associated
      * band populated, any additional stats are calculated on a need to know basis.*/
     typedef QList<QgsRasterBandStats> RasterStatsList;
 
@@ -227,7 +227,7 @@
     /** \brief  A list containing one RasterPyramid struct per raster band in this raster layer.
      * POTENTIAL pyramid layer. How this works is we divide the height
      * and width of the raster by an incrementing number. As soon as the result
-     * of the division is <=256 we stop allowing RasterPyramid stracuts
+     * of the division is <=256 we stop allowing RasterPyramid structs
      * to be added to the list. Each time a RasterPyramid is created
      * we will check to see if a pyramid matching these dimensions already exists
      * in the raster layer, and if so mark the exists flag as true. */
@@ -269,10 +269,10 @@
     /** \brief Draws a thumbnail of the rasterlayer into the supplied pixmap pointer */
      void drawThumbnail(QPixmap * theQPixmap);
 
-    /** \brief Get an 8x8 pixmap of the colour palette. If the layer has no palette a white pixmap will be returned. */
+    /** \brief Get an 8x8 pixmap of the color palette. If the layer has no palette a white pixmap will be returned. */
      QPixmap getPaletteAsPixmap();
      
-    /** \brief This is called when the view on the rasterlayer needs to be refreshed (redrawn).   
+    /** \brief This is called when the view on the raster layer needs to be refreshed (redrawn).   
      */
     bool draw(QgsRenderContext& renderContext);
 
@@ -354,8 +354,8 @@
     const  QgsRasterBandStats getRasterBandStats(int);
     /** \brief  Check whether a given band number has stats associated with it */
     bool hasStats(int theBandNoInt);
-    /** \brief Overloaded method that also returns stats for a band, but uses the band colour name
-    *    Note this approach is not recommeneded because it is possible for two gdal raster
+    /** \brief Overloaded method that also returns stats for a band, but uses the band color name
+    *    Note this approach is not recommended because it is possible for two gdal raster
     *    bands to have the same name!
     */
     const  QgsRasterBandStats getRasterBandStats(const QString &);
@@ -369,12 +369,12 @@
     bool hasBand(const QString &  theBandName);
     /** \brief Call any inline image manipulation filters */
     void filterLayer(QImage * theQImage);
-    /** \brief Accessor for red band name (allows alternate mappings e.g. map blue as red colour). */
+    /** \brief Accessor for red band name (allows alternate mappings e.g. map blue as red color). */
     QString getRedBandName()
     {
         return mRedBandName;
     }
-    /** \brief Mutator for red band name (allows alternate mappings e.g. map blue as red colour). */
+    /** \brief Mutator for red band name (allows alternate mappings e.g. map blue as red color). */
     void setRedBandName(const QString & theBandNameQString);
     // 
     // Accessor and mutator for green band name
@@ -594,13 +594,13 @@
     //
     // Accessor and mutator for the color shader algorithm
     //
-    /** \brief Accessor for colour shader algorithm. */
+    /** \brief Accessor for color shader algorithm. */
     QgsRasterLayer::COLOR_SHADING_ALGORITHM getColorShadingAlgorithm()
     {
         return mColorShadingAlgorithm;
     }
     
-    /** \brief Accessor for colour shader algorithm. */
+    /** \brief Accessor for color shader algorithm. */
     QString getColorShadingAlgorithmAsQString();
     
     /** \brief Mutator for color shader algorithm. */
@@ -662,7 +662,7 @@
     void setDrawingStyle(const DRAWING_STYLE &  theDrawingStyle) {drawingStyle=theDrawingStyle;}
     /** \brief Overloaded version of the above function for convenience when restoring from xml.
      *
-     * Implementaed mainly for serialisation / deserialisation of settings to xml.
+     * Implemented mainly for serialisation / deserialisation of settings to xml.
      * NOTE: May be deprecated in the future! Use alternate implementation above rather.
      * */
     void setDrawingStyle(const QString & theDrawingStyleQString);
@@ -675,7 +675,7 @@
       MULTIBAND    
     } rasterLayerType;
     //
-    //accessor and for raster layer type (READ ONLY)
+    // Accessor and for raster layer type (READ ONLY)
     //
     /** \brief  Accessor for raster layer type (which is a read only property) */
     RASTER_LAYER_TYPE getRasterLayerType() { return rasterLayerType; }
@@ -835,7 +835,7 @@
      */
     //void const convertTo();
     /**
-     * Mainly inteded for use in propogating progress updates from gdal up to the parent app.
+     * Mainly intended for use in propagating progress updates from gdal up to the parent app.
      **/
     void updateProgress(int,int);
 
@@ -855,16 +855,16 @@
                           void *theData);    
 */
 
-  /** Populate the histogram vector for a given layer
-  * @param theBandNoInt - which band to compute the histogram for
-  * @param theBinCountInt - how many 'bins' to categorise the data into
-  * @param theIgnoreOutOfRangeFlag - whether to ignore values that are out of range (default=true)
-  * @param theThoroughBandScanFlag - whether to visit each cell when computing the histogram (default=false)
-  */
-  void populateHistogram(int theBandNoInt, 
-                         int theBinCountInt=256,
-                         bool theIgnoreOutOfRangeFlag=true,
-                         bool theThoroughBandScanFlag=false);
+    /** Populate the histogram vector for a given layer
+    * @param theBandNoInt - which band to compute the histogram for
+    * @param theBinCountInt - how many 'bins' to categorise the data into
+    * @param theIgnoreOutOfRangeFlag - whether to ignore values that are out of range (default=true)
+    * @param theThoroughBandScanFlag - whether to visit each cell when computing the histogram (default=false)
+    */
+    void populateHistogram(int theBandNoInt, 
+                           int theBinCountInt=256,
+                           bool theIgnoreOutOfRangeFlag=true,
+                           bool theThoroughBandScanFlag=false);
 
     /** \brief Color table 
      *  \param band number
@@ -1014,13 +1014,13 @@
     
     /** \brief  Raster width. */
     int mRasterXDim;
-    /** \brief  Raster Height. */
+    /** \brief  Raster height. */
     int mRasterYDim;
     /** \brief Cell value representing no data. e.g. -9999  */
     double mNoDataValue;
     /** \brief Flag indicating if the nodatavalue is valid*/
     bool mValidNoDataValue;
-    /** \brief Flag to indicate whether debug infor overlay should be rendered onto the raster.  */
+    /** \brief Flag to indicate whether debug info overlay should be rendered onto the raster.  */
     bool mDebugOverlayFlag;
     /** \brief Pointer to the gdaldataset.  */
     GDALDatasetH mGdalBaseDataset;
@@ -1029,7 +1029,7 @@
     /** \brief Values for mapping pixel to world coordinates. Contents of
      * this array are the same as the gdal adfGeoTransform */
     double mGeoTransform[6];
-    /** \brief Flag indicating whether the colour of pixels should be inverted or not.  */
+    /** \brief Flag indicating whether the color of pixels should be inverted or not.  */
     bool mInvertPixelsFlag;
     /** \brief Number of stddev to plot (0) to ignore. Not applicable to all layer types.  */
     double mStandardDeviations;
@@ -1037,7 +1037,7 @@
      * The typedef for this is defined above before class declaration
      */
     RasterStatsList mRasterStatsList;
-    /** \brief List containging the contrast enhancements for each band */
+    /** \brief List containing the contrast enhancements for each band */
     ContrastEnhancementList mContrastEnhancementList;
     /** \brief The contrast enhancement algorithm being used */
     QgsContrastEnhancement::CONTRAST_ENHANCEMENT_ALGORITHM mContrastEnhancementAlgorithm;
@@ -1055,7 +1055,7 @@
     QgsRasterTransparency mRasterTransparency;
     /** \brief The band to be associated with transparency.  */
     QString mTransparencyBandName;
-    /** \brief The band to be associated with the grayscale only ouput - usually 1.  */
+    /** \brief The band to be associated with the grayscale only output - usually 1.  */
     QString mGrayBandName;
     /** \brief Whether this raster has overviews / pyramids or not */
     bool hasPyramidsFlag;
@@ -1068,7 +1068,7 @@
     /** \brief Flag to indicate of the min max values are actual or estimates/user defined */
     bool mGrayActualMinimumMaximum;
     /** \brief This list holds a series of RasterPyramid structs
-     * which store infomation for each potential pyramid level for this raster.*/
+     * which store information for each potential pyramid level for this raster.*/
     RasterPyramidList mPyramidList;
 
 /*
@@ -1124,7 +1124,7 @@
   /**Flag indicating wheter the layer is in editing mode or not*/
   bool mEditable;
   
-  /**Flag indicating wheter the layer has been modified since the last commit*/
+  /**Flag indicating whether the layer has been modified since the last commit*/
   bool mModified;
 
   //! Timestamp, the last modified time of the data source when the layer was created



More information about the QGIS-commit mailing list