public override void DoIdle() { // Initiate redrawing continuously if (_stopWatch.IsRunning) { UpdateImage?.Invoke(); } }
protected void Logic_ChannelsChanged(int[] channelIds) { if (_useTimeline) { double time = _time.GetValue(); // 0..1 - from mouse input _timeline.SetCurrentTime(time); } // Initiate redrawing UpdateImage?.Invoke(); }
public void SetNewImage(float[] imData, int height) { if (imData == null) { return; } image = imData; if (height < 1) { height = 1; } imHeight = height; imWidth = image.Length / imHeight; UpdateImage?.Invoke(image, imHeight); }
protected void Input_ChannelsChanged(int[] channelIds) { if (!_stopWatch.IsRunning) { return; } double time = GetCurrentTime(); if (Array.IndexOf(channelIds, _channelMouseY.GetId()) != -1) { double mouseY = -_channelMouseY.GetValue(); // flip here Debug.WriteLine("Signal mouse {0}", mouseY); _signalMouse.Add(time, mouseY); _signalMouse.RunCascade(); } // Initiate redrawing UpdateImage?.Invoke(); }