コード例 #1
0
        public static void DAEFile(string arg)
        {
            XFile file = Collada.Utils.ImportCOLLADA(arg, SharpDX.Matrix.RotationX(SharpDX.MathUtil.PiOverTwo), true, true);

            using (FileStream stream = new FileStream(Path.ChangeExtension(arg, ".x"), FileMode.Create, FileAccess.Write, FileShare.Read))
                using (BinaryWriter writer = new BinaryWriter(stream))
                {
                    file.Write(writer);
                }
        }
コード例 #2
0
        public static void OBJFile(string arg)
        {
            Console.WriteLine("    Writing X file...");

            XFile file = XUtils.ImportOBJ(arg, SharpDX.Matrix.RotationX(SharpDX.MathUtil.PiOverTwo), true, true);

            using (FileStream stream = new FileStream(Path.ChangeExtension(arg, ".x"), FileMode.Create))
                using (BinaryWriter writer = new BinaryWriter(stream))
                {
                    file.Write(writer);
                }
        }