예제 #1
0
        public override Box2D ComputeBox(Transform2D transf)
        {
            Box2D box = new Box2D();

            foreach (PicEntity entity in _entities)
            {
                PicDrawable drawable = entity as PicDrawable;
                if (null != drawable)
                {
                    box.Extend(drawable.ComputeBox(transf));
                }
            }
            return(box);
        }
예제 #2
0
 protected override bool Evaluate()
 {
     _box.Reset();
     foreach (PicEntity entity in _entities)
     {
         PicDrawable drawable = entity as PicDrawable;
         if (null != drawable)
         {
             PicTypedDrawable typeDrawable = drawable as PicTypedDrawable;
             if (null == typeDrawable || typeDrawable.LineType != PicGraphics.LT.LT_CONSTRUCTION)
             {
                 _box.Extend(drawable.ComputeBox(Transform2D.Identity));
             }
         }
     }
     return(true);
 }
예제 #3
0
        public override Box2D ComputeBox(Transform2D transform)
        {
            Box2D box = Box2D.Initial;

            foreach (PicEntity entity in _block)
            {
                PicDrawable drawable = entity as PicDrawable;
                if (null != drawable)
                {
                    PicTypedDrawable typeDrawable = drawable as PicTypedDrawable;
                    if (null == typeDrawable || typeDrawable.LineType != PicGraphics.LT.LT_CONSTRUCTION)
                    {
                        box.Extend(drawable.ComputeBox(transform * BlockTransformation));
                    }
                }
            }
            return(box);
        }