mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-05-07 20:09:58 -05:00
move call to calculateFilterValues to DataCygnet
This commit is contained in:
@@ -69,8 +69,10 @@ bool DataCygnet::updateTexture(){
|
||||
if(data.empty())
|
||||
return false;
|
||||
|
||||
if(_autoFilter)
|
||||
if(_autoFilter){
|
||||
_dataProcessor->calculateFilterValues(_dataOptions.value());
|
||||
_backgroundValues.setValue(_dataProcessor->filterValues());
|
||||
}
|
||||
|
||||
bool texturesReady = false;
|
||||
std::vector<int> selectedOptions = _dataOptions.value();
|
||||
|
||||
@@ -70,6 +70,7 @@ public:
|
||||
* @return Processed data
|
||||
*/
|
||||
virtual std::vector<float*> processData(const std::string& data, const properties::SelectionProperty& dataOptions, const glm::size3_t& dimensions) = 0;
|
||||
void calculateFilterValues(std::vector<int> selectedOptions);
|
||||
|
||||
void useLog(bool useLog);
|
||||
void useHistogram(bool useHistogram);
|
||||
@@ -82,7 +83,6 @@ public:
|
||||
protected:
|
||||
float processDataPoint(float value, int option);
|
||||
void initializeVectors(int numOptions);
|
||||
void calculateFilterValues(std::vector<int> selectedOptions);
|
||||
void add(std::vector<std::vector<float>>& optionValues, std::vector<float>& sum);
|
||||
|
||||
std::vector<float> _min;
|
||||
|
||||
@@ -134,8 +134,7 @@ std::vector<float*> DataProcessorJson::processData(const std::string& data, cons
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
calculateFilterValues(selectedOptions);
|
||||
//calculateFilterValues(selectedOptions);
|
||||
return dataOptions;
|
||||
}
|
||||
return std::vector<float*>();
|
||||
|
||||
@@ -130,7 +130,7 @@ std::vector<float*> DataProcessorKameleon::processData(const std::string& path,
|
||||
}
|
||||
}
|
||||
|
||||
calculateFilterValues(selectedOptions);
|
||||
//calculateFilterValues(selectedOptions);
|
||||
return dataOptions;
|
||||
}
|
||||
return std::vector<float*>(numOptions, nullptr);
|
||||
|
||||
@@ -210,7 +210,7 @@ std::vector<float*> DataProcessorText::processData(const std::string& data, cons
|
||||
numValues++;
|
||||
}
|
||||
|
||||
calculateFilterValues(selectedOptions);
|
||||
//calculateFilterValues(selectedOptions);
|
||||
|
||||
return dataOptions;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user