fish #9
@ -272,8 +272,12 @@ void renderScene()
|
||||
glm::mat4 submarineModelMatrix = glm::translate(cameraPos + cameraDir) * glm::mat4_cast(glm::inverse(rotation)) * submarineInitialTransformation;
|
||||
|
||||
glm::mat4 fishInitialTransformation = glm::translate(glm::vec3(0, 0, 0)) * glm::rotate(glm::radians(180.0f), glm::vec3(0, 1, 0)) * glm::scale(glm::vec3(0.25f));
|
||||
|
||||
for (int i = 0; i < 5; i++) {
|
||||
if (time > -10) {
|
||||
drawObjectTexture(fishContext, animationMatrix(time + 15), textureFish);
|
||||
time -= 3;
|
||||
}
|
||||
}
|
||||
drawObjectTexture(submarineContext, submarineModelMatrix, textureSubmarine);
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user