Friday, December 01, 2006

Canoma to Google Earth Workflow

A few people have asked me about the details of getting models from Canoma into Google Earth.

Here is the process:

First export your model/scene from Canoma to an OBJ file.

Import the OBJ files into 3ds Max (I am using 3ds Max 8). At this point the textures will not show up, or appear linked. In order to get them to show up, you have to save the scene as a max file (I saved mine within the same folder as the textures and OBJ file). Now the materials will point to the textures correctly. That part took me forever to figure out!

You still won't see the textures in the viewport (only in the render view). In order to get the textures to show up in the viewport, you have to toggle visibility for each diffuse texture within the multi/sub-object material. This can be very tedious. The maxscript "Showmap" by Michael B. Comet comes in handy for this, which allows you to toggle all diffuse textures visible on or off with one button.

Once in Max, you can tweak the model, and bake lighting into the texture. You can also render the multiple textures to a single texture with customized UV layout. This has little effect on the final model in Google Earth, but useful if you want to consolidate the textures for post-processing.

As for exporting to Collada, I did not have any luck with 3ds Max's default exporter. Luckily, Feeling Software has created another exporter which does the trick! (Free with registration on their website.)

Once you have your Collada DAE file, you can drag and drop it directly into Google Earth. When your model shows up, a yellow bracket appears around it. Clicking and dragging the center of the bracket allows you to position the model. You can drag the corners to scale the model proportionately, or drag the edges to scale along that axis. There is a small diamond on one side that lets you rotate the model.

There are also a couple options in the properties dialog to configure the altitude of the model. If you want to place the model's alititude below 0, it's a little unintuitive. You have to first increase the altitude by any value, then switch the mode from "Clamped to ground" to "Absolute". Then scrub the altitude slider to find the rough elevation, and fine tune with the numeric input.

For simplicity's sake, you can group several structures into a folder in Google Earth, and in the folder properties you can uncheck "Allow this folder to be expanded", and the folder will collapse into a single element in your "Places". This can always be undone later if you want to make changes to the individual models again.

From Google Earth, you can right click the model or folder in the Places list and click "Save As" to export a KMZ file or "Share" to export to the Google Earth community forum. Too bad you can't upload Collada files to Google's 3D Warehouse, that would be easier for users to find your model with the 3D Warehouse layer you can turn on in Google Earth. But you can still share on the forum, and link to that as well.

If you are fortunate to have a copy of Canoma, it's a very intuitive tool, and great for creating content for Google Earth. Robert Seldi, one of the Canoma creators, mentioned he might be able to streamline this process by creating a Collada exporter for Canoma.

For those not familar with Canoma, you can find more info at Resources for Canoma Users. Digitally Distributed Environments recently posted an article about Canoma as well. Another great blog to check out!

2 Comments:

Bob MaX said...

To create a Canoma model from a MicroStation Cad DGN model or from
a ArcView SHP file, read my blog:

http://exporttocanoma.blogspot.com/

Best Regards

BobMaX

12:35 AM  
Anonymous said...

Sebastian -
try exporting from Canoma in VRML2 format instead of OBJ and suck that into 3D Studio Max - the textures should appear in their proper place, somewhat simplifying things. At least thats what I seem to remember...
Robert

1:20 AM  

Post a Comment

<< Home