eyecatch

QGIS 3.30 New Features: Major Raster Updates

Published: Last updated:
This article uses QGIS 3.30. The current long-term release (LTR) is 3.44.

What you'll learn


  • New features in QGIS 3.30

Recommended for


  • Anyone interested in the latest QGIS features

Introduction

QGIS 3.30 was released on March 4, 2023.

As usual, the release includes a huge number of updates. This article picks three raster-related updates that stand out.

The release name “'s-Hertogenbosch” comes from a city of the same name in the southern Netherlands.

Header image with the QGIS 3.30 's-Hertogenbosch logo over an old map of the city
This article is a revised version of the “QGIS Blog” content that was published on the MIERUNE Inc. website.

Raster MapTips

QGIS has a feature called MapTips, but until now it worked only with vector layers.

(A MapTip is the small display that appears when you hover the mouse over a feature.)

A purple polygon layer with a MapTip pop-up labeled ‘東京都’ (Tokyo) on the map

MapTips appear when Show Map Tips is on.

The Show Map Tips button in the toolbar, highlighted with its tooltip

You can change the information shown in the layer properties.

The Display tab of a vector layer’s properties, choosing the field shown in MapTips

QGIS 3.30 adds MapTips for raster layers!

Open the layer properties of a raster layer and go to the Display tab.

The Display tab in a raster layer’s properties with the empty HTML Map Tip field

You control the display with the text you enter in HTML Map Tip. Start by entering the following:

[% raster_value( 'L03_b_14_5339_7f3bbcba_72d7_4acc_a63f_695b2ddf67e6', 1, @layer_cursor_point ) %]
Layer properties with a raster_value expression entered in the HTML Map Tip field

The MapTip with the content you specified appears!

Hovering over the land use raster layer shows a MapTip with the pixel value

HTML Map Tip accepts an HTML template and QGIS expressions.

To look up the layer name, process the output value, or do something else, click the ε button to open the Expression Dialog. Enter the following in the expression form, then click OK, Insert, and Apply in that order.

The Expression Dialog with an expression using map_to_html_table and raster_attributes

Check attributes by hovering the mouse

Feature: Identify on mouse move, no mouse click

Next up is feature information!

When you click a feature, its attributes appear in the Identify Results panel.

A clicked feature highlighted on the map, with its attributes in the Identify Results panel on the right

This update adds Identify Feature(s) on mouse over to the settings in Identify Results!

The identify mode menu in the Identify Results panel with Identify Feature(s) on mouse over selected

Turn it on, and you can see a feature's attributes just by hovering over it, as shown here!

Hovering over vector features shows their attributes in the Identify Results panel without clicking

It works with raster layers too, of course!

Hovering over a raster layer shows the pixel value in the Identify Results panel without clicking

Attribute table support for raster layers

Feature: Raster Attribute Tables (RAT) Support

Right-click a raster layer in the Layers panel and click Open Raster Attribute Table.

The raster layer context menu with Open Raster Attribute Table selected

The table lets you set values such as RGBA for each band and each pixel.

The Raster Attribute Table window listing Value, Class, RGBA and Color for each pixel value

You can also check it in the layer properties.

The Attribute Tables tab in the layer properties showing the raster attribute table

The data used here is the Land Use Tertiary Mesh from National Land Numerical Information. The colors mean the following:

Table of Land Use Tertiary Mesh categories with their pixel values, RGB values and sample colors

Because you can edit the RAT directly in QGIS, you can enter item names in Class and other columns, and you can add columns too.

The raster attribute table in edit mode with item names such as ‘田’ and ‘その他農用地’ typed into the Class column

You can create a RAT from the symbology or load one from a separate file.

Attribute Tables tab with buttons to create a new table from the current symbology or load one from a VAT.DBF file

A RAT is saved in a file named xxx.aux.xml and loads automatically when its prefix matches the raster layer's.

How to upgrade

The article below explains in detail how to upgrade QGIS. Have a look at it as well.

Conclusion

QGIS 3.30 adds many more features than the ones covered here. If you are curious, see the changelog!

About the author
QGIS LAB Editorial Team
QGIS LAB Editorial Team

QGIS LAB is a comprehensive information hub for QGIS, the open-source GIS software. Under the concept of “Geospatial for Greater Good,” we share the knowledge and skills to open up the world through location data.