' Set up the scene
NewScene , false
set obj1 = ActiveSceneRoot.AddGeometry( "Sphere", "MeshSurface" )
Selection.Add obj1
set obj2 = ActiveSceneRoot.AddGeometry( "Torus", "MeshSurface" )
Selection.Add obj2
' Export to an OBJ file
sFilePath = InstallationPath( siProjectPath ) & "\foo.obj"
ObjExport sFilePath, 0, False, 1, 100, 1, True, False, False, False, 0, False, False, False, True
DeleteAll false
' Import from the OBJ file
set rtn = ObjImport( sFilePath, 1, 0, True, True )
for each thing in rtn
logmessage thing.fullname & " (" & typename(thing) & ")"
next
'INFO : sphere,torus
'VERBOSE : Wavefront OBJ Export: <project_path>\foo.obj
'INFO : sphere (X3DObject)
'INFO : torus (X3DObject) |