Which is the better way to rotate an object?

I'm a developer on the long way to learn design so please forgive me if I'm not into design jargon ?.

I have to design an interface to rotate a 2D object. The rotation is discrete by fixed step: the object can be rotated by 0°, 45°, 90°, ..., 180° degrees (in this example the step is 45° but it can be parameterised by configuration).

I have few ideas, and I'd like to discuss which could be the best one.

Standard slider:

enter image description here

Standard slider are everywhere, easy to implement, easy to use. There's a slider over the object and by moving it, the user can control the rotation of the object.

Circular arc slider handle

enter image description here

There is the object surrounded by a circular arc slider with an handle that the user can drag to rotate.

I think that the circular shape of the slider can be functional to advise the purpose of the slider (a rotation), but I think that moving by fixed step can be not so intuitive both for the implementation and the usage.

What can be the best one? Any considerations/ideas/advice? Is there some other ways to do it? Maybe simpler ways?