Revit add-in to build up model automatically based on DWG drawings. This is a toy project in progress and any test or joint development are welcome.
manicotti
β /Demo
β β *.dwg - DWG file for testing
β β *.jpg - Screenshot
β β *.dll - Plugin DLL (Revit 2022)
β /Manicotti
β /Properties - Assembly info
β /Resources
β β /ico - Button icon files
β β /lib - Teigha DLL files
β β /rfa - Revit family files
β /Util
β β *.cs - Utility methods
β /Views
β β *.xaml - WPF View document
β β *.cs
β Manicotti.csproj - Configuration XML
β Manicotti.sln - VS solution file
β App.cs - Entry point
β *.cs - Class library
β Manicotti.addin - Application manifest
Test the demo by Revit 2022 (en-US) with all default family libraries installed. The default folder for Revit Add-in is C:\ProgramData\Autodesk\Revit\Addins\2022\
, or C:\Users\$username$\AppData\Roaming\Autodesk\Revit\Addins\2022\
.
The build events of the Visual Studio project will copy all necessary files to that directory after you build the source code. In case that you don't have VS, you need to copy those plugin files manually under that directory. Like this:
ProgramData\Autodesk\Revit\Addins\2022\
β /Manicotti
β β TD_*.dll - Copy from /Resources/lib
β β Manicotti.dll - Copy from /Demo
β Manicotti.addin - Copy from /Manicotti
Then start Revit and (video ref):
- Insert -> Link CAD ->
...\Demo\Link_floor.dwg
- Manicotti -> Settings (check if all .rfa files are loaded)
- Manicotti -> Build up model on all Levels
- Select the linked DWG in the floorplan view (process takes almost 1min)
The Manicotti add-in has been tested against Revit 2022. To apply it to other versions you need to rebuild it with correct .NET Framework.
Revit 2022/2021 - .NET 4.8
Revit 2020/2019 - .NET 4.7
Revit 2018 - .NET 4.6
REFERENCE | The project hosts two external references, RevitAPI.dll
and RevitAPIUI.dll
. You can locate them under ...\Autodesk\Revit 2022\
BUILD EVENTS | Set additional macros in post-build event to copy the built files to the Revit add-in folder.
if exist "$(AppData)\Autodesk\REVIT\Addins\2022" copy "$(ProjectDir)*.addin" "$(AppData)\Autodesk\REVIT\Addins\2022"
if exist "$(AppData)\Autodesk\REVIT\Addins\2022" mkdir "$(AppData)\Autodesk\REVIT\Addins\2022\Manicotti"
copy "$(ProjectDir)$(OutputPath)*.dll" "$(AppData)\Autodesk\REVIT\Addins\2022\Manicotti"
copy "$(ProjectDir)Resources\rfa\*.rfa" "$(AppData)\Autodesk\REVIT\Addins\2022\Manicotti"
DEBUG | Within the project property, under DEBUG panel set external program as ...\Autodesk\Revit 2022\Revit.exe
This project uses Teigha for temporary development.
To-do list moved to TaskBoard
A demo is online to build up the building model from CAD drawings. Only core components are covered (wall column window door room floor roof). For now the project still needs more cunning & robust algorithms to sort out layers/components and reshape the geometry, which will be the main theme in the next-phase coding.