[GRASS-dev] r.out.vtk problem?

Hi devs,

I'm trying to use t.rast.out.vtk but I obtain something strange. I
think something is wrong with r.out.vtk, I maybe found two errors:
- it doesn't maintain the color of the map
- there is something doesn't work with the Z axis.

I attach two screenshot, problem.png is the paraview scene and
right.png is the right color of my map.

I also tested r.out.vtk but I obtain the same result :frowning:

Thanks

--
ciao
Luca

http://gis.cri.fmach.it/delucchi/
www.lucadelu.org

Hi Luca,
can you please provide the command line that produces the wrong output?

Important to know is that r.out.vtk does not transform the GRASS color
table into a VTK lookup table. Therefore you do not see the colors
from GRASS in ParaView.

Best regards
Soeren

2014-11-28 14:28 GMT+01:00 Luca Delucchi <lucadeluge@gmail.com>:

Hi devs,

I'm trying to use t.rast.out.vtk but I obtain something strange. I
think something is wrong with r.out.vtk, I maybe found two errors:
- it doesn't maintain the color of the map
- there is something doesn't work with the Z axis.

I attach two screenshot, problem.png is the paraview scene and
right.png is the right color of my map.

I also tested r.out.vtk but I obtain the same result :frowning:

Thanks

--
ciao
Luca

http://gis.cri.fmach.it/delucchi/
www.lucadelu.org
_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

On 28 November 2014 at 14:35, Sören Gebbert
<soerengebbert@googlemail.com> wrote:

Hi Luca,

Hi Soeren

can you please provide the command line that produces the wrong output?

r.out.vtk in=2012_01_tempmean
out=/tmp/export_temporal/2012_01_tempmean.vtk rgbmaps=2012_01_tempmean
elevation2d=elev_state_500m@PERMANENT

using the data of FOSS4g 2014 temporal workshop

Important to know is that r.out.vtk does not transform the GRASS color
table into a VTK lookup table. Therefore you do not see the colors
from GRASS in ParaView.

ah, would it be possible to implement it? a new parameter like color?

Best regards
Soeren

--
ciao
Luca

http://gis.cri.fmach.it/delucchi/
www.lucadelu.org

Hi Luca,

2014-11-28 15:28 GMT+01:00 Luca Delucchi <lucadeluge@gmail.com>:

On 28 November 2014 at 14:35, Sören Gebbert
<soerengebbert@googlemail.com> wrote:

Hi Luca,

Hi Soeren

can you please provide the command line that produces the wrong output?

r.out.vtk in=2012_01_tempmean
out=/tmp/export_temporal/2012_01_tempmean.vtk rgbmaps=2012_01_tempmean
elevation2d=elev_state_500m@PERMANENT

Use the "input" option to specify the raster map that should be
exported. The "rgbmaps" option expects three maps for red, green and
blue (satellite image data).

Please use the "elevation" parameter for elevation maps. The
elevation2d parameter is a number that specifies the height of the
whole map if no elevation maps was specified.

using the data of FOSS4g 2014 temporal workshop

Important to know is that r.out.vtk does not transform the GRASS color
table into a VTK lookup table. Therefore you do not see the colors
from GRASS in ParaView.

ah, would it be possible to implement it? a new parameter like color?

It is possible to implement. Feel free to do it. :slight_smile:
You do not need a new parameter, since the "input" option expects one
more raster maps. Their color tables must be converted into the VTK
legacy lookup table format to visualize them in ParaView.

The "rgbmaps" option allows you to specify red, green and blue maps
that can be combined in ParaView to RGB data, hence no color table
conversion is needed here.

Best regards
Soeren

Best regards
Soeren

--
ciao
Luca

http://gis.cri.fmach.it/delucchi/
www.lucadelu.org

On 28 November 2014 at 16:40, Sören Gebbert
<soerengebbert@googlemail.com> wrote:

Hi Luca,

Hi Soeren

2014-11-28 15:28 GMT+01:00 Luca Delucchi <lucadeluge@gmail.com>:

On 28 November 2014 at 14:35, Sören Gebbert
<soerengebbert@googlemail.com> wrote:

Hi Luca,

Hi Soeren

can you please provide the command line that produces the wrong output?

r.out.vtk in=2012_01_tempmean
out=/tmp/export_temporal/2012_01_tempmean.vtk rgbmaps=2012_01_tempmean
elevation2d=elev_state_500m@PERMANENT

Use the "input" option to specify the raster map that should be
exported. The "rgbmaps" option expects three maps for red, green and
blue (satellite image data).

Please use the "elevation" parameter for elevation maps. The
elevation2d parameter is a number that specifies the height of the
whole map if no elevation maps was specified.

Yes, sorry this was one of the test that I did, my first test was running this

r.out.vtk in=2012_01_tempmean
out=/tmp/export_temporal/2012_01_tempmean.vtk
elevation=elev_state_500m@PERMANENT

It is possible to implement. Feel free to do it. :slight_smile:
You do not need a new parameter, since the "input" option expects one
more raster maps. Their color tables must be converted into the VTK
legacy lookup table format to visualize them in ParaView.

It seems not, at least with the command above I cannot see the right
color as shown in problem.png

Best regards
Soeren

--
ciao
Luca

http://gis.cri.fmach.it/delucchi/
www.lucadelu.org

Hi Luca,

2014-11-28 17:16 GMT+01:00 Luca Delucchi <lucadeluge@gmail.com>:

On 28 November 2014 at 16:40, Sören Gebbert
<soerengebbert@googlemail.com> wrote:

Hi Luca,

Hi Soeren

2014-11-28 15:28 GMT+01:00 Luca Delucchi <lucadeluge@gmail.com>:

On 28 November 2014 at 14:35, Sören Gebbert
<soerengebbert@googlemail.com> wrote:

Hi Luca,

Hi Soeren

can you please provide the command line that produces the wrong output?

r.out.vtk in=2012_01_tempmean
out=/tmp/export_temporal/2012_01_tempmean.vtk rgbmaps=2012_01_tempmean
elevation2d=elev_state_500m@PERMANENT

Use the "input" option to specify the raster map that should be
exported. The "rgbmaps" option expects three maps for red, green and
blue (satellite image data).

Please use the "elevation" parameter for elevation maps. The
elevation2d parameter is a number that specifies the height of the
whole map if no elevation maps was specified.

Yes, sorry this was one of the test that I did, my first test was running this

r.out.vtk in=2012_01_tempmean
out=/tmp/export_temporal/2012_01_tempmean.vtk
elevation=elev_state_500m@PERMANENT

Ok, and what exactly is the problem with the height map?

It is possible to implement. Feel free to do it. :slight_smile:
You do not need a new parameter, since the "input" option expects one
more raster maps. Their color tables must be converted into the VTK
legacy lookup table format to visualize them in ParaView.

It seems not, at least with the command above I cannot see the right
color as shown in problem.png

Actually, you didn't attached the png files ... at least they didn't
reached me. :wink:
However, color table conversion is currently not supported. Fell free
to implement it. I just tried to gave you a hint how to code it.

Ciao
Sören

Best regards
Soeren

--
ciao
Luca

http://gis.cri.fmach.it/delucchi/
www.lucadelu.org