using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Drawing3d;
using Drawing3d.Math;
using Drawing3d.Devices;
namespace Transformations_3D
{
    public partial class Form1 : Form
    {
        // Creates a OpenGlEngine Device
        public OpenGlDevice Device = new OpenGlDevice();
        public Form1()
        {
            InitializeComponent();
        }
        private void Form1_Load(object sender, EventArgs e)
        {
            Device.Navigate = NavigateKind.ZoomRotateTrans;
            // Set the current form as control of the device
            Device.WinControl = this;
            // Adds a paintingmethod to drawing into the form
            Device.OnPaint += new EventHandler(Device_OnPaint);
        }
        void Device_OnPaint(object sender, EventArgs e)
        {
            Tools.drawBoxAt(Device, new xyz(-2, -2, 0), new xyz(2, 2, 2));
            Tools.drawBoxAt(Device, new xyz(-2, 2, 0), new xyz(2, 2, 2));
            Tools.drawBoxAt(Device, new xyz(2, 2, 0), new xyz(2, 2, 2));
            Tools.drawBoxAt(Device, new xyz(2, -2, 0), new xyz(2, 2, 2));

        }
    }
}