Ejemplo n.º 1
0
        // Camera = new Camera(new Vector3(0, 0, -5), new Vector3(0, 0, 1));
        public Image TraceRay(Viewport viewport, Camera camera, Scene scene)
        {
            var image = new Image(viewport);
            Color[,] colours;

            for (int y = 0; y < viewport.Height; y++)
            {
                for (int x = 0; x < viewport.Width; x++)
                {
                    Ray ray = camera.GetRay(x, y, viewport);

                }
            }

            throw new NotImplementedException();
        }
Ejemplo n.º 2
0
 public Camera(Vector3 position, Vector3 direction, Viewport viewport)
 {
     Position = position;
     Direction = direction;
     ViewPort = viewport;
 }
Ejemplo n.º 3
0
 public Image(Viewport data)
     : this(data.Width, data.Height)
 {
 }