Hello Hamish, just a short note: I currently rework the g3d library and the related modules to use the correct coordinate system (x, y, z -> right hand side cube). So all modules which convert raster to raster3d and vis versa are implemented in a wrong way. The r3.out.vtk export module is wrong too, it flips the y coordinate so the result looks reasonable in Paraview. :/
While doing this i plan to implement two more modules: r3.retile and r3.colors. r3.colors can be used to assign a color table to a raster3d map (its an enhancement to r.colors to support 3d raster too, like r.univar and r3.univar). Because g3d uses the same color table and functions as the raster library these color tables can be exchanged between raster and raster3d maps. Maybe this is the function you are looking for? Nice to hear that you plan to write a convert tool to use grass color tables in VTK too. Can you please provide your code when its finished, because this functionality is still missing in the vtk-grass-bridge. I hope to finish the g3d library work this or next week to finally start with full temporal support in grass7. Best regards Soeren 2011/6/15 Hamish <hamis...@yahoo.com>: > Hi, > > I've got a 3D raster with a very skewed distribution. > For viewing the slices (r3.to.rast) I'd like to use a > single set of color rules for all of the z-levels. > > So I'd like to run the ever-amazing 'r.colors -e' to > equalize over the full distribution, but how to do > that for all the z-level slices at once? > > ideas: > -r.region translate them and then patch them all > together on the same horizontal plane, calc the color > rules, then apply the mosaic's set of rules to all > the original slices. > > -same but interleave the slices at 1/n resolution > instead of r.region + r.patch. > > -use `r3.univar -e percentile=a,b,c,d,...` to re- > create what `r.colors -e` does, perhaps poorly. > (is there a set number of histogram steps r.colors -e > breaks things up into? the 256 from lib/gis/color_hist.c?) > > -modify r.colors's get_fp_stats() to scan over > multiple input rasters in a loop? > > > The rules file I'd like to use starts out with 263 > levels, so more than I'd like to interpolate by > hand. > (grass-addons/raster/r.colors.tools/palettes/palette_sst.gcolors) > > my data is all > 0.0 > > > once I have that I'd like to write an addon module > which converts a grass color table to a VTK .xml > color table, so they can be used there too, and also > figure out how to auto-set NVIZ G3D isosurface > colors from them. > > > thanks, > Hamish > > _______________________________________________ > grass-user mailing list > grass-user@lists.osgeo.org > http://lists.osgeo.org/mailman/listinfo/grass-user > _______________________________________________ grass-user mailing list grass-user@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/grass-user