Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using PinballY together with VPinballX.starter makes it fail screen capture #8

Closed
JockeJarre opened this issue Dec 5, 2023 · 10 comments · Fixed by #10
Closed

Using PinballY together with VPinballX.starter makes it fail screen capture #8

JockeJarre opened this issue Dec 5, 2023 · 10 comments · Fixed by #10
Labels
bug Something isn't working enhancement New feature or request

Comments

@JockeJarre
Copy link
Owner

I have created the same story on PinballY's side. I hope Michael might know what the problem is.

The link is here:
mjrgh/PinballY#227

@JockeJarre JockeJarre added bug Something isn't working enhancement New feature or request labels Dec 5, 2023
@Karl030167
Copy link

Karl030167 commented Dec 7, 2023

maybe the issue is because the "starter.exe" is the "main task" and the real vpinball_xx.exe is a "child task" ?
Even if the starter.exe is renamed to vpinballx.exe and was started, in taskmanager then there is "vpinballx.starter" as a task.
And of course additionally the "real" Visual Pinball exe as a task.
Only when the visual pinball program will be closed (by menu-file-exit or long press esc) the two tasks are closed, too.

@JockeJarre
Copy link
Owner Author

The reason is because PinballY is waiting for our "VPinballX" replacement to idle in it's main gui loop. Windows has an API for this: "WaitForInputIdle", though since VPinballX.starter does not have any GUI nor GUI loop, PinballY calling WaitForInputIdle on the process, returns directly. One might have to add some dummy GUI to VPinballX.starter, to make it react on WaitForInputIdle?

@Karl030167
Copy link

Thank you for still looking at this behavior - at least a first step that you identified the reason

@JockeJarre
Copy link
Owner Author

Thank you for still looking at this behavior - at least a first step that you identified the reason

Do you mind testing a new build coming up in the actions, I want to know if it helps for PinballY?
I now also do the WaitForInputIdle() on VPX and hope it will tell PinballY to also wait... fingers crossed...

@Karl030167
Copy link

Hi, downloaded and tested 1.5.74
with plain use of the starter (renamed to vpinballx.exe) all is ok;
doubleclick of .vpx starts the right .exe as it is set in .starter.ini

but when used in PinballY, now sometimes the table don't close at game exit.
only when i switch with Alt-Tab to the table-process again, it get closed.
Oddly this happens not always; tried the same table few times again and again - sometimes PinballY close the table correctly, next time the table (vpx process) stays alive until the "Alt-Tab" doing

the screen capture ( i do only pictures, NO videos) is not clear, too. Ok, maybe one step further...
let me explain the capture-steps :
in PinballY i choose the menu-item to capture (i set it to capture backglass and playfield, manual start with a key)
Pinbally starts the table, show a small window with a timer from 20 sec to 0 sec (can be set how long, to give all kind of tables the neccessary start time)
When the time is at 0, i can press the defined key - capture of backglass is taken - then the small window switch from playfield display to backglass display and back - then i can press the defined key again to capture the playfield
PinballY then close the table (the vpx process) and is in menu mode again

now with the new starter.exe,
at the step when the first small window is visible and the countdown starts from 20 -> 0, nothing happens - i can't press the capture key. ONLY when i "ALT-TAB" switch to the table process, then i can use the capture key and then it works.

ok, i know this all sounds crazy, and maybe my wordings are not so clear as they should.
But hopefully you can pull some helpful info out of them, so you could look further with another test version ?

@JockeJarre
Copy link
Owner Author

Thanks for your tests! I guess my fix wasn't good enough. Will have to revisit this when I have a clue what I could try out...
Maybe I will install PinballY, so I can test it myself too

@JockeJarre JockeJarre linked a pull request Mar 29, 2024 that will close this issue
@Karl030167
Copy link

Hi , this one issue is almost gone, but sadly not for complete.
The capture process now is starting ok: PinballY starts the table - the capture "countdown-window" is visible, counts from 20 to 0, then the both captures for backglass and playfield are ok. BUT after this the "table"-task (a.k.a. the vpinballx.exe) won't close.
it needs to manually press ESC to close and return to PinballY

@JockeJarre
Copy link
Owner Author

We'll see if I can find a solution to that...

@JockeJarre
Copy link
Owner Author

Added new issue #11

@JockeJarre
Copy link
Owner Author

Hi , this one issue is almost gone, but sadly not for complete. The capture process now is starting ok: PinballY starts the table - the capture "countdown-window" is visible, counts from 20 to 0, then the both captures for backglass and playfield are ok. BUT after this the "table"-task (a.k.a. the vpinballx.exe) won't close. it needs to manually press ESC to close and return to PinballY

There is a new build under actions... which should now do what you explained.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants