Пример #1
0
        public void jog_zoom(int speed, ZOOM_DIRECTION direction)
        {
            if (!hardware_connected)  // No motion commands allowed now
                return;

            lock (command_buffer)
            {
                // Eliminate any zoom command from the buffer
                for (int i = 0; i < command_buffer.Count; ++i)
                    if (command_buffer[i] is zoom_absolute_command || command_buffer[i] is zoom_cancel_command ||
                        command_buffer[i] is zoom_jog_command || command_buffer[i] is zoom_stop_jog_command)  // There's already a zoom command that is awaiting dispatch
                        command_buffer.RemoveAt(i);

                command_buffer.Add(new zoom_jog_command(camera_num, speed, direction));  // Add it to the end of the buffer
            }
        }
Пример #2
0
 public zoom_jog_command(int camera_number, int speed = 4, ZOOM_DIRECTION d = ZOOM_DIRECTION.OUT)
     : base(camera_number)
 {
     zoom_speed = speed;
     direction = d;
 }