MCPcopy Create free account
hub / github.com/SakuraEngine/SakuraEngine / query

Method query

modules/engine/runtime/src/ecs/query.cpp:582–600  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

580}
581
582void sugoi_storage_t::query(const sugoi_query_t* q, sugoi_view_callback_t callback, void* u)
583{
584 bool mainThread = true;
585 if (scheduler)
586 {
587 mainThread = scheduler->is_main_thread(this);
588 }
589 if (mainThread)
590 {
591 build_queries();
592 }
593 else
594 SKR_ASSERT(queriesBuilt);
595
596 auto filterChunk = [&](sugoi_group_t* group) {
597 query(group, q->filter, q->meta, q->customFilter, q->customFilterUserData, callback, u);
598 };
599 query_groups(q, SUGOI_LAMBDA(filterChunk));
600}
601
602void sugoi_storage_t::destroy(const sugoi_query_t* q)
603{

Callers 4

sugoiS_queryFunction · 0.45
sugoiQ_get_viewsFunction · 0.45
sugoiQ_get_views_groupFunction · 0.45
schedule_ecs_jobMethod · 0.45

Calls 12

match_chunk_changedFunction · 0.85
_mm_set1_epi32Function · 0.85
sugoiV_get_owned_roFunction · 0.85
_mm_load_si128Function · 0.85
_mm_and_si128Function · 0.85
_mm_movemask_epi8Function · 0.85
_mm_cmpeq_epi32Function · 0.85
is_main_threadMethod · 0.80
timestampsMethod · 0.80
CountLeadingZeros64Function · 0.50
matchFunction · 0.50
get_maskMethod · 0.45

Tested by

no test coverage detected