BsCameraProxy.cpp 686 B

12345678910111213141516171819
  1. //__________________________ Banshee Project - A modern game development toolkit _________________________________//
  2. //_____________________________________ www.banshee-project.com __________________________________________________//
  3. //________________________ Copyright (c) 2014 Marko Pintera. All rights reserved. ________________________________//
  4. #include "BsCameraProxy.h"
  5. namespace BansheeEngine
  6. {
  7. void CameraProxy::calcWorldFrustum()
  8. {
  9. const Vector<Plane>& frustumPlanes = frustum.getPlanes();
  10. Vector<Plane> worldPlanes;
  11. for (auto& plane : frustumPlanes)
  12. {
  13. worldPlanes.push_back(worldMatrix.multiply3x4(plane));
  14. }
  15. worldFrustum = ConvexVolume(worldPlanes);
  16. }
  17. }