internal MxStdModel Clone() { var model = new MxStdModel(VertCount, FaceCount); Clone(model); return(model); }
internal MxStdSlim(MxStdModel model) { heap = new MxHeap(64); this.model = model; PlacementPolicy = MxPlacement.Optimal; WeightingPolicy = MxWeighting.Area; BoundaryWeight = 1000.0; CompactnessRatio = 0.0; MeshingPenalty = 1.0; LocalValidityThreshold = 0.0; VertexDegreeLimit = 24; WillJoinOnly = false; ValidFaces = 0; ValidVerts = 0; IsInitialized = false; for (var faceId = 0; faceId < model.FaceCount; faceId++) { if (!model.FaceIsValid(faceId)) continue; ValidFaces++; } for (var vertId = 0; vertId < model.VertCount; vertId++) { if (!model.VertexIsValid(vertId)) continue; ValidVerts++; } }
internal MxStdSlim(MxStdModel model) { heap = new MxHeap(64); this.model = model; PlacementPolicy = MxPlacement.Optimal; WeightingPolicy = MxWeighting.Area; BoundaryWeight = 1000.0; CompactnessRatio = 0.0; MeshingPenalty = 1.0; LocalValidityThreshold = 0.0; VertexDegreeLimit = 24; WillJoinOnly = false; ValidFaces = 0; ValidVerts = 0; IsInitialized = false; for (var faceId = 0; faceId < model.FaceCount; faceId++) { if (!model.FaceIsValid(faceId)) { continue; } ValidFaces++; } for (var vertId = 0; vertId < model.VertCount; vertId++) { if (!model.VertexIsValid(vertId)) { continue; } ValidVerts++; } }
internal MxFaceQSlim(MxStdModel model) : base(model) { faceInfo = new MxBlock <TriInfo>(model.FaceCount); }
internal MxStdModel Clone() { var model = new MxStdModel(VertCount, FaceCount); Clone(model); return model; }
internal MxEdgeQSlim(MxStdModel model) : base(model) { edgeLinks = new MxBlock<List<MxQSlimEdge>>(model.VertCount); Contracted += ContractionCallback; }
private void InitBaseModel() { baseModel = new MxStdModel(inputVertices.Count, inputIndices.Count/3) { ColorBinding = MxBinding.UnBound, NormalBinding = MxBinding.UnBound }; foreach(var vec in inputVertices) { baseModel.AddVertex(vec.X, vec.Y, vec.Z); } for (var i = 0; i < inputIndices.Count; ) { baseModel.AddFace(inputIndices[i++], inputIndices[i++], inputIndices[i++]); } }
internal MxEdgeQSlim(MxStdModel model) : base(model) { edgeLinks = new MxBlock <List <MxQSlimEdge> >(model.VertCount); Contracted += ContractionCallback; }
internal MxFaceQSlim(MxStdModel model) : base(model) { faceInfo = new MxBlock<TriInfo>(model.FaceCount); }
internal MxQSlim(MxStdModel model) : base(model) { quadrics = new MxBlock <MxQuadric3>(model.VertCount); ObjectTransform = null; }
internal MxQSlim(MxStdModel model) : base(model) { quadrics = new MxBlock<MxQuadric3>(model.VertCount); ObjectTransform = null; }