MCPcopy Create free account
hub / github.com/OGSR/OGSR-Engine / refresh_prefetch

Method refresh_prefetch

ogsr_engine/Layers/xrRender/ModelPool.cpp:354–374  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

352}
353
354void CModelPool::refresh_prefetch(const char* low_name, const bool is_hud_visual)
355{
356 if (now_prefetch2)
357 return;
358
359 std::string s(low_name);
360 if (m_prefetched.find(s) != m_prefetched.end())
361 return;
362
363 if (now_prefetch1)
364 {
365 m_prefetched.emplace(s, true);
366 }
367 else if (vis_prefetch_ini)
368 {
369 shared_str fname;
370 bool is_global = !!FS.exist(fsgame::game_meshes, *fname.sprintf("%s.ogf", low_name));
371 if (is_global)
372 vis_prefetch_ini->w_fvector2("prefetch", low_name, Fvector2{2.f, is_hud_visual ? 2.f : 1.f});
373 }
374}
375
376dxRender_Visual* CModelPool::CreateChild(LPCSTR name, IReader* data)
377{

Callers

nothing calls this directly

Calls 5

emplaceMethod · 0.80
existMethod · 0.80
w_fvector2Method · 0.80
findMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected