public ViewInfo(Document doc, ObjectId rasterObjectId) { Extent extentFromObject = DocUtil.GetExtentFromObject(doc, rasterObjectId); this.Width = extentFromObject.XMax.Value - extentFromObject.XMin.Value; this.Height = extentFromObject.YMax.Value - extentFromObject.YMin.Value; this.CenterPoint = new Point2d(extentFromObject.XMin.Value + this.Width / 2.0, extentFromObject.YMin.Value + this.Height / 2.0); }
public void UpdateToCurrentView() { this.DrawnViewInfo = DocUtil.GetExtentFromObject(this.ParentDataset.ParentDocument, this.RasterObjectId); this.UpdateIfNeeded(); }