hexagon logo

Have the roundness of an auto-circle in a variable

Hi there,

I am trying to have the roundness of an auto-element in a variable. I cannot use a dimension as I have 30,000 circles and try to export all of these roudnesses via a script to a txt file.

Does anyone knows how to call the roundness of an auto-circle into a variable?

Thanks in advance.
Parents
  • Hi ,

    Thanks for the code. Real effort here! I tried it and needed to change the iPointCount to iPointCount = DmisCommand.FeatureCommand.NumHits

    However, I still don't get the roundness value. I've investigated it and saw that the underneath part of the code doesn't take the hits from the feature. I found out, like you said, that it works only for CONTACT_CIRCLE_FEATURE, but I'm using the Camera for the measurement. Do you know what to do in order to change for the camera?

    For iCount = 1 To iPointCount
    ' Vector "CIR1.HIT[1..CIR1.NUMHITS].XYZ-CIR1.XYZ"
    dVectorX = DmisCommand.GetText(MEAS_X, iCount) - CirCenterX
    dVectorY = DmisCommand.GetText(MEAS_Y, iCount) - CirCenterY
    dVectorZ = DmisCommand.GetText(MEAS_Z, iCount) - CirCenterZ
    
    MsgBox dVectorX & " " & dVectorY & " " & dVectorZ


    I checked with the Tactile probing, but the roundness was different bij 0.2 between PC-DMIS GeoTol calculation. ​
Reply
  • Hi ,

    Thanks for the code. Real effort here! I tried it and needed to change the iPointCount to iPointCount = DmisCommand.FeatureCommand.NumHits

    However, I still don't get the roundness value. I've investigated it and saw that the underneath part of the code doesn't take the hits from the feature. I found out, like you said, that it works only for CONTACT_CIRCLE_FEATURE, but I'm using the Camera for the measurement. Do you know what to do in order to change for the camera?

    For iCount = 1 To iPointCount
    ' Vector "CIR1.HIT[1..CIR1.NUMHITS].XYZ-CIR1.XYZ"
    dVectorX = DmisCommand.GetText(MEAS_X, iCount) - CirCenterX
    dVectorY = DmisCommand.GetText(MEAS_Y, iCount) - CirCenterY
    dVectorZ = DmisCommand.GetText(MEAS_Z, iCount) - CirCenterZ
    
    MsgBox dVectorX & " " & dVectorY & " " & dVectorZ


    I checked with the Tactile probing, but the roundness was different bij 0.2 between PC-DMIS GeoTol calculation. ​
Children
No Data