Access corner points for dimensioning

Hi All,

Is there away to get corner points accessed through dynamo as per below?

All i want is to get that blue point you get when you hover dimension tool over element in revit.

Is this even posable?

image

Regards

Yes it is possible. That point is actually the vertical line in most cases, but you can use points as well. Look into Genius Loci or the Reference section of the Revit API.

2 Likes

Hello, The Genius loci package has nodes, but read the author’s advice carefully. see screen
Maybe you can look at its code to get it in your direction.

Sincerely
christian.stan

2 Likes

Thanks @jacob.small

Is this only works with familys?

Say i have direct shapes generated by dynamo and im only able to dim to surfaces at the moment.

As shapes are not uniform and i struggling to get 2 refs for dims.

Genius Loci node give me all nulls or empty lists.

Regards

No, it will work with a project as well. I am not sure how to best attain them from your direct shapes though, as I have no idea how they look. Post some files and I might be able to jump into it tomorrow, if someone else does t beat me to it.

1 Like

Hi @jacob.small Thanks for your time

Please see attached.

DirectShapes dims.dyn (87.0 KB)
DirectShapes.rvt (6.1 MB)

Regards

Hi @dkeinys not sure if something here could work for you

Revit_zUE1DqxHXE

2 Likes

Hi Sovitek,

Thanks for your time.

I don’t have issue creating dims to faces. Issue i have i dont have enough of them to dim to hence why i asked if there a way to dim to points instead.

Regards

havent tried with dim ref point. but probably something goin on when its directshape, i have just very fast tried your example

1 Like

Hi I tried to dig a little,
I started from one side to recover the curves and edges
But the GetEndPointReference method of the Edge class, I can’t use it, I’ll leave the script to you if you want to dig in that direction

import sys
import clr
import System
from System.Collections.Generic import *
clr.AddReference("RevitAPI")
clr.AddReference("RevitAPIUI")
from Autodesk.Revit.DB import *
from Autodesk.Revit.UI import *
from Autodesk.Revit.UI.Selection import *
clr.AddReference('RevitServices')
import RevitServices
from RevitServices.Persistence import DocumentManager
doc=DocumentManager.Instance.CurrentDBDocument
uidoc=DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument

flag = IN[0]

if flag:
    ref = uidoc.Selection.PickObject(ObjectType.Face,"Select a face")
elt=doc.GetElement(ref)
face=elt.GetGeometryObjectFromReference(ref)
lstcurv=face.GetEdgesAsCurveLoops()
lstedges=face.EdgeLoops
refp=ReferenceArray()
refpts=[]
for e in lstedges[0]:
    refp.Append(e.GetEndPointReference(0))
refpts.append(refp)
OUT = face,lstcurv,lstedges,refpts,lstedges[0]

cordially
christian.stan

1 Like