You are currently reviewing an older revision of this page.
Original Article Date: May 28, 2010
This tutorial is based on 2004 article that was written for MicroStation XM.
Explore the file:Download, open and explore 220_Points.dgn. In this 3D file you'll notice a model called Points that contains zero-length lines representing the peaks and valleys of a surface or ground terrain. Although these points are supplied with this tutorial, you can easily create your own if you have design software that can export DTM data to an XYZ text file. Once you have a text file, you can import the data into a design file by using the Import Coordinates tool from the XYZ Text toolbox.
Create the DTM:To create a triangluated network of these points, follow these very easy steps:If desired, create a new level - you might want to call it DTM for Digital Terrain Model.Make this your active level, and set the active colour to 0.Put all the points in a selection set, this can easily be done by using CTRL+A.
Navigate to the Create Meshes toolbox and choose Mesh From Points.
In the tool settings box, enable Expand to Rectangle and enter a datapoint to process. To clearly see what the Expand to Rectangle button does, delete the resulting mesh element, and regenerate the triangles with that option turned off. The difference is obvious:
Adjust the global lighting:At this time the mesh is ready to be rendered 'as is' or you can drape an aerial over it which I'll explain in the following pages. In the meantime, let's just render the triangles to get a better idea of what the terrain looks like. Before proceeding, ensure that you have generated the mesh without the bounding rectangle as explained above. You'll also want to turn off the elevation points since they are no longer needed.In order to get a better rendering from this particular model, we'll first adjust the global lighting.Choose Light Manager from the Lights toolbox.
Enable Ambient, Flashbulb and Solar and adjust the intensity as desired.
Render the surface:Choose Smooth from the View Display Mode list as shown:
Attach Image:The next step in this tutorial is to drape an aerial photo over the resulting digital terrain model. However, before we do that, let's take a look at the aerial by simply attaching it via the Raster Manager.From the Raster Manager, select File > Attach and select 220_Image.jpg. This image is georeferenced, so be sure to turn off Place Interactivly from the attach dialog.
The following graphic shows the image attached in the Top view. Note that the mesh has been turned off for clarity.
To remove the black collar around the image, right-click the image entry in the Raster Manager and select Transparency from the popup menu.
Enable the Transparent option and choose colour 0 to be 100% transparent.
When images are applied using Elevation Drape as the mapping method, they are tiled so that all four corners are coincidental. This means that each corner of the image is adjacent to the other three corners as shown below. (With thanks to Ron Jones from the The WSDOT Design Visualization Group for this bit of information and for the graphic below.)
Draping introduction:Ok...so now we are ready to get to the draping process. The ideal and preferred software to use for draping is Bentley Descartes which drapes images in a snap and requires no effort from the user. However, for those of you who don't have Bentley Descartes you can still drape images by following along with the remainder of this article.I'd like to point out that the draping workflow was originally published in an 1998 MicroStation Manager Magazine article called Draping photos over MicroStation models authored by Bill Hanson. Bill does a wonderful job of describing the theory behind each step and I recommend that you read his article to supplement the following abridged version. Whenever you're ready....Detach the image and display only the DTMDraping Workflow Overview:Create a material table to store material assignments in the file.Create a palette file to store material characteristics.Create a new material to point to the image.Assign the aerial photograph to the new material.Adjust the material characteristics.Assign the material to the DTMRender the view.
Create material table and palette file:From the Rendering Tools tool box, select Define Materials and you will be presented by a rather large dialog. This dialog is the "control center" for palettes and their material definitions.When you first access this dialog, MicroStation will populate the left side with an entry that is the same as your file name. This entry is the beginnings of a material table which is a file with a .mat extension. A material table stores material assignments to elements in the design file that live on specified levels and have specific colour.
From the menu bar, select Palette > NewMicroStation responds by adding New Palette (1) under the material table.Rename this to PhotoDrape by selecting Palette > Save As, or by right-clicking the entry and selecting Save As from the picklist.In doing so, MicroStation creates a palette file which has the extension of .pal.
A palette is a simple text-based file that contains a materials characteristics. To see what I mean, you can go ahead and open a delivered palette file from .../bentley/Workspace/system/materials/. You'll also notice that these files make reference to the "patterns" which are the actual JPG images. These images are in the .../Workspace/system/materials/pattern/ folder. Finally, palette files also refer to "bump maps" which adds roughness or texture to the pattern. They are typically greyscale contrasting or companion images that have the letter "b" as the last character. These will be found in the .../Workspace/system/materials/bump/ folder.Create a new material:Select the New Material button and rename New Material (1) to Aerial
Assign the aerial as the material:Select the little icon highlighted in the graphic below and select 120_Image.jpg.
Once the image has been loaded, you will be presented with the following dialog which allows you to customize the settings or characteristics for the material.
Adjust the materials characteristics:This step will require you to add the information we gathered about the image. Hopefully you still have those numbers near by!Adjust the settings to be as follows:Mapping to Elevation DrapeX Size = 5286 and Y Size = 5228This is the width and height of the image in master units and was obtained via the Raster Manager in a previous step.Offset X = 378864.5 and Offset Y = 5993712.5These are the lower left coordinates of the image and were grabbed from the attachment settings in the Raster Manager.
Close pattern dialog and save your changes by poking on the Save button in the Material Editor dialog. Hint: When you have unsaved work, the entries on the left side of the Material Editor will be blue. When there have been no changes, and there is no need to save, the entries will be black. See the graphic below.
Dismiss the Material Editor dialog and select Apply Material from the Rendering Tools tool box.Double check that you have the correct palette and material selected as shown in the graphic below.
Poke on Assign by Level/Colour and select the mesh element representing the terrain.Render the DTM:From the Rendering Tool tool box, select the Render tool and adjust the settings as follows:Target = View, Render Mode = Smooth, and Shading Type = Normal.Enter a datapoint on the isometric view and admire your results.
As you can see, there's a fair bit of work involved in draping an image over a DTM using plain old ordinary MicroStation. If you're going to be doing a fair bit of this, I recommend that you take a second look at MicroStation Descartes which eliminates 95% of the work.Other than that, I hope you've found this a worthwhile tutorial and that you'll be able to produce some fine looking DTM's in no time at all.
AskInga Article #220