bug in transformations

Paul Werkowski pw at snoopy.qozzy.com
Wed Dec 23 15:50:27 UTC 2020


Hey thanks!

I'll have a few more bug/features coming along soon.

On 12/23/2020 10:22 AM, Daniel Kochmański wrote:
> Hey Paul,
>
>
> ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
> On Monday, 14 December 2020 21:11, Paul Werkowski <pw at snoopy.qozzy.com> wrote:
>
>> I am working on getting McCLIM working on Lispworks7 on Windows 10. All
>> is going well and I will have a few patches to contribute soon.
>>
>> I do have 32 bit Lispworks Professional here, with CLIM2, that I have
>> been using for quite awhile now so I have my own code to use for testing
>> the port. One fairly simple plotting program put up a frame with no
>> complaints but appeared to show nothing on the screen. I traced the
>> issue to a disagreement between clim2 and McCLIM implementations in
>> transformation composition which caused my expected image to display way
>> out of the clipping region. This bit of code shows the problem...
>>
>> (defun txf()
>>    (let ((scale-x 2.35)
>>          (scale-y 24.7)
>>          (origin-x 38.0)
>>          (origin-y 263.0))
>>      (let* ((st (clim:make-scaling-transformation
>>                 scale-x (- scale-y)))
>>             ;;#<CLIM-INTERNALS::STANDARD-HAIRY-TRANSFORMATION
>>             ;; 2.35 0 0 -24.7 0.0 0.0>
>> (tt (clim:make-translation-transformation origin-x origin-y))
>>             ;;#<CLIM-INTERNALS::STANDARD-TRANSLATION :DX 38.0 :DY 263.0>
>> (ct1 (clim:compose-transformations tt st)) ; correct in
>> clim2 & Mcclim
>>             ;;#<CLIM-INTERNALS::STANDARD-HAIRY-TRANSFORMATION
>>             2.35 0.0 0.0 -24.7 38.0 263.0> <<<<<
>> ;; McCLIM gets this wrong (assuming clim2 is correct).
>>             (ct2 (clim:compose-transformation-with-translation
>>                   (clim:make-scaling-transformation
>>                    scale-x (- scale-y)) origin-x origin-y))
>>             ;;#<CLIM-INTERNALS::STANDARD-HAIRY-TRANSFORMATION
>>             ;;  2.35 0.0 0.0 -24.7 89.299996
>> -6496.1>                            <<<<<
>> )
>>        (values st tt ct1 ct2))))
>>
>> Reading the clim2 spec, I think clim2 implements it correctly.
>>
>> Paul
> thank you for letting us know. You are right, McCLIM got it wrong since 2018.
> I've proposed the fix in https://github.com/McCLIM/McCLIM/pull/1117, I'm going
> to merge it today or tomorrow.
>
> Best regards,
> Daniel
>
>
>
> --
> Daniel Kochmański ;; aka jackdaniel | Przemyśl, Poland
> TurtleWare - Daniel Kochmański      | www.turtleware.eu
>
> "Be the change that you wish to see in the world." - Mahatma Gandhi
>



More information about the mcclim-devel mailing list