I need 135 raster values of raster from 15 points. So, I want 3×3 pixels (9 raster values) from each point.

enter image description here

To make them, I tried "Rasterize" to convert points as shown below. (In this QGIS session, there are 2 layers, Point layer(Input layer) & Raster layer (Output extent).)

enter image description here But, after trying, I couldn't find the 9 pixels even at maximum zoom scale.

Should I change the parameters of Rasterize or think out another way?

For your information,

1.Properties of my raster data are shown below. enter image description here

2.The points were made by clicking on the map.

If my sentences confuse you, I'm sorry for it.


You can't rasterize a point as it has no dimensions. First create a polygon around your point, then rasterize this.

Version 1 (straightforward)

  1. As on your screenshot, you have set a pixel size of 10 * 10 and you want a 3 * 3 pixel raster, I suppose the polygon should be 30 * 30 meters with the point in the middle of it. To create such a square around your point, use Geometry by expression (Menu Processing / Toolbox / Geometry by expression - see also here for how to use it) with this expression:
       project (
  1. Rasterize the created polygon layer. Be sure to set Output raster size units to Georeferenced units and use a projected CRS (units in meters).

Version 2 (less straightforward)

There is another option, however, not so straightforward (depending on the spatial distribution / extent of your points). You'll get 30 * 30 meter polygons all over the extent of your point layer, whereas in the solution above, you create polygons only where you have points.

  1. Create a grid (Menu Vector / Research Tools / Create Grid), set it to Rectangle (polygon) with grid extent from your point layer (and in the same, projected CRS), horizontal and vertical spacing to 30. If your points are far away, you'll get a huge grid with a lot of cells (that's why the other option is faster).

  2. Use Menu Vector / Data Management Tools / Join attributes by location to select the cells that contain a point. Create a new attribute for them with field calculator that contains the value to be used for rasterization.

  3. Rasterize the grid.

  • 1
    Do you use a projected CRS (units in meters)? Be sure to set Output raster size units to Georeferenced units. What is the result when you try to make these rasters? Can you share your data?
    – Babel
    Sep 20 at 13:53
  • Finally, I could make 3*3 pixel corresponding to raster layer! I forgot to set raster layer as output layer and set "-99" at "Assign a....". When I set "0", the pixels were not visible. Anyway, Thank you very much for giving me a lot of time to share your knowledge.
    – Yuya
    Sep 21 at 0:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.