From d1768c6325a12287129ee889a73dacd94937996d Mon Sep 17 00:00:00 2001 From: rohannallamadge Date: Sun, 29 Dec 2024 12:56:46 +0530 Subject: [PATCH 1/2] fix: replace outdated WMS server in r.out.vtk example #48444 --- raster/r.out.vtk/r.out.vtk.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/raster/r.out.vtk/r.out.vtk.html b/raster/r.out.vtk/r.out.vtk.html index 9ae0ec3a65b..1f3a7baafeb 100644 --- a/raster/r.out.vtk/r.out.vtk.html +++ b/raster/r.out.vtk/r.out.vtk.html @@ -94,14 +94,14 @@

Spearfish example with RGB data

 #set the region
-g.region n=4926990 s=4914840 w=591570 e=607800 res=30 -p
+g.region n=7000000 s=5000000 w=-1000000 e=2000000 res=1000 -p
 
 # using r.in.wms to create RGB data to get a satellite coverage
-r.in.wms layers=global_mosaic mapserver=http://wms.jpl.nasa.gov/wms.cgi \
-         output=wms_global_mosaic
+r.in.wms layers=BlueMarble_ShadedRelief_Bathymetry url=https://gibs.earthdata.nasa.gov/wms/epsg3857/best/wms.cgi \
+         output=wms_blue_marble
 
 # export the data to VTK
-r.out.vtk rgbmaps=wms_global_mosaic.red,wms_global_mosaic.green,wms_global_mosaic.blue \
+r.out.vtk rgbmaps=wms_blue_marble.red,wms_blue_marble.green,wms_blue_marble.blue \
           elevation=elevation.10m output=/tmp/out.vtk
 
 # visualize in Paraview or other VTK viewer:

From 67611b3f6a2c9d6cd0e0e33f29736b9a1efec896 Mon Sep 17 00:00:00 2001
From: Anna Petrasova 
Date: Wed, 27 May 2026 23:07:20 -0400
Subject: [PATCH 2/2] use nc dataset

---
 raster/r.out.vtk/r.out.vtk.html | 16 +++++++++-------
 raster/r.out.vtk/r.out.vtk.md   | 18 ++++++++++--------
 2 files changed, 19 insertions(+), 15 deletions(-)

diff --git a/raster/r.out.vtk/r.out.vtk.html b/raster/r.out.vtk/r.out.vtk.html
index 1f3a7baafeb..51d15eac20a 100644
--- a/raster/r.out.vtk/r.out.vtk.html
+++ b/raster/r.out.vtk/r.out.vtk.html
@@ -90,19 +90,21 @@ 

Simple Spearfish example

paraview --data=/tmp/out.vtk
-

Spearfish example with RGB data

+

North Carolina sample dataset example with RGB data

-#set the region
-g.region n=7000000 s=5000000 w=-1000000 e=2000000 res=1000 -p
+# set the region to the statewide North Carolina elevation map
+g.region raster=elev_state_500m -p
 
-# using r.in.wms to create RGB data to get a satellite coverage
-r.in.wms layers=BlueMarble_ShadedRelief_Bathymetry url=https://gibs.earthdata.nasa.gov/wms/epsg3857/best/wms.cgi \
-         output=wms_blue_marble
+# use r.in.wms with the -b flag to fetch RGB satellite imagery from
+# NASA GIBS as separate .red, .green and .blue rasters
+r.in.wms -b layers=BlueMarble_ShadedRelief_Bathymetry \
+            url=https://gibs.earthdata.nasa.gov/wms/epsg4326/best/wms.cgi \
+            output=wms_blue_marble
 
 # export the data to VTK
 r.out.vtk rgbmaps=wms_blue_marble.red,wms_blue_marble.green,wms_blue_marble.blue \
-          elevation=elevation.10m output=/tmp/out.vtk
+          elevation=elev_state_500m output=/tmp/out.vtk
 
 # visualize in Paraview or other VTK viewer:
 paraview --data=/tmp/out.vtk
diff --git a/raster/r.out.vtk/r.out.vtk.md b/raster/r.out.vtk/r.out.vtk.md
index dad2807ff9d..c7fc2f2c889 100644
--- a/raster/r.out.vtk/r.out.vtk.md
+++ b/raster/r.out.vtk/r.out.vtk.md
@@ -93,19 +93,21 @@ r.out.vtk input=elevation.10m,slope,aspect elevation=elevation.10m output=/tmp/o
 paraview --data=/tmp/out.vtk
 ```
 
-### Spearfish example with RGB data
+### North Carolina sample dataset example with RGB data
 
 ```sh
-#set the region
-g.region n=4926990 s=4914840 w=591570 e=607800 res=30 -p
+# set the region to the statewide North Carolina elevation map
+g.region raster=elev_state_500m -p
 
-# using r.in.wms to create RGB data to get a satellite coverage
-r.in.wms layers=global_mosaic mapserver=http://wms.jpl.nasa.gov/wms.cgi \
-         output=wms_global_mosaic
+# use r.in.wms with the -b flag to fetch RGB satellite imagery from
+# NASA GIBS as separate .red, .green and .blue rasters
+r.in.wms -b layers=BlueMarble_ShadedRelief_Bathymetry \
+            url=https://gibs.earthdata.nasa.gov/wms/epsg4326/best/wms.cgi \
+            output=wms_blue_marble
 
 # export the data to VTK
-r.out.vtk rgbmaps=wms_global_mosaic.red,wms_global_mosaic.green,wms_global_mosaic.blue \
-          elevation=elevation.10m output=/tmp/out.vtk
+r.out.vtk rgbmaps=wms_blue_marble.red,wms_blue_marble.green,wms_blue_marble.blue \
+          elevation=elev_state_500m output=/tmp/out.vtk
 
 # visualize in Paraview or other VTK viewer:
 paraview --data=/tmp/out.vtk