A discussion with Håvard Dagsvik on the use of
TransmissionData, standalone access to the
BasicFileInfo without the need for a valid Revit API context, and a Revit-independent method replacing
– No document required for
TransmissionData requires a valid Revit API context
GetFamilyXmlData method replacing
– Windows explorer
BasicFileInfo right click utility...
Several questions on filtering for intersecting elements came up recently. It is pretty easy as long as a bounding box can be used. However, the bounding box is generally aligned with the cardinal X, Y and Z axes. If the containing volume of interest is not, too many elements may be selected – Family instances in a diagonal room – Conduits intersecting a junction box – Generate 2D arc from radius, start and end points...
An add-in will often need to retrieve the elements that it just created for further processing. Frequently, the Revit API method used to create them will return their element ids. Sometimes, that is not the case. Now this topic arose again in a couple of cases and brought some other aspects to mind – Using the element lister – Consecutive element ids – Retrieving recently added elements – AEC job openings in Munich and elsewhere...
Is there a way to return failure information to your main command when creating a transaction?
My program does some error logging and creates an error report at the end, and I'd like to include some information from specific types of Revit failures (i.e., include if multiple instances were created in the same place).
Yes, you can use the
PreprocessFailures method argument
failuresAccessor to review and store failure message information for later use...
Two recent Revit MEP related cases brought up some new information on the pipe
K factor table and custom calculations for pipe fittings, the Forge DevCon class recordings are now available, and I discovered Konrad Sobon's wonderful archi+lab Revit API blog, which helps resolve an installation and setup issue
K factor table
K factor calculation for pipe fittings
– Dynamo code to change loss coefficient
– Forge DevCon 2017 class recordings
– Revit add-in installer and buttons...
A quick geometrical question on retrieving geometry from a basic wall being used as a panel in a curtain wall.
I am struggling to retrieve the geometry data from a curtain wall that contains a Basic wall in one of the curtain wall panels. My example curtain wall has two panels. With one of the panels, a basic wall type is associated. I need to get the geometry data (i.e., the faces) for the entire curtain wall. When I reach the second panel in my code, the
SymbolGeometry contains zero objects, so my code cannot retrieve any geometry for it...
Here is an official answer from the Revit development team on the long-standing and recurrent issue on retrieving the path to a specific material texture bitmap file
– Question: I am working on an exporter plugin for Revit that exports all geometry from selected objects using the
When extracting object materials, I can successfully get most of the information, but I can't seem to find the path to the material texture
A biggish post rather late in the week... still answering too many cases – Forge for AEC demos and sample code – Determining the starting view – Detecting installed Revit version – Detecting installed C3D version – Moving items inside a detail group – Filtering for family instances and types by family name...
Forge versus Revit programming – Access Revit BIM data and element ids from BIM360 – Unique IDs for Forge viewer elements – Edit and export Revit properties in Forge – Upcoming Forge accelerators – Updated Visual Studio Revit add-in wizard installation – Question on RevitLookup installation – RevitLookup cannot snoop everything...
Depending on circumstances, interactively picked family instance geometry may be returned in the global Revit world coordinate system WCS, or in the family instance definition local coordinate system LCS. A family instance may have its own non-empty solid, or use the symbol geometry. The symbol geometry requires keeping track of the instance transform to map it to the actual instance project location – Question on Incorrect Face Normal – Working Plane has no Effect – Non-Picked Face Normals are Correct – Solution – Detecting When to Use LCS versus WCS – Retrieval of Picked Geometry Face from Instance is Untransformed...
Here is another brilliant and super succinct solution provided by Fair59, answering the Revit API discussion forum thread on how to get cutting void instances in the floor using the
FindInserts method – Question: I have a floor on which a family instance is inserted on the face of the floor (the instance host is also the floor). I checked in the family the "Cut with Void When Loaded" parameter, so that the void is created in the floor. Now, I want to retrieve all the instances that create voids in the floor...
A rather hard struggle led to a rather simple solution for determining the start and end points of dimension segments. In summary, the solution looks like this – A
Dimension element is either single- or multi-segment; these two cases need to be handled separately – In case of a single segment, the dimension element itself has a line, an origin and a value; the line is indeed the dimension line. However, it may be unbounded...
An explanation of the Revit project location elements and selecting the right one to use. I see two project location elements: 'Internal 21748' and 'Project 111428'. The active Project Location is 'Internal 21748'. However, the values in 'Project 111428' are correct and can be used to transform the coordinates, whereas the values in 'Internal 21748' are nonsense. Why is the active project location wrong? How can I determine which of the two to use? What is the difference between these two? ...
Here is another Revit 2018 API enhancement that is obviously worth highlighting, since it immediately answers the question on getting a specific reference from a family instance raised in the Revit API discussion forum: Is it possible to get a named reference plane from a family without going into the family editor API? For example, I would like to have users be able to name a reference plane 'my arbitrary location' when they are creating a family...
We discussed several examples of using the temporary transaction trick TTT in the past. Here is a new exquisitly subtle variant for you to enjoy, provided by Frank @Fair59 Aarssen to get the coordinates of the endpoints for a section marker line segment. Question: I have a section marker that I would like to rotate around one of the endpoints of the line segment leader, but I haven't been able to figure out how to determine the endpoint coordinates...
Are you interested in easy access to your Revit model properties? Well, you can have that even without a need to install Revit. The Forge Model Derivative API extracts a streamlined copy of all geometry, BIM element hierarchy and properties from over fifty file formats, and Revit RVT files are just one of them. Augusto Goncalves implemented a Forge sample to read all the properties on all BIM elements in an RVT file and export them to an XLSX spreadsheet – Test run it yourself – Source code on GitHub...
I already discussed the first clean-up of the new
Reflection based version of RevitLookup; here comes the second one, restoring access to view extensible storage data
– Recent changes to RevitLookup
– Restore access to extensible storage data
– Download and access to old functionality...
Last week, I presented a drastic change to RevitLookup using
Reflection to provide more complete coverage of all the Revit database element methods and properties. Victor Chekalin took a critical look at this new version and cleaned it up significantly. Now all is well and order has been restored again
– Shock and gripe
– Commit summary
– 1. Methods and properties extraction
– 2. Show enum values
– 3. Drill down into
– 4. Remove duplicate
get_ property getter method
– 5. Fixed
– 6. Visual style of separator
– Download and access to old functionality
– Reaction and read-only assurance...
Today, I present a large and drastic contribution to RevitLookup from Andy @awmcc90 McCloskey of RevDev Studios that will help significantly in supporting both past and future releases of Revit
– Drastic changes making use of object inspection via
– Cross version compatibility
– Removal of events and unused functionality
– Commit summary
– File Changes
Let's pick up two more topics from the Revit API discussion forum today
Category property is not always set
– Two different energy analysis model types
– gbXML export options
EnergyAnalysisDetailModel creation from building elements and volumes
I revisited the custom tooltip implementation that I prepared to demonstrate the Revit 2013 API features including the View API and its
UIView class. It class still provides the only possibility to convert back and forth between Revit model coordinates and Windows device screen points. That functionality can be combined with the
ReferenceIntersector to shoot a ray through the model to determine what Revit database element is located under the current cursor position and display a custom tooltip presenting information about it or anything else you please...
Lots of information on, from and about schedule parameters, and a new elegant solution to a long-standing challenge – Direct access to shared parameter GUID – Getting parameter information from a schedule...
A Python Revit API question on renumbering viewports helps highlight two separate important programming aspects; I also add some other notes from the Munich Forge accelerator – Question – The need to regenerate – Use built-in parameters to access parameters – Forge accelerator and outage report – Added materials to 210 King model...
I returned from the Munich Forge accelerator, travelling back to Switzerland by train. For ecological reasons, I prefer to avoid flying whenever I possibly can. Last Friday was the deadline for submitting my Autodesk University handout, so that kept me busy. I still need to improve it a bit, and I hope a post-deadline update is feasible. I am presenting two classes, and I have a special discount to offer you. Lots of other things are happening as well – My classes at Autodesk University – $400 AU registration discount – Revit 2017.1 SDK – REX SDK FreezeDrawing sample – Determining the height of a column...
I updated the WebGL and Forge introduction for BIM programming and its GitHub source for the presentations in the coming days at the RTC Revit Technology Conference Europe and the ISEPBIM Forge and BIM workshops at ISEP, in Porto, implemented two little curl wrapper scripts to help me list the supported file formats, explored why they changed and updated the hackathon webinar overview. Before getting to that, I'll also highlight a helpful note by Christian on how to access the 'Symbolic Representation' setting
– 'Symbolic Representation' setting parameter
– Forge intro for BIM programming
cURL wrapper scripts to list Forge file formats
– Updated Forge file formats
– Forge hackathon webinar series and Fusion 360 Client API recording...
Today is the last day before my one-week vacation, directly followed non-stop by the ISEPBIM Forge and BIM workshops at Porto University, the RTC Revit Technology Conference Europe, and the Forge Accelerator in Munich. Before leaving, here is a note about another recording of the Forge webinar series and a happy resolution of a recent material asset texture related Revit API issue: – Forge webinar series and BIM360 recordings – Listing material asset textures and sub-textures...
Lots of exciting news for today, like every day, once again on the pure Revit API, connecting the desktop and the cloud, and Autodesk Forge – Isolating an element in a newly created view requires two transactions – Forge research enquiry – Connecting desktop and cloud – Roomedit3dv3 live – Could you demo this remotely? – Connecting desktop and cloud draft handout – Table of contents...
My discussion with Philippe on integrating
roomedit3dv3 with the rest of his Forge node.js boilerplate samples continues, as does the Forge hackathon webinar series. Furthermore, the Open Design Alliance made an interesting Revit related announcement
– REST vs WebSocket and Roomedit3dv3 broadcast architecture
– Teigha BIM announcement
– Forge webinar series...
I recently shared Scott Wilson's reference stable representation magic voodoo, and you may have asked yourself what use it is. Well, here is one example making effective use of it, raised and solved by Ola Gunnar Skippervik of Multiconsult – Goal: retrieve family instance edge to create direct shape – Snooping the family instance geometry – Partial answer and suggestion – Confirmation – Summary – Structural concrete setout point add-in...
Here comes a quick clarification of the units used for the
UnitWeight built-in parameter
PHY_MATERIAL_PARAM_UNIT_WEIGHT. One example usage is to calculate the total weight of rebars in a project...
The Forge DevCon last week completed successfully. I had a full body 3D scan created there and used
sed to flip the axes of the resulting OBJ mode. This week, I am sitting in the Autodesk offices at One Market in San Francisco, supporting the fourth Cloud Accelerator. One of the projects we are working on is from the University of Southern California to interact with Revit MEP systems in the Forge viewer. That requires traversing the MEP systems in the Revit model to store, recreate and represent their graph structures in the viewer
– Revit MEP System Traversal
– TraverseAllSystems Revit Add-in
– To do
– Thanks to Mustafa Salaheldin...
I returned from the trip to Barcelona last week for the Forge Accelerator and was immediately inundated with overdue tasks. One issue that I addressed has to do with rendering assets – Roomedit3d Revit-Independent Implementation Aspects – Connecting BIM and the cloud – Demonstrating cool possibilities to enhance interaction with the View and Data API – A viewer extension enabling interactive model modification, i.e., translation of selected elements – Real-time communication of the modification back to the source CAD system using: – A REST API POST call from the viewer extension to the node.js web server – A direct socket.io connection to broadcast from the web server to any number of desktop clients...
A picture says more than a thousand words. I find a compelling and clear picture takes a lot of work, though. I created the image below to explain the context and architecture of the FireRatingCloud and other samples connecting BIM and the cloud like RoomEditorApp, followed by some musings on using Revit as a server – FireRatingCloud context and architecture – You cannot use Revit as a server...
Today, I address the first item in yesterday's to do list
– Document and improve FireRatingClient, the stand-alone Windows client – we will need this to demonstrate the real-time BIM update from arbitrary sources
– Adding the
– Updating the
modified Field on Edit
– FireRatingClient Live BIM Update Demo Recording
– To Do...
Let's end the week with a truly magnificent contribution and research result provided by Scott Wilson in the Revit API discussion forum. Scott responded to Pat Hague's recent thread on converting local family instance coordinate of a selected edge to project coordinates, saying, Yeah the Stable Reference Strings can be used to get at areas of the Geometry API that aren't fully exposed – I love playing around with them. Sometimes I stumble upon something cool such as this solution for a situation in which the geometry returns no reference for a family instance...
Håvard added some clarifications and background information on his sample code to determine wall opening areas per room: I have some questions on Håvard's initial approaches. Using a Boolean subtraction between transient solids from the actual wall and the family symbol sounds like the right track, but I don’t understand the need for the family instance, because the wall already provides the net geometry...