public Form1(string[] args) { singleton = this; InitializeComponent(); progress = new RenderingProgress(this); // Init scenes etc. FormSupport.InitializeScenes(args, out string name); Text += @" (" + rev + @") '" + name + '\''; formTitle = Text; SetWindowTitleSuffix(" Zoom: 100%"); SetOptions(args); buttonRes.Text = FormResolution.GetLabel(ref ImageWidth, ref ImageHeight); // Placeholder image for PictureBox. Image image = Resources.CGG_Logo; additionalViews = new AdditionalViews(collectDataCheckBox, Notification); additionalViews.Initialize(); // Makes all maps to initialize again. additionalViews.SetNewDimensions(ImageWidth, ImageHeight); // Default PaZ button = Right. panAndZoom = new PanAndZoomSupport(pictureBox1, image, SetWindowTitleSuffix) { Button = MouseButtons.Right }; rayVisualizer = new RayVisualizer(); }
/// <summary> /// Prepares lists /// Initial list capacity is small enough to accomodate all elements in most cases /// (used for speed-up since ray registration and rendering should be in real-time) /// </summary> public RayVisualizer() { rays = new List <Vector3> (initialListCapacity); shadowRays = new List <Vector3> (initialListCapacity); singleton = this; }