MCPcopy Create free account
hub / github.com/christophhart/HISE / reloadAllSamples

Method reloadAllSamples

hi_scripting/scripting/api/ScriptingApi.cpp:1792–1816  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1790}
1791
1792void ScriptingApi::Engine::reloadAllSamples()
1793{
1794 auto f = [](Processor* p)
1795 {
1796 Processor::Iterator<ModulatorSampler> iter(p);
1797
1798 while (auto s = iter.getNextProcessor())
1799 s->reloadSampleMap();
1800
1801 return SafeFunctionCall::OK;
1802 };
1803
1804 auto mc = getScriptProcessor()->getMainController_();
1805
1806#if USE_BACKEND
1807 mc->getSampleManager().getProjectHandler().checkSubDirectories();
1808#else
1809 mc->getSampleManager().getProjectHandler().checkAllSampleReferences();
1810#endif
1811
1812
1813
1814
1815 mc->getKillStateHandler().killVoicesAndCall(mc->getMainSynthChain(), f, MainController::KillStateHandler::TargetThread::SampleLoadingThread);
1816}
1817
1818double ScriptingApi::Engine::getPreloadProgress()
1819{

Callers

nothing calls this directly

Calls 7

getNextProcessorMethod · 0.80
reloadSampleMapMethod · 0.80
getMainController_Method · 0.80
checkSubDirectoriesMethod · 0.80
killVoicesAndCallMethod · 0.45
getMainSynthChainMethod · 0.45

Tested by

no test coverage detected