载入中...
搜索中...
未找到
BoidsCommon.h 文件参考
#include "gpuagents/AgentState.h"
#include "gpuagents/EnvironmentSnapshot.h"
#include <glm/glm.hpp>
#include <algorithm>
#include <cmath>
#include <span>

浏览源代码.

类

struct  eve::gpuagents::detail::NeighborAccum
 NeighborAccum public API. 更多...
 

命名空间

namespace  eve
 Build metadata (engine git commit, build time, third-party version).
 
namespace  eve::gpuagents
 
namespace  eve::gpuagents::detail
 

函数

float eve::gpuagents::detail::compactWeight (float dist, float radius)
 Compact-support radial weight w(q)=(1-q)^2 for q in [0,1).
 
bool eve::gpuagents::detail::isInFieldOfView (const glm::vec3 &forward, const glm::vec3 &toNeighbor, float fovDegrees)
 True when neighbor direction is inside a forward cone (degrees).
 
NeighborAccum eve::gpuagents::detail::gatherNeighbors (std::span< const AgentState > agents, int selfIndex, const glm::vec3 &forward, float sepR, float cohR, float aliR, float fovDeg, int maxSamples)
 Gather neighborhood forces with compact weights and FOV / sample caps.
 
glm::vec3 eve::gpuagents::detail::markerForce (const glm::vec3 &pos, const std::vector< EnvironmentMarker > &markers, bool attract)
 Marker force.
 
void eve::gpuagents::detail::integrateBoid (AgentState &out, const AgentState &in, glm::vec3 accel, float dt, float maxAccel, float maxSpeed, float maxHTurn, float maxVTurn)
 Clamp acceleration then integrate semi-implicit Euler with turn-rate limits.