/// <summary>以回溯的方式寻找对应线段</summary> /// <param name="frcpl">大比例尺线状要素</param> /// <param name="tocpl">小比例尺线状要素</param> /// <param name="CFrEdgeLt">大比例尺线段</param> /// <param name="CToEdgeLt">小比例尺线段</param> /// <param name="frlastcpllt">大比例尺终点线段(只有一个点)</param> /// <param name="tolastcpllt">小比例尺终点线段(只有一个点)</param> /// <returns>对应线段数组</returns> public C5.LinkedList <CCorrespondSegment> FindCorrespondSegmentLk(CTable[,] T, CPolyline frcpl, CPolyline tocpl, List <CPolyline> CFrEdgeLt, List <CPolyline> CToEdgeLt) { C5.LinkedList <CCorrespondSegment> CorrespondSegmentLk = new C5.LinkedList <CCorrespondSegment>(); int i = CFrEdgeLt.Count; int j = CToEdgeLt.Count; while (i >= 0 && j >= 0) { CPolyline frcplw = new CPolyline(); CPolyline tocplw = new CPolyline(); if (i == 0 && j == 0) { break; } else //其它行列的情况 { frcplw = frcpl.GetSubPolyline(CFrEdgeLt[i - T[i, j].intBackK].cptlt[0], CFrEdgeLt[i - 1].cptlt[1]); tocplw = CToEdgeLt[j - 1]; i = i - T[i, j].intBackK; j = j - 1; } CCorrespondSegment pCorrespondSegment = new CCorrespondSegment(); pCorrespondSegment = new CCorrespondSegment(frcplw, tocplw); CorrespondSegmentLk.Insert(0, pCorrespondSegment); } return(CorrespondSegmentLk); }
public C5.LinkedList <CCorrespondSegment> DWByOptCorSimplified(CPolyline frcpl, CPolyline tocpl, int intMaxBackK, CPoint StandardVetorCpt) { double dblSmallDis = CGeometricMethods.CalSmallDis(frcpl); List <CPolyline> CFrEdgeLt = CGeometricMethods.CreateCplLt(frcpl.cptlt); List <CPolyline> CToEdgeLt = CGeometricMethods.CreateCplLt(tocpl.cptlt); CTable[,] T = CreatT(frcpl, tocpl, CFrEdgeLt, CToEdgeLt, intMaxBackK, StandardVetorCpt); //创建T矩阵 C5.LinkedList <CCorrespondSegment> pCorrespondSegmentLk = FindCorrespondSegmentLk(T, frcpl, tocpl, CFrEdgeLt, CToEdgeLt); return(pCorrespondSegmentLk); }
/// <summary> /// Standard ctor for new runtime state /// </summary> /// <param name="numGlobals">Number of global variables in the associated script</param> public RuntimeState(int numGlobals) { MemInfo = new MemoryInfo(); Globals = new object[numGlobals]; Operands = new Stack <object>(64); Calls = new Stack <StackFrame>(64); EventQueue = new C5.LinkedList <PostedEvent>(); ActiveListens = new Dictionary <int, ActiveListen>(); MiscAttributes = new Dictionary <int, object[]>(); LocalDisable = LocalDisableFlag.None; this.Reset(); }
/// <inheirtdoc /> public HistoryService() { Service = this; _undoStack = new C5.LinkedList <HistoryAction>(); _redoStack = new C5.LinkedList <HistoryAction>(); _waypoints = new List <string>(); Undone = new Signal <string>(this); Redone = new Signal <string>(this); WaypointSet = new Signal <string>(this); _enabled = true; }
/// <summary> /// Standard ctor for new runtime state /// </summary> /// <param name="numGlobals">Number of global variables in the associated script</param> public RuntimeState(int numGlobals) { MemInfo = new MemoryInfo(); Globals = new object[numGlobals]; Operands = new Stack<object>(64); Calls = new Stack<StackFrame>(64); EventQueue = new C5.LinkedList<PostedEvent>(); ActiveListens = new Dictionary<int, ActiveListen>(); MiscAttributes = new Dictionary<int, object[]>(); LocalDisable = LocalDisableFlag.None; this.Reset(); }
public void C5_LinkedList() => _ = new C5.LinkedList <Int32>();