Recent

Author Topic: [FPC 3.2.4, Windows] PTC unit broken?  (Read 3835 times)

Roland57

  • Hero Member
  • *****
  • Posts: 609
    • msegui.net
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #30 on: April 25, 2026, 11:29:03 am »
Thank you all for your contribution.

I stop the combat.

Thank you for your efforts Fred. Since the problem seems to be specific to some Windows versions, I suggest that we wait for the next Windows update and see.  ;)
My projects are on Codeberg.

Fred vS

  • Hero Member
  • *****
  • Posts: 3943
    • StrumPract is the musicians best friend
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #31 on: April 25, 2026, 01:03:51 pm »
Thank you all for your contribution.

I stop the combat.

Thank you for your efforts Fred. Since the problem seems to be specific to some Windows versions, I suggest that we wait for the next Windows update and see.  ;)

Hello Roland.

I'm afraid it might be more complicated.
LeP and I have the same version of Windows 11, but everything seems to work on his system, even using fpc 3.2.2.
I did test with fpc 3.2.2/4 32 and 64 bit, same bad result, idem with trunk fpc 3.3.1 32/64 bit.
« Last Edit: April 25, 2026, 02:10:35 pm by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

Fred vS

  • Hero Member
  • *****
  • Posts: 3943
    • StrumPract is the musicians best friend
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #32 on: April 25, 2026, 02:27:53 pm »
The flower demo tests correct for 64 bit. I won't test 32 bit on Windows. All other demo's work too, as already stated.
Win11 is 25H2 26200 8246 So current release + all patches.
The suggestion that the issue is caused by win11 is bogus, at least for 64 bit.

Hello Thaddy.
Thanks to give your flower.exe.
Sadly on my Win11 25H2 26200 8246 I get that result:

Code: Pascal  [Select][+][-]
  1. C:\Users\TESTER\Downloads\flower.exe
  2. An unhandled exception occurred at $0000000100009107:
  3. EAccessViolation: Access violation
  4.   $0000000100009107
  5.   $000000010001F8AB
  6.   $000000010002394F
  7.   $0000000100021D8C
  8.   $000000010002101A
  9.   $0000000100009E97
  10.   $00000001000090AD
  11.   $0000000100029CCB
  12.   $0000000100011ABE
  13.   $00007FFB944662BF
  14.   $00007FFB9430E603
  15.   $000000010001163A
  16.   $00007FFB9446623F
  17.   $00007FFB94312397
  18.   $00007FFB94465B7E
  19.   $0000000100009107
  20.   $000000010001F8AB
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

LeP

  • Sr. Member
  • ****
  • Posts: 330
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #33 on: April 25, 2026, 03:45:04 pm »
I think, like I told, that should be the surface that the software choose to "draw" the issue.

If someone can switch through all surfaces supportde, this can help to find the issue.
« Last Edit: April 25, 2026, 06:31:16 pm by LeP »
Un Sistema per domarli, un IDE per trovarli, un codice per ghermirli e nel framework incatenarli.
An operating system to tame them, an IDE to find them, a code to catch them and in the framework chain them.

Thaddy

  • Hero Member
  • *****
  • Posts: 19267
  • Glad to be alive.
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #34 on: April 25, 2026, 06:10:15 pm »
Fred, it works on ALL machines in my household, all applicable of mine, my wife's, my daughter's....
I am out of wit.

These machines are all quite different: Intels, AMD's, but all with the same Windows 11 64 bit version.

Tested out of curiosity a total of 7 machines. 3 of them have no particular development software, quite clean machines. All passed.

Again, I am out of wit. Try other machines, like I did.

Of course, defender should warn, but ignore.
« Last Edit: April 25, 2026, 06:24:31 pm by Thaddy »
objects are fine constructs. You can even initialize them with constructors.

Fred vS

  • Hero Member
  • *****
  • Posts: 3943
    • StrumPract is the musicians best friend
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #35 on: April 25, 2026, 06:35:33 pm »
Fred, it works on ALL machines in my household, all applicable of mine, my wife's, my daughter's....
I am out of wit.

These machines are all quite different: Intels, AMD's, but all with the same Windows 11 64 bit version.

Tested out of curiosity a total of 7 machines. 3 of them have no particular development software, quite clean machines. All passed.

Again, I am out of wit. Try other machines, like I did.

Of course, defender should warn, but ignore.

Dear Thaddy,

I believe you, just as I believe LeP's result.

But I also believe Roland and my machine.

Unfortunately, I don't have any other Windows 11 machines besides my own to test with.
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

LeP

  • Sr. Member
  • ****
  • Posts: 330
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #36 on: April 25, 2026, 06:42:22 pm »
In my VM Windows machine flowers doesn't work:

Code: Pascal  [Select][+][-]
  1. C:\Users\Operatore\Desktop>flower.exe
  2. An unhandled exception occurred at $0000000100047FB8:
  3. EAccessViolation: Access violation
  4.   $0000000100047FB8
  5.   $000000010000990B
  6.   $00000001000140E7
  7.   $000000010001FD32
  8.   $00000001000268B5
  9.   $0000000100025B25
  10.   $0000000100024000
  11.   $000000010002C357
  12.   $0000000100002133  $main,  line 139 of flower.pp
  13.   $0000000100002726
  14.   $0000000100010AC0
  15.   $0000000100001B10
  16.   $00007FFF9D7E7374
  17.   $00007FFF9F7FCC91

