mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
don't clamp t value in set_t()
This commit is contained in:
parent
9581603cd8
commit
bfc61341a1
@ -58,7 +58,11 @@ class Interval(DirectObject):
|
||||
self.getState() == CInterval.SFinal)
|
||||
|
||||
def setT(self, t):
|
||||
t = min(max(t, 0.0), self.getDuration())
|
||||
# There doesn't seem to be any reason to clamp this, and it
|
||||
# breaks looping intervals. The interval code should properly
|
||||
# handle t values outside the proper range.
|
||||
#t = min(max(t, 0.0), self.getDuration())
|
||||
|
||||
state = self.getState()
|
||||
if state == CInterval.SInitial:
|
||||
self.privInitialize(t)
|
||||
|
@ -66,7 +66,11 @@ CInterval(const string &name, double duration, bool open_ended) :
|
||||
////////////////////////////////////////////////////////////////////
|
||||
void CInterval::
|
||||
set_t(double t) {
|
||||
t = min(max(t, 0.0), get_duration());
|
||||
// There doesn't seem to be any reason to clamp this, and it
|
||||
// breaks looping intervals. The interval code should properly
|
||||
// handle t values outside the proper range.
|
||||
//t = min(max(t, 0.0), get_duration());
|
||||
|
||||
switch (get_state()) {
|
||||
case S_initial:
|
||||
priv_initialize(t);
|
||||
|
Loading…
x
Reference in New Issue
Block a user