| 201 | } |
| 202 | |
| 203 | void PlanarShadowEffect::GatherVisuals( |
| 204 | std::shared_ptr<ProgramFactory> const& factory, |
| 205 | std::shared_ptr<Spatial> const& spatial) |
| 206 | { |
| 207 | auto visual = std::dynamic_pointer_cast<Visual>(spatial); |
| 208 | if (visual) |
| 209 | { |
| 210 | Vector4<float> black{ 0.0f, 0.0f, 0.0f, 1.0f }; |
| 211 | auto effect = std::make_shared<ConstantColorEffect>(factory, black); |
| 212 | mCasterVisuals.push_back(visual); |
| 213 | mCasterEffects.push_back(effect); |
| 214 | return; |
| 215 | } |
| 216 | |
| 217 | auto node = std::dynamic_pointer_cast<Node>(spatial); |
| 218 | if (node) |
| 219 | { |
| 220 | for (int32_t i = 0; i < node->GetNumChildren(); ++i) |
| 221 | { |
| 222 | auto const& child = node->GetChild(i); |
| 223 | if (child) |
| 224 | { |
| 225 | GatherVisuals(factory, child); |
| 226 | } |
| 227 | } |
| 228 | } |
| 229 | } |
| 230 | |
| 231 | void PlanarShadowEffect::GetModelSpaceTriangles() |
| 232 | { |
nothing calls this directly
no test coverage detected