Пример #1
0
        /// <summary>
        /// LoadContent will be called once per game and is the place to load
        /// all of your content.
        /// </summary>
        protected override void LoadContent()
        {
            // Create a new SpriteBatch, which can be used to draw textures.
            spriteBatch = new SpriteBatch(GraphicsDevice);
            IReader3d reader = new Reader3ds();
            using (Stream s = new FileStream("3dObjects/spherecube.3ds", FileMode.Open))
            {
                reader.FillScene(s,scene);
            }

            // TODO: use this.Content to load your game content here
        }
Пример #2
0
        static void Main(string[] args)
        {
            IReader3d reader = new Reader3ds();
            IScene scene = new TestScene();
            using (Stream s = new FileStream("3dObjects/cube.3ds", FileMode.Open))
            {
                reader.FillScene(s, scene);
            }

            IScene scene2 = new TestScene();
            using (Stream s = new FileStream("3dObjects/donutcube.3ds", FileMode.Open))
            {
                reader.FillScene(s, scene2);
            }

            Console.ReadLine();
        }