Example #1
0
        /// <summary>
        /// Handles calling singleSample for RayVisualizer and picture box image pan control
        /// </summary>
        /// <param name="sender">Not needed</param>
        /// <param name="e">Needed for mouse button detection and cursor location</param>
        private void pictureBox1_MouseMove(object sender, MouseEventArgs e)
        {
            bool condition = aThread == null &&
                             e.Button != MouseButtons.None &&
                             e.Button != panAndZoom.Button &&
                             MT.sceneRendered &&
                             !MT.renderingInProgress;

            panAndZoom.OnMouseMove(e, singleSample, condition, ModifierKeys, out Cursor cursor);

            if (cursor != null)
            {
                Cursor = cursor;
            }
        }