Thursday, November 12, 2009

(II) New SDO_GEOMETRY <-> Autodesk Map3d 2010

Author: Jonio, Dennis

The DrawAbleType enums were easy. I just had to give them values that could be distinguised via “OR”ing them together.

  • Point = 1,
  • Line = 2,
  • Surface = 4


    Source code (C#):

    I really wrestled with these DrawAbleSubComponentEType enums. I tried to be really clever with these values and somehow take advantage of the relationship between ETYPE and INTERPRETATION. Tried is the operative word.

  • Point = 1, //1
  • PointCluster = 10, //1 + n
  • PointOriented = 19, //Not supported OrientedPoint
  • SimpleLine = 3, //2 + 1
  • SimpleLineAllCurves = 4, //2 + 2
  • CompoundLine = 40, //4 + n
  • SimpleSurfaceOuterRingLine = 1004, //1003 + 1
  • SimpleSurfaceOuterRingAllCurves = 1005, //1003 + 2
  • SimpleSurfaceOuterRingRectangle = 1006, //1003 + 3
  • SimpleSurfaceOuterRingCircle = 1007, //1003 + 4
  • SimpleSurfaceInnerRingLine = 2004, //2003 + 1
  • SimpleSurfaceInnerRingAllCurves = 2005, //2003 + 2
  • SimpleSurfaceInnerRingRectangle = 2006, //2003 + 3
  • SimpleSurfaceInnerRingCircle = 2007, //2003 + 4
  • CompoundSurfaceOuterRingLine = 10050, //1005 + n
  • CompoundSurfaceInnerRingLine = 20050 //2005 + n
    The specification has to many exceptions for this to work but at least I have my unique values.


    I do wonder alot as to why Oracle set up the unique combinations for Circle, Rectangle and instances of all Curves. I did read the spec on “Oriented Point” and just arbitrarily decided NOT to support it. I will never use it and I guess I am the boss. So if you need that you will have to do it yourself. It should be a straight forward job for someone with the motivation.


    When it gets time to resolve these into the “real” ETYPE and INTERPRETATION values I just set up a couple static methods in a static utility class.
    Source code (C#):

    To be continued ...
  • No comments:

    Post a Comment