r.to.rast3(1)

πŸ’– r.to.rast3 β€” bestie's guide πŸ’–

okay so this is the GRASS GIS User's Manual page for r.to.rast3(1) and honestly? it's giving glow-up. you're taking a whole stack of flat 2D raster maps and smooshing them into ONE 3D raster volume map. volumetric. iconic. slay ✨


🌈 NAME 🌈

r.to.rast3 β€” no cap, this converts 2D raster map slices into one single 3D raster volume map. that's the whole vibe. πŸ’…


πŸŽ€ KEYWORDS πŸŽ€

raster, conversion, voxel


✨ SYNOPSIS ✨

r.to.rast3
r.to.rast3 --help
r.to.rast3 [-m] input=name[,name,...] output=name  [tilesize=integer]
[--overwrite]  [--help]  [--verbose]  [--quiet]  [--ui]

πŸ¦‹ Flags πŸ¦‹

  • -m β€” use the 3D raster mask (if one exists) with your output map. mask on, bestie 🫢
  • --overwrite β€” lets your output files just bulldoze over existing files. allow it. πŸ’…
  • --help β€” prints the usage summary, aka the tl;dr
  • --verbose β€” verbose module output, it will literally tell you everything
  • --quiet β€” quiet module output, shhh 🀫
  • --ui β€” force launches the GUI dialog, for when you want the pretty buttons

🌸 Parameters 🌸

  • input=name[,name,...] β€” required. the 2D raster maps that represent the slices. yes you can pass a whole little squad of them, comma-separated.
  • output=name β€” required. the name for your output 3D raster map. name it something cute.
  • tilesize=integer β€” the maximum tile size in kilo bytes. default is 32KB.
    • Default: 32

πŸ’œ DESCRIPTION πŸ’œ

so r.to.rast3 converts 2D raster map(s) into one raster3D map. periodt.

but listen β€” it is super important to properly set your 3D region settings, especially the number of layers and the depth of layers. like, this is the whole ballgame. πŸ™ˆ if your 2D and 3D region settings are different, the 2D resolution will get adjusted to the 3D resolution. it just will. that's the deal.

How r.to.rast3 works


πŸ”₯ NOTES πŸ”₯

  • every single 2D raster map gets copied as one slice to the raster3D map.
  • slices are counted from the bottom to the top, so the bottom slice has to be number 1. no negotiating. 1 is the floor, literally.
  • if you provide less 2D raster maps than the defined depths, the last given 2D map is used to fill up the remaining raster3D slices all the way to the top. it's giving "stretch that last one". πŸ’€

🌟 EXAMPLES 🌟

⭐ EXAMPLE 1 ⭐

this example shows how to convert 6 maps into one 3D map with 6 layers. six for six. ate. πŸ‘‘

# Mapset data in dataset slovakia3d
g.region raster=prec_1,prec_2,prec_3,prec_4,prec_5,prec_6 -p
g.region b=0 t=600 tbres=100 res3=100 -p3
r.to.rast3 input=prec_1,prec_2,prec_3,prec_4,prec_5,prec_6 output=new_3dmap

⭐ EXAMPLE 2 ⭐

this example shows how to convert 3 maps into one 3D map with 6 layers. three maps, six layers β€” see the fill-up thing from NOTES? that's her. 🧚

# Mapset data in dataset slovakia3d
g.region b=0 t=600 tbres=100 res3=100 -p3
r.to.rast3 input=prec_1,prec_2,prec_3 output=new_3dmap

πŸ‘€ SEE ALSO πŸ‘€

g.region, r3.to.rast, r.to.rast3elev

go read those too bestie, they're in the same friend group 🫢


πŸ’– AUTHOR πŸ’–

Soeren Gebbert


🌈 SOURCE CODE 🌈

Available at: r.to.rast3 source code (history)

Accessed: Saturday Jan 17 05:41:03 2026

Main index | Raster index | Topics index | Keywords index | Graphical index | Full index

Β© 2003-2025 GRASS Development Team, GRASS GIS 8.4.2 Reference Manual


ok that's the whole page!! this is GRASS 8.4.2, from the GRASS GIS User's Manual, and you accessed it Saturday Jan 17 05:41:03 2026. mwah πŸ’‹ go make some voxels bestie, iykyk πŸ’œβœ¨πŸŽ€
πŸ“¦ where this page comes from