<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: CAD file Extended Entity Data Used in Revit? in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10879455#M21404</link>
    <description>&lt;P&gt;Regarding a polyline what you would do is read a byte stream into a set of number structures that represent the ords of each polyline point. If you were to use Integer for example then each Integer would take 32 bits of data. So ignoring the fractional part of the double and ensuring all the ord values are between Int.MinValue and Int.MaxValue you can store 32x3 bits of data for each polyline point in order from the stream. In reality however doubles like everything have a binary representation. You probably want to constrain the polyline to a certain section of the dwg so that aspect is the biggest factor in limiting the amount of bytes stored per coord rather than what a double or integer can actually store.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can do similar for points along a location curve i.e. in a pure binary form a point at a certain fixed interval from the start of the location line is either there (1) or it isn't (0). For larger number systems it is simply a case of how many points at each slot location.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;By exchange file I mean binary/xml/json anything serialised by the AutoCAD API that is deserialised by the Revit API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes a key is required for relational database objects, you have handles in AutoCAD for each object but those don't come through. So perhaps relative location of an object from a given point is the best key. That would be a common aspect in Revit and AutoCAD geometry.&lt;/P&gt;</description>
    <pubDate>Fri, 14 Jan 2022 10:32:46 GMT</pubDate>
    <dc:creator>RPTHOMAS108</dc:creator>
    <dc:date>2022-01-14T10:32:46Z</dc:date>
    <item>
      <title>CAD file Extended Entity Data Used in Revit?</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10878123#M21401</link>
      <description>&lt;P&gt;I am planning an addin based on a Dynamo script that creates building models with LOD 200/300.&amp;nbsp; &amp;nbsp;Using &lt;A href="https://www.safe.com/" target="_blank" rel="noopener"&gt;FME&lt;/A&gt;, I am able process CAD floor plans for almost all data needed and generate a spreadsheet.&amp;nbsp; It works nicely in Dynamo, but takes awhile to run.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My C# level is advanced beginner, so a bunch of for loops into lists is how I have been organizing the data.&amp;nbsp; It works so far, but is long-winded. I have to wonder if there is a better way than converting coordinates into points, into lines, into walls?&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;FME can also generate CAD files with XData assigned to each entity.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could it be possible to leverage CAD geometry and XData to populate the respective methods?&amp;nbsp; If you can imagine geometry representing a wall centerline with it's Level name, Wall Type and also a UUID (used for door/window placement) all in one object.&amp;nbsp; To access that would be super cool!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The ImportInstance Class has a&amp;nbsp;GetGeometryObjectFromReference Method and also a Geometry property.&amp;nbsp; To be able to use non-converted geometry is the reason for this question.&amp;nbsp; Any feedback is appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;L&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jan 2022 21:31:15 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10878123#M21401</guid>
      <dc:creator>loren_routh</dc:creator>
      <dc:date>2022-01-13T21:31:15Z</dc:date>
    </item>
    <item>
      <title>Re: CAD file Extended Entity Data Used in Revit?</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10878453#M21402</link>
      <description>&lt;P&gt;There is no support for XData within dwg imports in the Revit API, the API only exposes access to geometry.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are certain imaginative ways that data could be encoded into a dwg geometry and then interpreted within a link in Revit:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Encode data into points within polyline (every point gives you three doubles).&lt;/LI&gt;&lt;LI&gt;Add points at fixed intervals along a location line similar to a bar code. You have to put the points on defpoints layer so pdmode is 0 for them otherwise they are represented as other forms of geometry i.e. two lines for the cross of pdmode 3.&lt;/LI&gt;&lt;LI&gt;Create serialised MText objects and read in Revit via custom exporter. You can't read text from dwgs unless they are exploded but custom exporter probably processes them.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;However these things would require encoding the data using the AutoCAD API. So if you are going to do that you may as well not bother and instead use AutoCAD API to extract the data into a separate exchange file for import into Revit via the API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;They are just interesting ideas for adding data in the dwg and getting it out of the link geometry in Revit not very practical compared to other exchange formats. Just a challenge of going beyond what is seemingly possible.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jan 2022 00:02:58 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10878453#M21402</guid>
      <dc:creator>RPTHOMAS108</dc:creator>
      <dc:date>2022-01-14T00:02:58Z</dc:date>
    </item>
    <item>
      <title>Re: CAD file Extended Entity Data Used in Revit?</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10878561#M21403</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1035859"&gt;@RPTHOMAS108&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Very interesting.&amp;nbsp; Just to make sure I understand:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Only access to CAD Geometry via Revit API, no XData or unexploded text.&amp;nbsp; Check.&lt;/LI&gt;&lt;LI&gt;Not sure what you mean by "encoding data in points within a polyline".&amp;nbsp; Are you saying you can encode...text?.. In the points of a line?&amp;nbsp; I do not understand that.&amp;nbsp;&amp;nbsp;&lt;/LI&gt;&lt;LI&gt;When you say "exchange file"&amp;nbsp; are you thinking of a format other than Excel/csv/mdb?&amp;nbsp; &amp;nbsp;XML and json come to mind.&lt;/LI&gt;&lt;LI&gt;I am using&amp;nbsp;FME to create the .dwgs (Standard or RealDwg),&amp;nbsp; so almost anything can be put in.&amp;nbsp;&amp;nbsp;&lt;/LI&gt;&lt;LI&gt;If I were to do CAD geometry (binary/object?) instead of coordinates(doubles), I would need a key identifier to map to the data.&amp;nbsp; The &lt;SPAN&gt;autocad_entity_handle&lt;/SPAN&gt; attribute might work.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Thanks for your insight!&amp;nbsp; This is a really ambitious project for me, but will have a huge payoff.&amp;nbsp; Appreciate the help.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/9342530"&gt;@loren_routh&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jan 2022 00:53:59 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10878561#M21403</guid>
      <dc:creator>loren_routh</dc:creator>
      <dc:date>2022-01-14T00:53:59Z</dc:date>
    </item>
    <item>
      <title>Re: CAD file Extended Entity Data Used in Revit?</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10879455#M21404</link>
      <description>&lt;P&gt;Regarding a polyline what you would do is read a byte stream into a set of number structures that represent the ords of each polyline point. If you were to use Integer for example then each Integer would take 32 bits of data. So ignoring the fractional part of the double and ensuring all the ord values are between Int.MinValue and Int.MaxValue you can store 32x3 bits of data for each polyline point in order from the stream. In reality however doubles like everything have a binary representation. You probably want to constrain the polyline to a certain section of the dwg so that aspect is the biggest factor in limiting the amount of bytes stored per coord rather than what a double or integer can actually store.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can do similar for points along a location curve i.e. in a pure binary form a point at a certain fixed interval from the start of the location line is either there (1) or it isn't (0). For larger number systems it is simply a case of how many points at each slot location.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;By exchange file I mean binary/xml/json anything serialised by the AutoCAD API that is deserialised by the Revit API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes a key is required for relational database objects, you have handles in AutoCAD for each object but those don't come through. So perhaps relative location of an object from a given point is the best key. That would be a common aspect in Revit and AutoCAD geometry.&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jan 2022 10:32:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10879455#M21404</guid>
      <dc:creator>RPTHOMAS108</dc:creator>
      <dc:date>2022-01-14T10:32:46Z</dc:date>
    </item>
    <item>
      <title>Re: CAD file Extended Entity Data Used in Revit?</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10882471#M21405</link>
      <description>&lt;P&gt;Well, I have no clue how to do what you suggest or where to start, but it is amazing that's even possible!&lt;/P&gt;&lt;P&gt;I will close out this post and continue to research AutoCAD API (and learn more C#).&amp;nbsp; My current plan is to get data from the dwg file without linking to Revit.&amp;nbsp; Thanks again for your insight.&lt;/P&gt;</description>
      <pubDate>Sat, 15 Jan 2022 23:22:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/cad-file-extended-entity-data-used-in-revit/m-p/10882471#M21405</guid>
      <dc:creator>loren_routh</dc:creator>
      <dc:date>2022-01-15T23:22:30Z</dc:date>
    </item>
  </channel>
</rss>

