[GRASS-user] Moebius strip to illustrate 3D vector capabilities

Hamish hamish_nospam at yahoo.com
Wed May 30 12:36:55 EDT 2007


Markus Neteler wrote:
> > > I just made this screenshot
> > > http://grass.itc.it/grass63/screenshots/vector.php
> > > to illustrate GRASS' 3D vector capabilities. Not
> > > sure if you can do the same with other GIS :-)
..
> I would love to see the Escher ants:
> http://www.nature.com/nature/journal/v426/n6968/images/426776a-f1.2.jpg
> 
> With v.in.dxf (of ants or whatever) and v.transform and a rainy day it
> shouldn't be too hard!


some notes:

most DXF download sites I looked at were useless for-profit black holes.

but then I found a very nice collection of 3D vector meshes:
  http://www-rocq1.inria.fr/gamma/download/download.php

In a nice well documented & cleaned mesh format. yay .edu.

rather than write a nice mesh -> grass 3D vector face converter, I went
quick & dirty and downloaded the 3d studio versions (.3ds) and converted
them to DXF before importing with v.in.dxf.


To convert .3ds -> .dxf I used wcvt2pov.exe in wine. It worked pretty
well, nice simple program.
   http://ftp.carnet.hr/pub/misc/VRML/utilities/converters/


I also tried 3dto3dV35.zip; the obfuscated linux version compiled, but
I think it has some dirsep errors or something (and little way to tell).

there is a .rpm version, maybe that's better?
  http://fr.rpmfind.net/linux/rpm2html/search.php?query=3dto3d
source:
  http://www.tb-software.com/download_4.html

I gave up and ran the 3dto3d.exe version in wine.
   (in .wine/config change x11 to ttydrv)
command line for that looked like:
 wine ../3dto3d.exe polyline.obj /if6 /iv /d"polyline.dxf" /of13 /ov /ol1 /om1
 wine ../3dto3d.exe face.obj /if6 /iv /d"face.dxf" /of13 /ov /ol1 /om0


wcvt2pov.exe was less painful for sure.


then, in GRASS,
 v.in.dxf in=cow.dxf out=cow
 #v.transform
 g.region vect=cow
 r.mapcalc foo=1
 nviz foo
 [Raster Surface -> Transparency -> Max]
 [3d Polygons -> New]
 ...


see also
  http://grass.gdf-hannover.de/wiki/Help_with_3D


Hamish




More information about the grass-user mailing list