Subversion Repository Public Repository

Divide-Framework

This repository has no backups
This repository's network speed is throttled to 100KB/sec

Diff Revisions 593 vs 598 for /trunk/Source Code/Dynamics/Entities/Particles/ParticleEmitter.cpp

Diff revisions: vs.
  @@ -193,6 +193,7 @@
193 193 if (!_enabled) {
194 194 return false;
195 195 }
196 +
196 197 DIVIDE_ASSERT(_particles.get() != nullptr,
197 198 "ParticleEmitter::computeBoundingBox error: BoundingBox "
198 199 "calculation requested without valid particle data "
  @@ -207,6 +208,21 @@
207 208 return SceneNode::computeBoundingBox(sgn);
208 209 }
209 210
211 + bool ParticleEmitter::isInView(const SceneRenderState& sceneRenderState,
212 + const SceneGraphNode& sgn,
213 + Frustum::FrustCollision& collisionType,
214 + const bool distanceCheck) const {
215 + bool visible = false;
216 + if (_enabled && _impostor) {
217 + visible = _impostor->isInView(sceneRenderState, sgn, collisionType, distanceCheck);
218 + }
219 +
220 + collisionType = visible ? Frustum::FrustCollision::FRUSTUM_IN
221 + : Frustum::FrustCollision::FRUSTUM_OUT;
222 +
223 + return visible;
224 + }
225 +
210 226 void ParticleEmitter::onCameraUpdate(SceneGraphNode& sgn, Camera& camera) {
211 227
212 228 vec3<F32> up(camera.getUpDir());