Beispiel #1
0
        /// <summary>
        /// Exports the specified model to a .OBJ / .MTL file pair.
        /// </summary>
        /// <param name="model">The model to export.</param>
        public System.Collections.Generic.List <int> ExportModel(IRenderable model, string modelName)
        {
            if (model == null)
            {
                throw new ArgumentNullException("model");
            }

            using (ObjMtlRenderer renderer = new ObjMtlRenderer(outputPath, outputFilename))
            {
                return(model.Render(renderer, modelName));
            }
        }
Beispiel #2
0
        /// <summary>
        /// Exports the specified model to a .OBJ / .MTL file pair.
        /// </summary>
        /// <param name="model">The model to export.</param>
        public void ExportModel(IRenderable model)
        {
            if (model == null)
            {
                throw new ArgumentNullException("model");
            }

            using (ObjMtlRenderer renderer = new ObjMtlRenderer(outputPath, outputFilename))
            {
                model.Render(renderer);
            }
        }