And now I'm pretty sure that is about the rendering surface the issue.
« Last Edit: April 25, 2026, 06:44:32 pm by LeP »
Un Sistema per domarli, un IDE per trovarli, un codice per ghermirli e nel framework incatenarli.
An operating system to tame them, an IDE to find them, a code to catch them and in the framework chain them.

LeP

  • Sr. Member
  • ****
  • Posts: 330
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #37 on: April 25, 2026, 11:00:00 pm »
The error is in the call indicated in the previous post (line 139):

Code: Pascal  [Select][+][-]
  1. console.open('Flower demo', 320, 200, format);

This means that something in the format, the resolution or other regards surface is not available in the system.

See the attached image.
Un Sistema per domarli, un IDE per trovarli, un codice per ghermirli e nel framework incatenarli.
An operating system to tame them, an IDE to find them, a code to catch them and in the framework chain them.

Thaddy

  • Hero Member
  • *****
  • Posts: 19267
  • Glad to be alive.
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #38 on: April 26, 2026, 07:34:38 am »
I can't test on a Windows VM but that seems a likely scenario.
I will test in Linux VM's, both WSL2 (hyperV'd) and VirtualBox (which has Wine on one machine).
Since I can't test if the console window size makes any difference- it works here - , can you test that?
[edit:]
Set the surface area to 1920x1024
Set all others to 640 X 480

Then report back.
« Last Edit: April 26, 2026, 07:56:49 am by Thaddy »
objects are fine constructs. You can even initialize them with constructors.

LeP

  • Sr. Member
  • ****
  • Posts: 330
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #39 on: April 26, 2026, 10:49:15 am »
Now I don't try in the WM, but I try different resolutions in my real Windows (where the original flowers worked) .... and the scenario are various.

Some resolutions work, but the drawing effects are really different form the orginal one (positions, colors, etc ...), other totally lock the screen (not keyb or mouse acts, except "special" keys) with no drawing or effects. May be an exception was thrown, but impossible to view.

So, I think that the PTC is very bad developed, with no exceptions catch and and incorrect handling of function results (API).

Like I told, I have no competence on PTC (I really don't know what is it) so no meaning from me to go on.

N.B.: in the VM the tests are more difficult 'cause when the program start you always lost mouse and keyb controls, so really difficult to go on.
Un Sistema per domarli, un IDE per trovarli, un codice per ghermirli e nel framework incatenarli.
An operating system to tame them, an IDE to find them, a code to catch them and in the framework chain them.

Thaddy

  • Hero Member
  • *****
  • Posts: 19267
  • Glad to be alive.
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #40 on: April 27, 2026, 07:23:12 am »
If windows is running in virtualbox (not hyperv'd) without the extensions installed, flowers.exe crashes. If running on wsl2 (yes, I installed windows on windows) with paravirtualization (hyperv'd) enabled it does not crash. What was what I more or less expected.
Discovered by accident because I forgot to install the extensions in virtualbox.

But the original question does not mention virtualization?
If that is the case I have been wasting my time.
« Last Edit: April 27, 2026, 07:28:27 am by Thaddy »
objects are fine constructs. You can even initialize them with constructors.

LeP

  • Sr. Member
  • ****
  • Posts: 330
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #41 on: April 27, 2026, 03:56:05 pm »
If windows is running in virtualbox (not hyperv'd) without the extensions installed, flowers.exe crashes. If running on wsl2 (yes, I installed windows on windows) with paravirtualization (hyperv'd) enabled it does not crash. What was what I more or less expected.
Discovered by accident because I forgot to install the extensions in virtualbox.
Of course, my VM has the extension and works with graphical engines like DDRAW, D3D, and OpenGL. Altought may be not compatible (like every VM) with some settings.
Un Sistema per domarli, un IDE per trovarli, un codice per ghermirli e nel framework incatenarli.
An operating system to tame them, an IDE to find them, a code to catch them and in the framework chain them.

LeP

  • Sr. Member
  • ****
  • Posts: 330
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #42 on: April 27, 2026, 04:03:26 pm »
But the original question does not mention virtualization?
If that is the case I have been wasting my time.
I don't know about OP, but I have tried in a REAL MACHINE, and PTC doesn't work always.
The worst thing is NOT "not working", it's that when it doesn't work, very bad things happen (it's not a good thing to hang a station or crash).
Un Sistema per domarli, un IDE per trovarli, un codice per ghermirli e nel framework incatenarli.
An operating system to tame them, an IDE to find them, a code to catch them and in the framework chain them.

Thaddy

  • Hero Member
  • *****
  • Posts: 19267
  • Glad to be alive.
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #43 on: April 27, 2026, 04:47:29 pm »
Not reproducable. That is frustrating, but I can't help any further.
You can ask Nicolai Nicolov on the dev mailinglist. He wrote it and is a core developer.
« Last Edit: April 27, 2026, 04:49:16 pm by Thaddy »
objects are fine constructs. You can even initialize them with constructors.

Fred vS

  • Hero Member
  • *****
  • Posts: 3943
    • StrumPract is the musicians best friend
Re: [FPC 3.2.4, Windows] PTC unit broken?
« Reply #44 on: April 27, 2026, 04:51:03 pm »
Maybe forget PTC and switch to https://github.com/GuvaCode/ray4laz  ;)
« Last Edit: April 27, 2026, 04:54:21 pm by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

 

TinyPortal © 2005-2018