'Python: get_time Time interval

I'm trying to make a short loop animation that rotates the object between 0~90 degrees iteratively.

T = glfw.get_time()-animStartTime;

#v is the rotation vector 
r = T * v

i.e.) 0->10->20->...->90->80->70->...->0->10...so on

I need to set time interval as (0 <= T <= 1)to rotate 0~90 degree; however, since I used glfw.time_get()for time elasping, it rotates the object 360 degree.

Is there any way to set interval to the glfw.time_get() ??



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source