mirror of
https://github.com/dgirardeau/q3DMASC.git
synced 2026-08-29 08:34:48 +08:00
WIP
This commit is contained in:
@@ -133,3 +133,24 @@ bool Feature::PerformMathOp(const IScalarFieldWrapper& sf1, const IScalarFieldWr
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Feature::ExtractSources(const Set& features, Source::Set& sources)
|
||||
{
|
||||
sources.clear();
|
||||
try
|
||||
{
|
||||
sources.reserve(features.size());
|
||||
}
|
||||
catch (const std::bad_alloc&)
|
||||
{
|
||||
ccLog::Warning("Not enough memory");
|
||||
return false;
|
||||
}
|
||||
|
||||
for (Feature::Shared f : features)
|
||||
{
|
||||
sources.push_back(f->source);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user