diff --git a/as2/README.md b/as2/README.md index d0abf19..9c4f2f3 100644 --- a/as2/README.md +++ b/as2/README.md @@ -36,6 +36,11 @@ run the executable with the following command: The models spin at a rate of 10 degrees per second. +# Controls + +There are no specific controls for this program. The program will automatically +display the models with their transformations and bounding boxes. + # Readme Question The `DrawBoundedModel` function takes a model and transformer lambda function diff --git a/as2/as2.cpp b/as2/as2.cpp index 8b36dd4..1d94841 100644 --- a/as2/as2.cpp +++ b/as2/as2.cpp @@ -6,8 +6,6 @@ #include #include -static bool scaleModel = false; - void DrawBoundedModel(raylib::Model &model, auto transformer) { // store the original transform to apply a different transform to the // model without affecting the next time we draw @@ -17,12 +15,6 @@ void DrawBoundedModel(raylib::Model &model, auto transformer) { // gives us raylib::Matrix transform = transformer(model.GetTransform()); - // default scale doesn't render correctly, so scale the model by 10 if the - // spacebar is pressed - if (scaleModel) { - transform = transform.Scale(10); - } - // apply the transform that we got from the transformer to the model model.SetTransform(transform); @@ -62,10 +54,6 @@ int main() { window.ClearBackground(raylib::Color::Gray()); camera.BeginMode(); - if (raylib::Keyboard::IsKeyPressed(KEY_SPACE)) { - scaleModel = !scaleModel; - } - // in addition to the required transforms, the models will rotate 10 // degrees per second (extra credit), and the penguin is scaled by 30 // eagle scaled by 10