void FFTCallback(float[] fftData) //data received { Dispatcher.Invoke(() => { // MatrixFrame.FFTToFrame(fftData); MatrixFrame.FillFrame(new Pixel(0, 0, 0)); float[] downSampledData = ResizeSampleArray(fftData, MatrixFrame.Width); for (int i = 0; i < MatrixFrame.Width; i++) { if (SelectedDisplayMode == 0) { MatrixFrame.DrawColumnMirrored(i, (int)(downSampledData[i] * MatrixFrame.Height), _bottomColorPixel, _topColorPixel); } if (SelectedDisplayMode == 1) { MatrixFrame.DrawColumn(i, (int)(downSampledData[i] * MatrixFrame.Height), _bottomColorPixel, _topColorPixel); } } MatrixFrame.Refresh(); }); }
private void PixelOrder_NewLine_Snake_Click(object sender, RoutedEventArgs e) { MatrixFrame.newLine = PixelOrder.NewLine.SN; MatrixFrame.Refresh(); }
private void PixelOrder_StartCorner_BottomRight_Click(object sender, RoutedEventArgs e) { MatrixFrame.startCorner = PixelOrder.StartCorner.BR; MatrixFrame.Refresh(); }
private void PixelOrder_StartCorner_TopLeft_Click(object sender, RoutedEventArgs e) { MatrixFrame.startCorner = PixelOrder.StartCorner.TL; MatrixFrame.Refresh(); }
private void PixelOrder_Orientation_Vertical_Click(object sender, RoutedEventArgs e) { MatrixFrame.orientation = PixelOrder.Orientation.VT; MatrixFrame.Refresh(); }
private void MenuItem_Serial_ColorMode_BPP1Mono_Click(object sender, RoutedEventArgs e) { SerialManager.ColorMode = SerialManager.CMode.BPP1Mono; MatrixFrame.Refresh(); OnColorModeChanged(); }