PWM to Sinewave with Amplitude

Question for the electronics gurus. I’m looking for a circuit that can generate Sine Waves given the frequency of a PWM signal (simple enough) and modulate the amplitude based on the duty cycle of the PWM signal.

(Yes it’s for a stepper motor control experiment. No I don’t want to use an existing stepper driver.)