﻿namespace Renderer
{
    public class Mesh
    {
        public Vector3[] Vertices { get; private set; }
        public Vector3[] Uv { get; private set; }
        public Vector3[] Normals { get; private set; }
        public int[] Faces { get; private set; }

        public Mesh(Vector3[] vertices, int[] faces)
        {
            Vertices = vertices;
            Faces = faces;
        }

        public static Mesh FromWaveformObj(string wavefrontText)
        {
            var parser = new WavefrontParser();
            return parser.Parse(wavefrontText);
        }
    }
}