Opened 14 years ago

Closed 13 years ago

#2440 closed enhancement (fixed)

Better support for raster providers

Reported by: lutra Owned by: nobody
Priority: minor: annoyance Milestone: Version 1.7.0
Component: Data Provider Version: Trunk
Keywords: Cc: rblazek, pcav
Must Fix for Release: No Platform: All
Platform Version: Awaiting user input: no

Description

The new GRASS provider solved many problems, especially a few nasty bugs that made many GRASS modules not usable under Vista and Seven (caused qgis to crash). See for example #1945 and #2028

Moreover it "solved" a qgis critical bug that was not yet spotted: basically after closing a mapset (and leaving a GRASS layer in the legend), if click on the canvas with a tool such the identify qgis crashes. You can test this bug in qgis 1.4.

Nevertheless there are a few consequences in the qgis raster layer properties that would need a fix (in the provider or in the properties or maybe both).

The synptoms I see are:

A) making GRASS raster pixels transparent (properties -> transparency) does not work anymore.

B) changing the colormap (freakout, pseudocolor, colormap) does not work anymore.

C) if you tested A) and/or B) you probably already noticed that now, in the qgis raster layer properties, the "render as" property (and the below "RGB more..." or "Single Band Properties") are messed:

*) GRASS raster should always open as "single band gray" and the "three band color" should be greyed out and not available. In trunk the "render as" property for GRASS rasters shows by default the "three band color" selected (that does not make sense). You can then choose "single band gray", close the properties and then if you'll open it again "three band color" will show correctly greyed out.

*) Even when you manually choose "single band gray", the "gray band" dropdown is not populated (should show two options "band1" and "not set") and the "color map" dropdown does not show the correct otion.

*) The colormap is never shown in the appropriate tab.

Change History (6)

comment:1 by rblazek, 14 years ago

Summary: new GRASS raster provider and QGIS raster layer properties: changes neededBetter support for raster providers

All the above problems cannot be solved in GRASS raster data provider. At the moment it does just what it can, it is it gives a picture to the layer.

QgsRasterDataProvider and QgsRasterLayer must first be rewritten to really support raster data providers. Current implementation is just mess of GDAL raster layer + WMS hack.

comment:2 by lutra, 14 years ago

Well, then I believe that until we have a "Better support for raster providers" the qgis raster layer properties for GRASS rasters should be changed in order to avoid show wrong/confusing things.

Symbology of GRASS raster can be done trough GRASS and the plugin, so probably is possible to make transparent pixels of a certain color.

comment:3 by lutra, 14 years ago

see also #2794

comment:4 by jef, 14 years ago

Must Fix for Release: YesNo
Priority: major: does not work as expectedminor: annoyance
Type: bugenhancement

GRASS UI aspects are covered by #2794, which can be considered a bug. This is more a refactoring request for the raster layer/providers, so I'm downgrading it.

See also http://www.qgis.org/wiki/Raster_Refactor_RFC and http://www.qgis.org/wiki/Raster_Development_Page

comment:5 by pcav, 14 years ago

Milestone: Version 1.5.0Version 1.6.0

comment:6 by lutra, 13 years ago

Resolution: fixed
Status: newclosed

In the latest revisions and with the new Radim work on rasters I see all the above as fixed.

Note: See TracTickets for help on using tickets.