Loading testing/D19Proto/ColorMap.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -11,11 +11,11 @@ COLOUR GetColour(double v,double vmin,double vmax) v = vmax; dv = vmax - vmin; if (v < (vmin + 0.4 * dv)) { if (v <= (vmin + 0.4 * dv)) { c.r = 2.5*(v-vmin) / dv; c.g = 0; c.b = 0; } else if (v < (vmin + 0.8 * dv)) { } else if (v <= (vmin + 0.8 * dv)) { c.r = 1; c.g = 1 + 2.5 * (-vmin - 0.4 * dv + v) / dv; c.b= 0.; Loading testing/D19Proto/D19Proto.pro +9 −4 Original line number Diff line number Diff line Loading @@ -5,6 +5,7 @@ #------------------------------------------------- QT += core gui CONFIG += debug_and_release QMAKE_CXXFLAGS += -std=c++0x -fopenmp TARGET = D19Proto Loading @@ -16,17 +17,22 @@ SOURCES += main.cpp\ Data.cpp \ Logger.cpp \ DetectorView.cpp \ ColorMap.cpp ColorMap.cpp \ qcustomplot.cpp \ Plotter1D.cpp HEADERS += mainwindow.h \ DetectorView.h \ DialogPeakFind.h \ Data.h \ Logger.h \ ColorMap.h ColorMap.h \ qcustomplot.h \ Plotter1D.h FORMS += mainwindow.ui \ dialog_PeakFind.ui dialog_PeakFind.ui \ plotter1d.ui win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../../../../usr/local/NSXTool/ -lNSXTool else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../../../../usr/local/NSXTool/ -lNSXTool Loading @@ -36,4 +42,3 @@ INCLUDEPATH += $$PWD/ /usr/local/include/NSXTool INCLUDEPATH += $$PWD/ /usr/local/include/eigen3 DEPENDPATH += $$PWD/ /usr/local/include/NSXTool CONFIG += qwt testing/D19Proto/D19Proto.pro.user +148 −62 File changed.Preview size limit exceeded, changes collapsed. Show changes testing/D19Proto/Data.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -33,6 +33,8 @@ void Data::readBlock(int i) { _currentFrame=_data[i]; } auto it=std::max_element(_currentFrame.begin(),_currentFrame.end()); _maxCurrentFrame=(*it); } void Data::readInMemory() { Loading @@ -42,8 +44,6 @@ void Data::readInMemory() int count=0; int counter=0; #pragma omp parallel for shared(count) for (int i=0;i<_nblocks;++i) Loading Loading @@ -84,7 +84,7 @@ void Data::getCountsHistogram(std::vector<int>& histo) for (auto i=0;i<_nblocks;++i) { std::vector<int>& d=_data[i]; for (auto j=0;j<d.size();++j) for (unsigned int j=0;j<d.size();++j) { histo[d[j]]++; } Loading testing/D19Proto/Data.h +1 −0 Original line number Diff line number Diff line Loading @@ -34,6 +34,7 @@ struct Data std::vector<int> _sum; bool _inmemory; int _maxCount; int _maxCurrentFrame; std::map<int,SX::Geometry::Ellipsoid<double,3>,std::less<int>, Eigen::aligned_allocator<std::pair<const int, Eigen::Matrix4d> >> _peaks; }; Loading Loading
testing/D19Proto/ColorMap.cpp +2 −2 Original line number Diff line number Diff line Loading @@ -11,11 +11,11 @@ COLOUR GetColour(double v,double vmin,double vmax) v = vmax; dv = vmax - vmin; if (v < (vmin + 0.4 * dv)) { if (v <= (vmin + 0.4 * dv)) { c.r = 2.5*(v-vmin) / dv; c.g = 0; c.b = 0; } else if (v < (vmin + 0.8 * dv)) { } else if (v <= (vmin + 0.8 * dv)) { c.r = 1; c.g = 1 + 2.5 * (-vmin - 0.4 * dv + v) / dv; c.b= 0.; Loading
testing/D19Proto/D19Proto.pro +9 −4 Original line number Diff line number Diff line Loading @@ -5,6 +5,7 @@ #------------------------------------------------- QT += core gui CONFIG += debug_and_release QMAKE_CXXFLAGS += -std=c++0x -fopenmp TARGET = D19Proto Loading @@ -16,17 +17,22 @@ SOURCES += main.cpp\ Data.cpp \ Logger.cpp \ DetectorView.cpp \ ColorMap.cpp ColorMap.cpp \ qcustomplot.cpp \ Plotter1D.cpp HEADERS += mainwindow.h \ DetectorView.h \ DialogPeakFind.h \ Data.h \ Logger.h \ ColorMap.h ColorMap.h \ qcustomplot.h \ Plotter1D.h FORMS += mainwindow.ui \ dialog_PeakFind.ui dialog_PeakFind.ui \ plotter1d.ui win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../../../../../../usr/local/NSXTool/ -lNSXTool else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../../../../../../usr/local/NSXTool/ -lNSXTool Loading @@ -36,4 +42,3 @@ INCLUDEPATH += $$PWD/ /usr/local/include/NSXTool INCLUDEPATH += $$PWD/ /usr/local/include/eigen3 DEPENDPATH += $$PWD/ /usr/local/include/NSXTool CONFIG += qwt
testing/D19Proto/D19Proto.pro.user +148 −62 File changed.Preview size limit exceeded, changes collapsed. Show changes
testing/D19Proto/Data.cpp +3 −3 Original line number Diff line number Diff line Loading @@ -33,6 +33,8 @@ void Data::readBlock(int i) { _currentFrame=_data[i]; } auto it=std::max_element(_currentFrame.begin(),_currentFrame.end()); _maxCurrentFrame=(*it); } void Data::readInMemory() { Loading @@ -42,8 +44,6 @@ void Data::readInMemory() int count=0; int counter=0; #pragma omp parallel for shared(count) for (int i=0;i<_nblocks;++i) Loading Loading @@ -84,7 +84,7 @@ void Data::getCountsHistogram(std::vector<int>& histo) for (auto i=0;i<_nblocks;++i) { std::vector<int>& d=_data[i]; for (auto j=0;j<d.size();++j) for (unsigned int j=0;j<d.size();++j) { histo[d[j]]++; } Loading
testing/D19Proto/Data.h +1 −0 Original line number Diff line number Diff line Loading @@ -34,6 +34,7 @@ struct Data std::vector<int> _sum; bool _inmemory; int _maxCount; int _maxCurrentFrame; std::map<int,SX::Geometry::Ellipsoid<double,3>,std::less<int>, Eigen::aligned_allocator<std::pair<const int, Eigen::Matrix4d> >> _peaks; }; Loading