mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-27 00:33:48 -05:00
Load raster category names fix
This commit is contained in:
parent
d901e5065a
commit
c59cd92c12
@ -63,11 +63,14 @@ QList<QgsColorRampShader::ColorRampItem> QgsGdalProviderBase::colorTable( GDALDa
|
||||
// load category labels
|
||||
char ** categoryNames = GDALGetRasterCategoryNames( myGdalBand );
|
||||
QVector<QString> labels;
|
||||
int i = 0;
|
||||
while ( categoryNames[i] )
|
||||
if ( categoryNames )
|
||||
{
|
||||
labels.append( QString( categoryNames[i] ) );
|
||||
i++;
|
||||
int i = 0;
|
||||
while ( categoryNames[i] )
|
||||
{
|
||||
labels.append( QString( categoryNames[i] ) );
|
||||
i++;
|
||||
}
|
||||
}
|
||||
|
||||
int myEntryCount = GDALGetColorEntryCount( myGdalColorTable );
|
||||
|
Loading…
x
Reference in New Issue
Block a user