public static FaceRecorder Instance(Document doc, IFaceRecordData recordedData)
 {
     if (_instance == null)
     {
         lock (syncRoot)
         {
             if (_instance == null)
             {
                 _instance = new FaceRecorder(doc, recordedData);
             }
         }
     }
     return(_instance);
 }
예제 #2
0
        public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
        {
            uiapp = commandData.Application;
            uidoc = commandData.Application.ActiveUIDocument;
            doc   = commandData.Application.ActiveUIDocument.Document;
            object obj = new object();

            using (Transaction trans = new Transaction(doc, "xxx"))
            {
                trans.Start();

                //Remove();
                Data data = new Data();
                FaceRecorder.Instance(doc, data).Recorder();
                double d = FaceRecorder.Instance(doc, data).Extract("a1");

                trans.Commit();
            }

            return(Result.Succeeded);
        }