SFML community forums

Help => Graphics => Topic started by: Spark Dev on February 17, 2021, 05:16:30 am

Title: Camera Shake
Post by: Spark Dev on February 17, 2021, 05:16:30 am
Hey Programmers!, I'm working on a game using SFML & C++. This is my first experience with SFML. I wonder how could I add camera shake effect to my application. Anyone got any idea about that?
Title: Re: Camera Shake
Post by: fallahn on February 17, 2021, 10:52:10 am
Take a look at views: https://www.sfml-dev.org/tutorials/2.5/graphics-view.php these are basically your in-game camera. Adding some movement to the position will create something akin to camera shake.
Title: Re: Camera Shake
Post by: Spark Dev on February 21, 2021, 03:06:19 am
Thanks for your answer. It helps me a lot.