Search Unity

Accessing Revit Document Level Data

Discussion in 'Unity Reflect' started by odehit, Aug 9, 2020.

  1. odehit

    odehit

    Joined:
    Aug 5, 2020
    Posts:
    6
    Is there any way to access data that is stored at Document level in Revit and not in a Family Instance? Specifically I am looking at accessing the list and order of Phases in a Revit project.

    If the Revit plug-in in its current state does not export this data to the model, is there a way we can modify the Revit add-in to add more data to the exported model?
     
  2. quintus_smit

    quintus_smit

    Joined:
    May 15, 2019
    Posts:
    35
  3. mika_leonard

    mika_leonard

    Unity Technologies

    Joined:
    Dec 9, 2019
    Posts:
    20
    Providing document level metadata is on our to do list. Indeed, as quintus_smit mentionned, only the metadata associated with the elements will be exported.

    The workaround is in the Unity editor side for now. When I faced this issue in the past, I had to write a script that gathers all the values of the parameter (in this case the Phase) of the scene's objects and recreate a clean list from there
     
  4. odehit

    odehit

    Joined:
    Aug 5, 2020
    Posts:
    6
    Thank you all for the answers, you confirmed what I was afraid of.

    I know workarounds can be used at the moment, but since this kind of sequencing data is already well baked in the Revit project it seems odd to have to add less structured data to accomplish this.

    At the moment I think the best way would be to collect all the Phases one can see in the Editor, like mika_leonard suggested, and try to sort them using the information that an element is always built before it's demolished.

    I look forward to the plugin adding this data, since it's readily available in the Revit API.
     
  5. mika_leonard

    mika_leonard

    Unity Technologies

    Joined:
    Dec 9, 2019
    Posts:
    20
    UnityPeterD likes this.