예제 #1
0
        private void LoadFile(int index, string filename)
        {
            System.IO.StreamReader streamReader     = new System.IO.StreamReader(filename);
            LocateFileReader       locateFileReader = new LocateFileReader(streamReader);

            loadedFiles[index] = locateFileReader.Read();

            rawData3KHz[index]        = loadedFiles[index].Channel1Data;
            calibration3KHz[index]    = new Calibration(loadedFiles[index].Calibration3KHz);
            calibratedData3KHz[index] = new CalibratedDataSet(calibration3KHz[index], rawData3KHz[index]);

            rawData24KHz[index]        = loadedFiles[index].Channel2Data;
            calibration24KHz[index]    = new Calibration(loadedFiles[index].Calibration24KHz);
            calibratedData24KHz[index] = new CalibratedDataSet(calibration24KHz[index], rawData24KHz[index]);

            mixedCalibration[index]    = loadedFiles[index].CalibrationMixed;
            mixedCalibratedData[index] = new MixedCalibratedDataSet(mixedCalibration[index], calibratedData3KHz[index], calibratedData24KHz[index]);

            UpdateTrackBarsFromSelectedCalibration();
            UpdateCalibrationLabels();

            if (mixedCalibratedData[0] != null && mixedCalibratedData[1] != null)
            {
                subtractedData = new SubtractedDataSet(mixedCalibratedData[0], mixedCalibratedData[1]);
            }
        }
예제 #2
0
        private void LoadFile(int index, string filename)
        {
            System.IO.StreamReader streamReader = new System.IO.StreamReader(filename);
            LocateFileReader locateFileReader = new LocateFileReader(streamReader);
            loadedFiles[index] = locateFileReader.Read();

            rawData3KHz[index] = loadedFiles[index].Channel1Data;
            calibration3KHz[index] = new Calibration(loadedFiles[index].Calibration3KHz);
            calibratedData3KHz[index] = new CalibratedDataSet(calibration3KHz[index], rawData3KHz[index]);

            rawData24KHz[index] = loadedFiles[index].Channel2Data;
            calibration24KHz[index] = new Calibration(loadedFiles[index].Calibration24KHz);
            calibratedData24KHz[index] = new CalibratedDataSet(calibration24KHz[index], rawData24KHz[index]);

            mixedCalibration[index] = loadedFiles[index].CalibrationMixed;
            mixedCalibratedData[index] = new MixedCalibratedDataSet(mixedCalibration[index], calibratedData3KHz[index], calibratedData24KHz[index]);

            UpdateTrackBarsFromSelectedCalibration();
            UpdateCalibrationLabels();

            if (mixedCalibratedData[0] != null && mixedCalibratedData[1] != null)
                subtractedData = new SubtractedDataSet(mixedCalibratedData[0], mixedCalibratedData[1]);
        }