Demo update and start counting tests times
-Fixed performance issue with multithreading and rendering -start making better shaders (by using many macros) -speed up rendeing when maximum objects count was reached -remove map rendering form Snake demo, and render entities by themself -start adding depth and color rendering parameters -added properly names to jobs (for debugging purpses) -starts adding multithreaded rendering -added some math to vectors -changes execute() to willExecute(). Probably should have different name.
This commit is contained in:
parent
46aba822d0
commit
4bd5a37b5d
13 changed files with 429 additions and 198 deletions
|
|
@ -63,6 +63,7 @@ struct ECSJobUpdater
|
|||
JobData[1024] jobs;
|
||||
JobCaller[1024] callers;
|
||||
uint count = 0;
|
||||
string name;
|
||||
|
||||
void dependantOn(Group* dependency)
|
||||
{
|
||||
|
|
@ -89,7 +90,7 @@ struct ECSJobUpdater
|
|||
void add(JobCaller caller)
|
||||
{
|
||||
callers[count] = caller;
|
||||
jobs[count] = JobData(&callers[count].callJob,"hmm");
|
||||
jobs[count] = JobData(&callers[count].callJob,name);
|
||||
count++;
|
||||
}
|
||||
}
|
||||
|
|
@ -216,6 +217,8 @@ struct ECSJobUpdater
|
|||
return;
|
||||
}
|
||||
|
||||
jobs[group.id].name = cast(string)group.caller.system.name;
|
||||
|
||||
foreach(ref job;group.jobs)
|
||||
{
|
||||
uint index = 0;
|
||||
|
|
@ -233,7 +236,7 @@ struct ECSJobUpdater
|
|||
|
||||
foreach(dep;group.dependencies)
|
||||
{
|
||||
if(jobs[dep.id].count && dep.caller.system.execute && dep.caller.system.enabled)jobs[group.id].dependantOn(&jobs[dep.id]);
|
||||
if(jobs[dep.id].count && dep.caller.system.willExecute && dep.caller.system.enabled)jobs[group.id].dependantOn(&jobs[dep.id]);
|
||||
else deps--;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue