Perfectly working abs pos caching using dirty flags! :D
This commit is contained in:
@@ -56,7 +56,6 @@ struct ComponentWrapper
|
||||
|
||||
void SetAllDirty(const std::string& fieldName, bool dirty = true)
|
||||
{
|
||||
LOG_DEBUG("DIRTY: %s %s", Info.Name.c_str(), fieldName.c_str());
|
||||
for (auto& kv : *DirtyBitField) {
|
||||
SetDirty(kv.first, fieldName);
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
namespace Transform
|
||||
{
|
||||
|
||||
glm::mat4 AbsoluteTransformation(EntityWrapper entity);
|
||||
//glm::mat4 AbsoluteTransformation(EntityWrapper entity);
|
||||
glm::vec3 AbsolutePosition(EntityWrapper entity);
|
||||
glm::vec3 AbsolutePosition(World* world, EntityID entity);
|
||||
glm::vec3 AbsoluteOrientationEuler(EntityWrapper entity);
|
||||
@@ -20,6 +20,11 @@ glm::mat4 ModelMatrix(EntityWrapper entity);
|
||||
glm::mat4 ModelMatrix(EntityID entity, World* world);
|
||||
glm::vec3 TransformPoint(const glm::vec3& point, const glm::mat4& matrix);
|
||||
|
||||
|
||||
extern int RecalculatedPositions;
|
||||
extern int RecalculatedOrientations;
|
||||
extern int RecalculatedScales;
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user