Full FPS camera, better profile info about time distribution, update Todo's README

This commit is contained in:
Krzosa Karol
2022-02-26 11:09:39 +01:00
parent 76a8053443
commit e553eb40fc
4 changed files with 316 additions and 215 deletions

View File

@@ -12,11 +12,11 @@ GLOBAL ProfileScope profile_scopes[ProfileScopeName_Count];
#define PROFILE_BEGIN(name) do { \
ProfileScope *__profile_scope = profile_scopes + ProfileScopeName_##name; \
__profile_scope->samples[__profile_scope->i] = os_time(); \
__profile_scope->samples[__profile_scope->i] = os_time()*1000; \
} while (0)
#define PROFILE_END(name) do { \
ProfileScope *_profile_scope = profile_scopes + ProfileScopeName_##name; \
_profile_scope->samples[_profile_scope->i] = os_time() - _profile_scope->samples[_profile_scope->i]; \
_profile_scope->samples[_profile_scope->i] = os_time()*1000 - _profile_scope->samples[_profile_scope->i]; \
_profile_scope->i = (_profile_scope->i + 1) % 5096; \
}while (0)