コード例 #1
0
        public static GraphicalElementData FromType(GraphicalElementTypes type)
        {
            switch (type)
            {
            case GraphicalElementTypes.Normal:
                return(new NormalGraphicalElementData());

            case GraphicalElementTypes.BoundingBox:
                return(new BoundingBoxGraphicalElementData());

            case GraphicalElementTypes.Animated:
                return(new AnimatedGraphicalElementData());

            case GraphicalElementTypes.Entity:
                return(new EntityGraphicalElementData());

            case GraphicalElementTypes.Particles:
                return(new ParticlesGraphicalElementData());

            case GraphicalElementTypes.Blended:
                return(new BlendedGraphicalElementData());

            default:
                return(null);
            }
        }
コード例 #2
0
 public NormalGraphicalElementData(GraphicalElementTypes type = GraphicalElementTypes.Normal) : base(type)
 {
     Origin = new Point();
     Size   = new Point();
 }
コード例 #3
0
 public GraphicalElementData(GraphicalElementTypes type)
 {
     Type = type;
 }