SFML community forums

Help => General => Topic started by: idontmakesense on July 19, 2013, 11:08:56 am

Title: How to create a shape with its axis of rotation in the center?
Post by: idontmakesense on July 19, 2013, 11:08:56 am
I've created basic shapes like rectangles, triangles and lines but they all rotate from one end of the object. I want to uniformly rotate it from the center of the object. Intention is to create a car(top down) driving on the screen.
Title: Re: How to create a shape with its axis of rotation in the center?
Post by: Laurent on July 19, 2013, 11:11:08 am
Use the setOrigin function. Read the transformations tutorial carefully so that you fully understand what it implies.
Title: Re: How to create a shape with its axis of rotation in the center?
Post by: idontmakesense on July 19, 2013, 11:16:13 am
Thanks. I did read it, ill try again. Maybe look for more examples.