Hello there.
I have a mesh batcher here and it’s working wonders, however, whenever I switch to release build the UpdateBatches
function isn’t called. I’ve tried everything, disabled all optimizations both in Urho (static link) and my code, it simply refuses to work . I made a simple test class and the problem is reproducible, here you go:
//NOTE: run "context_->RegisterFactory<TestDrawable>();" somewhere
class TestDrawable : public Drawable
{
public:
URHO3D_OBJECT(TestDrawable, Drawable);
explicit TestDrawable(Context* context) : Drawable(context, DRAWABLE_ANY) {}
virtual void UpdateBatches(const FrameInfo& frame) override
{
printf("CALLED!\n");
}
virtual void OnWorldBoundingBoxUpdate() override
{
boundingBox_ = BoundingBox(-10000, 10000);
}
};
Any ideas what could be causing that problem? Thanks in advance.