|
the trick to add 0.25 may not be necessary in this case,
but the reason why I suggest using it is for field rendering.
In field rendering, the frame number in xsi will be 1.0, 1.5, 2.0, 2.5,
etc. If you round to nearest frame with +0.25,
you'll end up with frame numbers 1, 1, 2, 2. If you use
+0.5, you'll end up with frame numbers 1,2,2,3. In other words +0.25
rounds down each field time to the frame number.
From: owner-xsi(at)Softimage.COM
[mailto:owner-xsi(at)Softimage.COM] On Behalf Of Kim Aldis Posted
At: Thursday, June 07, 2007 1:51 PM Posted To:
xsi Conversation: [SDK]Double to long in c++ ? Subject:
RE: [SDK]Double to long in c++ ?
(LONG)(
1.6 + 0.25) =>
1
(LONG)(1.6
+ 0.5) => 2
The
correct round of 1.6 is 2, so adding 0.25 gives an incorrect round.
Surely?
|