protected void CreateBoardModels(ContentPackage package)
        {
            MeshGroup group   = package.LoadMeshGroup(BoardMeshSource);
            int       texture = package.LoadTexture(BoardTextureSource);

            DiffuseMaterial material = new DiffuseMaterial(texture, BoardMaterialName);

            material.Load(package);
            RenderScene.AddMaterial(material);

            Model pawn = new Model()
            {
                Name = BoardModelName, Material = material, MeshGroup = group
            };

            RenderScene.AddModel(pawn);

            RenderNode node = new RenderNode()
            {
                Model     = pawn,
                Transform = Matrix4.Identity
            };

            RenderScene.AddRenderNode(node);
        }
        protected void CreateSelector(ContentPackage package)
        {
            SolidColorSpecularMaterial materialGray = new SolidColorSpecularMaterial(new Vector3(.5f, .5f, 1f), SelectorMaterialName);

            materialGray.Load(package);
            RenderScene.AddMaterial(materialGray);
            materialGray.LightDirection = new Vector3(1f, -1f, 0f);
            materialGray.Shininess      = 3f;
            materialGray.Specularity    = .5f;

            MeshGroup selectorMesh  = package.LoadMeshGroup(SelectorMeshSource);
            Model     selectorModel = new Model()
            {
                Name = SelectorModelName, Material = materialGray, MeshGroup = selectorMesh
            };

            RenderScene.AddModel(selectorModel);

            selector = new RenderNode()
            {
                Model = selectorModel, Transform = Matrix4.Identity
            };
            RenderScene.AddRenderNode(selector);
        }
        protected void CreatePieceModels(ContentPackage package)
        {
            Material materialWhite = RenderScene.Materials[MaterialWhiteName];
            Material materialBlack = RenderScene.Materials[MaterialBlackName];

            MeshGroup mesh      = package.LoadMeshGroup(Pawn.MeshSource);
            Model     pawnWhite = new Model()
            {
                Name = Pawn.ModelWhite, Material = materialWhite, MeshGroup = mesh
            };

            RenderScene.AddModel(pawnWhite);
            Model pawnBlack = new Model()
            {
                Name = Pawn.ModelBlack, Material = materialBlack, MeshGroup = mesh
            };

            RenderScene.AddModel(pawnBlack);

            mesh = package.LoadMeshGroup(Knight.MeshSource);
            Model knightWhite = new Model()
            {
                Name = Knight.ModelWhite, Material = materialWhite, MeshGroup = mesh
            };

            RenderScene.AddModel(knightWhite);
            Model knightBlack = new Model()
            {
                Name = Knight.ModelBlack, Material = materialBlack, MeshGroup = mesh
            };

            RenderScene.AddModel(knightBlack);

            mesh = package.LoadMeshGroup(Bishop.MeshSource);
            Model bishopWhite = new Model()
            {
                Name = Bishop.ModelWhite, Material = materialWhite, MeshGroup = mesh
            };

            RenderScene.AddModel(bishopWhite);
            Model bishopBlack = new Model()
            {
                Name = Bishop.ModelBlack, Material = materialBlack, MeshGroup = mesh
            };

            RenderScene.AddModel(bishopBlack);

            mesh = package.LoadMeshGroup(Rook.MeshSource);
            Model rookWhite = new Model()
            {
                Name = Rook.ModelWhite, Material = materialWhite, MeshGroup = mesh
            };

            RenderScene.AddModel(rookWhite);
            Model rookBlack = new Model()
            {
                Name = Rook.ModelBlack, Material = materialBlack, MeshGroup = mesh
            };

            RenderScene.AddModel(rookBlack);

            mesh = package.LoadMeshGroup(Queen.MeshSource);
            Model queenWhite = new Model()
            {
                Name = Queen.ModelWhite, Material = materialWhite, MeshGroup = mesh
            };

            RenderScene.AddModel(queenWhite);
            Model queenBlack = new Model()
            {
                Name = Queen.ModelBlack, Material = materialBlack, MeshGroup = mesh
            };

            RenderScene.AddModel(queenBlack);

            mesh = package.LoadMeshGroup(King.MeshSource);
            Model kingWhite = new Model()
            {
                Name = King.ModelWhite, Material = materialWhite, MeshGroup = mesh
            };

            RenderScene.AddModel(kingWhite);
            Model kingBlack = new Model()
            {
                Name = King.ModelBlack, Material = materialBlack, MeshGroup = mesh
            };

            RenderScene.AddModel(kingBlack);
        }