BsRenderableProxy.cpp 390 B

1234567891011121314151617181920
  1. #include "BsRenderableProxy.h"
  2. #include "BsMeshProxy.h"
  3. namespace BansheeEngine
  4. {
  5. RenderableSubProxy::RenderableSubProxy()
  6. :mBoundsDirty(false), id(0), mesh(nullptr)
  7. { }
  8. Bounds RenderableSubProxy::calculateWorldBounds()
  9. {
  10. if (mesh == nullptr)
  11. return Bounds();
  12. Bounds worldBounds = mesh->getBounds();
  13. worldBounds.transformAffine(worldTransform);
  14. return worldBounds;
  15. }
  16. }