History

more render util cleanup

ZappoMan committed 11 years ago

Commit 4ac673f1 parent e9ea6b216 files · +38 −34Browse files

Showing the changes to interface/src/avatar/SkeletonModel.cpp (1 of 16 files). Show all

Unified · Split

interface/src/avatar/SkeletonModel.cpp+7−7
@@ -561,9 +561,9 @@ void SkeletonModel::renderRagdoll() { · 560 unmodified lines
561 glTranslatef(position.x, position.y, position.z);561 glTranslatef(position.x, position.y, position.z);
562 // draw each point as a yellow hexagon with black border562 // draw each point as a yellow hexagon with black border
563 glColor4f(0.0f, 0.0f, 0.0f, alpha);563 glColor4f(0.0f, 0.0f, 0.0f, alpha);
564 Application::getInstance()->getGeometryCache()->renderSphere(radius2, BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);564 GeometryCache::getInstance()->renderSphere(radius2, BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
565 glColor4f(1.0f, 1.0f, 0.0f, alpha);565 glColor4f(1.0f, 1.0f, 0.0f, alpha);
566 Application::getInstance()->getGeometryCache()->renderSphere(radius1, BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);566 GeometryCache::getInstance()->renderSphere(radius1, BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
567 glPopMatrix();567 glPopMatrix();
568 }568 }
569 glPopMatrix();569 glPopMatrix();
@@ -913,7 +913,7 @@ void SkeletonModel::renderBoundingCollisionShapes(float alpha) { · 343 unmodified lines
913 endPoint = endPoint - _translation;913 endPoint = endPoint - _translation;
914 glTranslatef(endPoint.x, endPoint.y, endPoint.z);914 glTranslatef(endPoint.x, endPoint.y, endPoint.z);
915 glColor4f(0.6f, 0.6f, 0.8f, alpha);915 glColor4f(0.6f, 0.6f, 0.8f, alpha);
916 Application::getInstance()->getGeometryCache()->renderSphere(_boundingShape.getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);916 GeometryCache::getInstance()->renderSphere(_boundingShape.getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
917 917
918 // draw a yellow sphere at the capsule startpoint918 // draw a yellow sphere at the capsule startpoint
919 glm::vec3 startPoint;919 glm::vec3 startPoint;
@@ -922,7 +922,7 @@ void SkeletonModel::renderBoundingCollisionShapes(float alpha) { · 2 unmodified lines
922 glm::vec3 axis = endPoint - startPoint;922 glm::vec3 axis = endPoint - startPoint;
923 glTranslatef(-axis.x, -axis.y, -axis.z);923 glTranslatef(-axis.x, -axis.y, -axis.z);
924 glColor4f(0.8f, 0.8f, 0.6f, alpha);924 glColor4f(0.8f, 0.8f, 0.6f, alpha);
925 Application::getInstance()->getGeometryCache()->renderSphere(_boundingShape.getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);925 GeometryCache::getInstance()->renderSphere(_boundingShape.getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
926 926
927 // draw a green cylinder between the two points927 // draw a green cylinder between the two points
928 glm::vec3 origin(0.0f);928 glm::vec3 origin(0.0f);
@@ -955,7 +955,7 @@ void SkeletonModel::renderJointCollisionShapes(float alpha) { · 26 unmodified lines
955 glTranslatef(position.x, position.y, position.z);955 glTranslatef(position.x, position.y, position.z);
956 // draw a grey sphere at shape position956 // draw a grey sphere at shape position
957 glColor4f(0.75f, 0.75f, 0.75f, alpha);957 glColor4f(0.75f, 0.75f, 0.75f, alpha);
958 Application::getInstance()->getGeometryCache()->renderSphere(shape->getBoundingRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);958 GeometryCache::getInstance()->renderSphere(shape->getBoundingRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
959 } else if (shape->getType() == CAPSULE_SHAPE) {959 } else if (shape->getType() == CAPSULE_SHAPE) {
960 CapsuleShape* capsule = static_cast<CapsuleShape*>(shape);960 CapsuleShape* capsule = static_cast<CapsuleShape*>(shape);
961 961
@@ -965,7 +965,7 @@ void SkeletonModel::renderJointCollisionShapes(float alpha) { · 3 unmodified lines
965 endPoint = endPoint - simulationTranslation;965 endPoint = endPoint - simulationTranslation;
966 glTranslatef(endPoint.x, endPoint.y, endPoint.z); 966 glTranslatef(endPoint.x, endPoint.y, endPoint.z);
967 glColor4f(0.6f, 0.6f, 0.8f, alpha); 967 glColor4f(0.6f, 0.6f, 0.8f, alpha);
968 Application::getInstance()->getGeometryCache()->renderSphere(capsule->getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS); 968 GeometryCache::getInstance()->renderSphere(capsule->getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
969 969
970 // draw a yellow sphere at the capsule startpoint970 // draw a yellow sphere at the capsule startpoint
971 glm::vec3 startPoint;971 glm::vec3 startPoint;
@@ -974,7 +974,7 @@ void SkeletonModel::renderJointCollisionShapes(float alpha) { · 2 unmodified lines
974 glm::vec3 axis = endPoint - startPoint;974 glm::vec3 axis = endPoint - startPoint;
975 glTranslatef(-axis.x, -axis.y, -axis.z);975 glTranslatef(-axis.x, -axis.y, -axis.z);
976 glColor4f(0.8f, 0.8f, 0.6f, alpha); 976 glColor4f(0.8f, 0.8f, 0.6f, alpha);
977 Application::getInstance()->getGeometryCache()->renderSphere(capsule->getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS); 977 GeometryCache::getInstance()->renderSphere(capsule->getRadius(), BALL_SUBDIVISIONS, BALL_SUBDIVISIONS);
978 978
979 // draw a green cylinder between the two points979 // draw a green cylinder between the two points
980 glm::vec3 origin(0.0f);980 glm::vec3 origin(0.0f);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t