Possible Bug Report - Rigid Joint API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi this is to inform Autodesk of a possible glitch/bug in the joint creation API. To explain:
Normal UI behaviour: If I create a rigid joint between 2 faces, and then move or twist either of the faces in any direction, the joint remains rigid and intact.
Apparent API behaviour: A programmatically created rigid joint will remain intact for some movements (turning/translating the face) but not for others (twisting/rotating the face).
I would assume that the behaviour of an API created rigid joint should be the same as a normal UI created joint.
This is an important part of a large customer project we are currently working on. I'll be very happy to provide a dataset/video explaining the problem further as required.
Many thanks,
Luke
ps. Heres the function that creates the rigid joint. This works fine - the problem occurs later when a joint face is moved.
Public Sub AssemblyJoint(face1 As Face, face2 As Face, seljoint1compocc As ComponentOccurrence, seljoint2compocc As ComponentOccurrence)
' create a FaceProxy.
Dim AsmDef As AssemblyComponentDefinition
AsmDef = inventorapp.ActiveDocument.ComponentDefinition
Try
' create a FaceProxy.
Dim face3 As FaceProxy
Dim face4 As FaceProxy
seljoint1compocc.CreateGeometryProxy(face1, face3)
seljoint2compocc.CreateGeometryProxy(face2, face4)
Dim face1Intent As GeometryIntent = AsmDef.CreateGeometryIntent(face3, PointIntentEnum.kPlanarFaceCenterPointIntent)
Dim face2Intent As GeometryIntent = AsmDef.CreateGeometryIntent(face4, PointIntentEnum.kPlanarFaceCenterPointIntent)
Dim intentOne As GeometryIntent = face1Intent
Dim intentTwo As GeometryIntent = face2Intent
Dim jointDef As AssemblyJointDefinition = AsmDef.Joints.CreateAssemblyJointDefinition(AssemblyJointTypeEnum.kRigidJointType, intentTwo, intentOne)
' jointDef.FlipAlignmentDirection = False
jointDef.FlipOriginDirection = True
Dim joint As AssemblyJoint = AsmDef.Joints.Add(jointDef)
' Make the joint visible.
joint.Visible = True
joint1Label.Text = ""
joint1partlab.Text = ""
joint2Label.Text = ""
joint2partlab.Text = ""
Catch ex As Exception
End Try
End Sub