mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 18:23:54 +02:00
Warning fixes.
This commit is contained in:
parent
e6b0dc592b
commit
18cb15ee7d
3 changed files with 13 additions and 6 deletions
|
@ -2319,9 +2319,16 @@ void StaticModelRenderer::renderUnclipped(float alpha, Mode mode) {
|
|||
_model->render(alpha);
|
||||
}
|
||||
|
||||
bool StaticModelRenderer::findRayIntersection(RayIntersectionInfo& intersection,
|
||||
const glm::vec3& clipMinimum, float clipSize) const {
|
||||
return _model->findRayIntersection(intersection);
|
||||
bool StaticModelRenderer::findRayIntersection(const glm::vec3& origin, const glm::vec3& direction,
|
||||
const glm::vec3& clipMinimum, float clipSize, float& distance) const {
|
||||
RayIntersectionInfo info;
|
||||
info._rayStart = origin;
|
||||
info._rayDirection = direction;
|
||||
if (!_model->findRayIntersection(info)) {
|
||||
return false;
|
||||
}
|
||||
distance = info._hitDistance;
|
||||
return true;
|
||||
}
|
||||
|
||||
void StaticModelRenderer::applyTranslation(const glm::vec3& translation) {
|
||||
|
|
|
@ -370,8 +370,8 @@ public:
|
|||
|
||||
virtual void init(Spanner* spanner);
|
||||
virtual void simulate(float deltaTime);
|
||||
virtual bool findRayIntersection(RayIntersectionInfo& intersection,
|
||||
const glm::vec3& clipMinimum, float clipSize) const;
|
||||
virtual bool findRayIntersection(const glm::vec3& origin, const glm::vec3& direction,
|
||||
const glm::vec3& clipMinimum, float clipSize, float& distance) const;
|
||||
|
||||
protected:
|
||||
|
||||
|
|
|
@ -505,7 +505,7 @@ void Avatar::renderBody(RenderMode renderMode, bool postLighting, float glowLeve
|
|||
{
|
||||
Glower glower(glowLevel);
|
||||
|
||||
if (_shouldRenderBillboard || !(_skeletonModel.isRenderable() && getHead()->getFaceModel().isRenderable()) &&
|
||||
if ((_shouldRenderBillboard || !(_skeletonModel.isRenderable() && getHead()->getFaceModel().isRenderable())) &&
|
||||
(postLighting || renderMode == SHADOW_RENDER_MODE)) {
|
||||
// render the billboard until both models are loaded
|
||||
renderBillboard();
|
||||
|
|
Loading…
Reference in a new issue