- 04 Jul 2024
- 10 Minutes to read
- Print
- DarkLight
- PDF
Working with .dxf Vector Maps
- Updated on 04 Jul 2024
- 10 Minutes to read
- Print
- DarkLight
- PDF
D vector maps can be imported as .dxf files to complement or replace the maps in NavVis IVION. Vector maps enable users to present an easy-to-read overview of the building that can be customized.
To successfully import and work with .dxf files refer to the following:
Only metric values are supported for a local coordinate system.
Imports of files up to 20 MB or less are supported.
Supported geometries include points, polylines, polygons, arcs, and hatches, other geometry types are not supported.
Tips on improving the overall performance, download times, and level of detail.
(ftUS) indicates US Survey Feet and (ft) indicates International Feet when selecting a Spatial Reference System.
The following table shows versions that are supported:
Version | Internal version | AutoCAD versions |
---|---|---|
DWG2013 | AC1027 | AutoCAD 2013, AutoCAD 2014, AutoCAD 2015, AutoCAD 2016, AutoCAD 2017 |
Uploading a .dxf Vector Map
In NavVis IVION, go to the Site for which you want to upload a vector map.
Go to Site Setup > Vector map.
Click Add a DXF file.
In the dialog that opens, specify the source coordinate system for the .dxf file:
Select Site coordinate system to import the .dxf file into the coordinate system that was previously defined for the site. Place the cursor over the info icon for details on the site coordinate system.
Select Spatial reference system to import the .dxf file into a projected, metric system. Start typing a name and select the desired spatial reference system from the options that appear.
Select Dataset to import the .dxf file into the coordinate system of a specific dataset. Select a dataset from the drop-down menu.
Click Upload DXF file and choose the file that you want to upload.
Click Publish when you have finished.
Creating a Transformation
The Manage Transformations option offers users the ability to create a new transformation on the applicable coordinate reference system in NavVis IVION. Inputs for the Custom Coordinate Systems dialogue are based on an affine transformation matrix, describing a shift and a rotation relative to a parent coordinate system such as the site coordinate system or a spatial reference system.
Procedure
Go to Site Setup > Vector Map.
Click Manage transformations.
Click Add.
In the dialog that opens, enter a name for the custom coordinate system.
Select a spatial reference system by typing a name and selecting from the options that appear.
Alternatively, you can specify a custom projection:
Enter a name for the custom projection.
Define the
x
,y
, andz
values of the base point.Optionally, define a rotation for the spatial reference system by entering the angle or the rotation of the x-axis (
rx
) and y-axis (ry
)
Click Save.
Click Publish when you have finished.
UTM Projection
The Universal Transverse Mercator (UTM) projection is ideal to use for geo-referencing vector maps in a local area, since angles and direction are preserved. To minimize distance distortion, UTM splits the globe into sixty zones.
Munich, Germany is located in UTM zone 32 North. If you do not know which UTM zone describes your location, you can use this online tool to find the best fit.
Another piece of information that is necessary to provide with UTM projections is the ellipsoid. While the WGS84 ellipsoid is generally used globally, the European Terrestrial Reference System 1989 (ETRS89) is the preferred datum system for describing geographical data located in Europe. Therefore, our vector map located in Munich, Germany can be referenced to the EPSG 25832 - ETRS89 / UTM zone 32N coordinate reference system.
NavVis IVION Add-In for Revit
You can also use the NavVis IVION Add-In for Revit to geo-reference vector maps instead of doing it manually. The add-in connects a Revit project to an NavVis IVION Instance and can calculate the appropriate transformation based on tie points.
Other Software for Geo-Referencing
Currently, importing a .dxf vector map into NavVis IVION requires knowing which coordinate reference system best describes its real-world location. In other words, it is necessary to know:
Source coordinate system for previously geo-referenced vector maps, e.g. EPSG 25832, ETRS89 / UTM zone 32N.
Custom coordinate system, e.g. knowing the reference SRID as well as its affine transformation parameters.
Sometimes this information is difficult to find for individuals who are not familiar with geo-referencing or coordinate reference systems. One way to geo-reference your vector map without knowing its transformation parameters is to do so using external software. Some available software that can help with this task includes, but is not limited to:
Tutorial: Geo-Referencing .dwg using Open Source Software
Before performing this task you need the following:
QCAD: Note that when using the trial version, QCAD must be restarted every 30 minutes to ensure full feature functionality. Remember to save edits often.
QGIS: Plus an OpenStreetMap plugin, such as the QOSM Plugin.
The .dwg file: NavVis-2D Floor Plan.dwg.
Procedure
After downloading the required material, open the .dwg file in QCAD.
Edit the layers using the Layer List.
Remove all unnecessary layers, such as annotation and unused layers.
To remove a layer, select it in the Layer List and select the red minus symbol at the top.
Toggle the layer visibility to determine whether unused layers can be removed.
Convert all the Block References to polylines so that they can be imported to NavVis IVION.
Open the Property Editor window.
Check whether a selected layer contains Block References and, if so, explode them.
Select a layer from the Layer List by right-clicking on it.
The Property Editor is now populated with the selected layer's properties.
In the Selection field, select Block Reference from the drop-down menu.
Type
explode
in the command line to convert the blocks to polylines.Important: If you select the entire drawing and explode, all geometries will be exploded into simple lines. This will increase the file size and will slow down processes in NavVis IVION. Only explode non-supported items.
Once you are finished exploding Block References, Purge unused blocks. Type
purgeblocks
in the command line.
Save edits.
Open QGIS.
Install QOSM Plugin so that OpenStreetMap Map Tiles can be imported into QGIS as a reference.
Add OSM Tile Layer.
Drag Map to Location and zoom in on the location where the .dxf should be placed.
Select a coordinate reference system such as EPSG 25832 - ETRS89 / UTM zone 32N
Copy the coordinates from QGIS to QCAD.
In QGIS, zoom to a point where the DXF should be placed.
Copy the coordinates.
In QCAD, move objects to their real-world location using the coordinates from QGIS.
Select all objects by typing
selectall
in the command line.Type
move
in the command line.The
reference point
should be the point on the vector map that corresponds to the coordinates copied from QGIS. In this tutorial, the coordinates copied from QGIS equate to the top left corner of the rotated vector map, or the bottom left corner before rotation.When it prompts for
target point
in the command line, paste the coordinates from QGIS and press Enter.Accept the default settings and press OK.
In QGIS, measure the angle of the building on OpenStreetMap to determine the angle the vector map must be rotated.
First, line up the building you are referencing on OpenStreetMap to a horizontal reference, such as the bottom map border.
From the View menu, navigate to Measure and select Measure Angle.
Trace the angle onto the map and double click when finished.
Copy the angle value.
In QCAD, rotate the vector map by the angle copied from QGIS.
Select all objects then type
rotate
in the command line.The
center point
can be the same point that was chosen as the reference point in Step 10.Accept the default settings and press OK.
In this tutorial, the objects were first rotated -90 degrees to more accurately reflect the building's orientation on OpenStreetMap. They were then rotated by the angle obtained from QGIS, -18.777.
Scale the vector map to its appropriate size.
Normally, if the file is saved in metric units such as meters, modifying the scale might not be necessary.
One way to determine if the scale is correct is to calculate the distance of a room.
Type
infodist
in the QCAD command line and find the distance between two walls in a room.Note: The distance measured in this example is 5410.5497, and the dimensions of the room are known to be about 5.4 meters. Therefore the scale in this example is 1:1000, and the vector map must be scaled by 0.001.
Select all objects.
Type
scale
in the command line.Input 0.001 in the Scale Options box then select OK.
Save the .dwg file as a .dxf file.
Open NavVis IVION to import the .dxf file.
Once logged into the instance, select the eye icon and check Show Vector Map Editor.
Input the Source Coordinate System, selecting the same CRS (EPSG 25832 - ETRS89 / UTM zone 32N) you used for QGIS.
Upload the .dxf file.
Edit the .dxf height, attributes and names as you wish.
Troubleshooting
If the upload fails, there may be an issue with the file's encoding. You can try to re-save it with the current version of your editing program and then re-upload it.
Unknown geometry types are ignored, which can lead to holes in your .dxf file. Currently, the fastest workaround is to directly edit the .dxf file and
explode
the unsupported geometries, such as Block References.
Vector Maps List
The tree view shows all uploaded .dxf files and can be expanded to show the layers. Next to each item is a badge showing the number of polygons and the number of vertices in the map.
Underneath the title of each vector map are the Edit and Jump to map fields. After selecting the Edit pencil, Min height and Max height fields become visible. They can be used to define when the map is shown. Additionally, the View and Edit fields can be used to control access to the vector maps.
When expanding a map, all layers and their colors as defined in the .dxf file are shown. Visibility of a layer can be toggled by clicking the icon on the right. This setting is saved on the server and takes effect for all users.
You can select maps and layers with your cursor. The toolbar buttons on the bottom operate on the currently selected items (Show All, Hide All, Delete).
Visibility of Map Layers
Once the upload is complete, a new map entry is appended to the list and a map layer for each layer in the .dxf file.
The visibility of vector map layers is controlled by two conditions:
The visibility of the map containing the layer.
The visibility setting of the layer.
For a layer to be shown, both of these conditions need to be true.
Visibility of the Map
The vector map is visible if ANY of the following conditions apply:
The
z
coordinate of the currently shown panoramic image's floor is between-100
and100
. To disable this mechanism you can omit one or both of these values.The name of the currently selected floor matches the name of the .dxf layer. If the layer name starts with
_
, the map will be shown regardless of the current floor.
Performance and Level-of-Detail
To improve performance and reduce download times, delete all the layers that are not required.
You can make them invisible with a toggle, but make sure to delete these layers before going into production mode. Layers that were marked invisible in the .dxf file are imported too, so you should review the vector map list after import in order to remove them.
After removing maps and/or layers, reload the page before evaluating the performance.
Because there is no level-of-detail mechanism, you have to simplify the .dxf file as much as possible. Every polygon adds to the download time and slows down rendering. The badges with polygon and vertex counts give an indication of how complex the maps and layers are.