[BUG] possible MatrixTransform2x3 bug?

Ned Konz ned at bike-nomad.com
Wed Aug 20 19:15:09 UTC 2003


This one's got me baffled. I've got a Matrix2x3Plugin internally 
built, using the sources off SF and generated from a recent 3.6 
image.

In a Workspace:

m1 _ MatrixTransform2x3 withOffset: 100.0 at 100.0.

m1 "print it =>" MatrixTransform2x3(
1.0	0.0	100.0
0.0	1.0	100.0
)

Smalltalk listLoadedModules  "print it =>" #('LargeIntegers v1.2 3 
August 2003 (i)' 'B2DPlugin 3 August 2003 (i)' 'Matrix2x3Plugin 3 
August 2003 (i)' 'FloatArrayPlugin 3 August 2003 (i)' 'BitBltPlugin 3 
August 2003 (i)' 'UnixOSProcessPlugin 13 August 2003 (e)' 
'SecurityPlugin 3 August 2003 (i)' 'FilePlugin 3 August 2003 (i)' 
'MiscPrimitivePlugin 3 August 2003 (i)')

m1 localPointToGlobal: 0 at 0 "print it =>" 100 at 100
m1 globalPointToLocal: 100 at 100 "print it =>" 0 at 0

So far so good. But:

m1 globalPointToLocal: 0 at 0 "print it =>" -99 at -99
m1 globalPointToLocal: (0 at 0) asFloatPoint "print it =>" -99 at -99

Hmm. The code falls back to "^(self invertPoint: aPoint) rounded" if 
the plugin is not present. And that works OK:

m1 invertPoint: 0 at 0 "print it =>" -100.0 at -100.0

(m1 invertPoint: 0 at 0) rounded "print it =>"  -100 at -100

I've looked in the sources and in the C source, and I have verified 
that the return value is indeed getting rounded.

Am I missing something here? This behavior is the same going back to a 
3.2 VM.

-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE



More information about the Squeak-dev mailing list