Forge's Model Derivative model data extraction and format conversion can operate almost all design model formats in the industry, including Autodesk's engineering construction industry design format: Revit. Revit design files generally include 3D views, 2D drawings, 2D views, imported drawings, linked models or drawings, etc. All Forge services can extract and convert.

This article organizes several related matters:

  1. Forge conversion service can convert the drawings or views set release setting It is usually selected in a selection set (Set).
  2. By default, the Forge service will look for a view named {3D}, if not, it will automatically create one. Therefore, when the default {3D} view in the Revit model is renamed (for example, the Chinese name) or deleted, the release setting must also be selected, otherwise, after Forge conversion, it may mistakenly believe that the default loaded view is the adjusted view. .
  3. After conversion, all views are the conversion data of this model. Through the port API GET Manifest (modelderivative/v2/designdata/:urn), you can see how much conversion data there is. A node (derivative) corresponds to a 3D model or a 2D drawing. /view. Forge will also process the stage model view , which will also be a derivative.
  4. Load the model in Forge Viewer. If no special settings are made, the {3D} view will be loaded by default. To switch to some other view drawing, you need to set the viewerable id in the loading options, see viewerableId in the figure above. The code sample loads the default {3D} view by default, so the data of the root node is directly fetched without specifying the viewerableId.
function onDocumentLoadSuccess(doc) {
    // if a viewableId was specified, load that view, otherwise the default view
    var viewables = (viewableId ? doc.getRoot().findByGuid(viewableId) : doc.getRoot().getDefaultGeometry()); 
      viewer.loadDocumentNode(doc, viewables, { ids: global_queryBuilder.ids }).then(i => {
        });
  1. If you do not make any development adjustments, you can use the extension Autodesk.DocumentBrowser that comes with the Viewer. After loading this extension, in the dialog box opened on the toolbar, all converted 3D models and 2D drawings/views will be listed, click You can switch loading flexibly. This dialog box also includes the stage model view , which are all concentrated under the node of this Guid (08f99ae5-b8be-4f8d-881b-128675723c10). Guid is the Forge Management stage model view unique id, any Revit models are the same.

  1. Phase model view is not available in Revit, only the phase setting (Phase). Start the conversion Forge conversion must set generateMasterViews = true, then the stage model view organization work will be done. Otherwise, there will be no stage model view
{
         "input": {
           "urn": "{{urnBase64}}" 
         },
         "output": {
           "destination": {
             "region": "us"
           },
           "formats": [
             {
               "type": "svf",
               "views": [
                 "2d",
                 "3d"
               ],"advanced":{
                 "generateMasterViews":true
             }   
             } 
           ] 
         }
       }
  1. Imported drawings (such as DWG) are integrated with the original Revit model, and only need to follow the regular conversion requirements. At present, the two-dimensional DWG has been merged, and some graphic elements will be displayed a little problem. The development department has known it and is studying and improving it.
  2. Linked models are additional data content. If only the main Revit model is converted, these linked models will not be converted. Get Manifest will inform you that the xxx file is missing.. If you need to link the model content, there are several ways:
    8.1) Package the main Revit model and the link model as a zip, send the zip to the Forge service for conversion, and set the conversion options
{
    "input": {
        "urn": "{{urnBase64}}",
        "compressedUrn":true,
        "rootFilename":"main.rvt"
        },
    "output": {
         "destination": {
            "region": "us"
        },
        "formats": [
        {
            "type": "svf",
            "views":["2d", "3d"]
        } 
        ]
    }
}

8.2) Convert the main Revit model and the link model separately, and then merge them in the Viewer through model aggregation. Reference model aggregation of special courses
8.3) In BIM 360 or ACC, the main Revit model and the link model are uploaded separately and converted separately. You only need to POST the Xref mode link. This blog has a detailed description.

  1. Whether it is a two-dimensional drawing or a three-dimensional model, or even a three-dimensional model and a two-dimensional drawing, aggregation work can be done. Free to merge in order to load a conventional manner, in model aggregation of special courses there is talk, but recommended AggregateView Viewer class of , or directly Viewer comes with extended Autodesk.AEC.Hypermodeling (underlying mechanism is also used To the AggregateView class).

梁晓冬
527 声望301 粉丝

现就职于Autodesk软件中国有限公司,主要负责Autodesk产品API和APS云服务的推广和传播工作。


引用和评论

0 条评论