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

Piano keyboard does not work when MuseScore is newly opened #17421

Open
AlexAndPedro opened this issue Apr 30, 2023 · 11 comments
Open

Piano keyboard does not work when MuseScore is newly opened #17421

AlexAndPedro opened this issue Apr 30, 2023 · 11 comments
Assignees
Labels
needs review The issue needs review to set priority, fix version or change status etc.

Comments

@AlexAndPedro
Copy link

Issue type

Other type of issue

Bug description

Piano does not work when MuseScore is newly opened. It will only work after a note has been inputted on the staff.

Steps to reproduce

  1. Open MuseScore 4
  2. Create a new score
  3. Immediately open the piano by Pressing P
  4. Press any key of the piano. No audio.
  5. Add a note on the staff.
  6. Piano now works.

Screenshots/Screen recordings

2023-04-30.14-27-52.mp4

MuseScore Version

Version 4.0.2

Regression

I don't know

Operating system

Windows 10

Additional context

No response

@muse-bot muse-bot added the needs review The issue needs review to set priority, fix version or change status etc. label Apr 30, 2023
@cbjeukendrup cbjeukendrup changed the title Piano does not work when MuseScore is newly opened Piano keyboard does not work when MuseScore is newly opened Apr 30, 2023
@MarcSabatella
Copy link
Contributor

You don't need to enter a note but you do need to select something so MuseScore knows which staff to use for the sound. That's kind of by design, but one with room for improvement - a reasonable default should exist.

@bkunda
Copy link

bkunda commented May 1, 2023

When you are not in note input mode, pressing keys on the piano keyboard previews the sound – nothing is entered on the stave.
As soon as you enter note input mode, pressing keys on the piano keyboard enters those notes on the stave.
That's really the extent of it. Am I missing something here that you expect the keyboard to do, but isn't doing @AlexAndPedro?

And @MarcSabatella I'll need you to clarify what you mean by "a reasonable default should exist".

@cbjeukendrup
Copy link
Contributor

What's missing, is that sound preview does not work when you have just opened MuseScore. It only starts working after clicking on a note or entering a note.
I think that what needs to happen is that we will by default use the sound of the topmost staff if the user has not yet selected anything.

@MarcSabatella
Copy link
Contributor

Exactly. Although, using the top staff when nothing is selected is what MU3 did and we did get complaints about that. People would resort to adding an invisible staff above all others to force a specific sound to be used.

It is a piano keyboard, so another reasonable possibility - and one that some users had requested - is to use piano sound unless something explicit is selected. Another possibility is to give the piano keyboard its own mixer channel so the user can select a sound, although I'm not sure that should take precedence if the user has explicitly selected a staff.

@bkunda
Copy link

bkunda commented May 1, 2023

Ah got it, ok.
I think there are two parts to this issue:

  1. You shouldn't have to enter a note to trigger the "preview-sound-on-selected-stave" feature; i.e. just selecting a stave and pressing a note on the keyboard should be enough to hear a preview of the sound assigned to that stave. I think it's reasonable to call this out as a bug, and one we might address in the first instance.

  2. Pressing a note on the keyboard should trigger a sound even if nothing is selected. This means deciding on a "reasonable default" (top stave sound, piano sound, etc.). This is perhaps a bit more contentious (as you've pointed out, @MarcSabatella). If we were to fix point 1 above, then I'd be curious to see whether people still get confused by the current behaviour (i.e. no sound when nothing is selected), and how long it takes them to figure out that a stave needs to be selected before hearing anything. Certainly, I can see that pressing a key and seeing it become highlighted could be a bit misleading when there is no sound.

@cbjeukendrup
Copy link
Contributor

cbjeukendrup commented May 1, 2023

It turns out that I was apparently confused myself: you have to select something and keep it selected. That is working correctly (even immediately after opening MuseScore afaics), so there is no bug fortunately.

But I think that's quite unintuitive. My expectation would be that sound preview will always use the sound of the last clicked staff, even if nothing is currently selected. And if you have never clicked anything yet, it will use the sound of the top staff.

(And by the way, it looks like in MS3 sound preview is not working at all. Is that correct?)

@MarcSabatella
Copy link
Contributor

MarcSabatella commented May 1, 2023

It seems that for a newly opened score, selecting a staff is enough to trigger sound. But for a newly created score, you do indeed need to enter a note first. So indeed, that's a bug.

Regarding the default with nothing selected, I agree that if something was previously selected, we should use that. We do partially track this already, but only during note input. We use it to re-establish a reasonable note input position if the user presses "N" with nothing selected, and also to re-establish the selection for the accessibility command "Shift+L". Should be simple enough to add the tracking to ordinary selection as well.

MU3 piano keyboard is working fine for me. I know there was a bug at one point where you would or wouldn't get sound from the keyboard depending on exactly what was selected - note, rest, or range.

@bkunda
Copy link

bkunda commented May 1, 2023

At the moment in MS4: yes, you have to keep something selected. However, if you've just created the score, then even selecting a stave won't trigger the sound preview feature; you have to enter a note first to kick-start it into gear. I'd suggest that this is a bug.

Interestingly, your point about the sound preview always using the last clicked staff is how MS3 does it, and it does seem to be working.

@bkunda
Copy link

bkunda commented May 1, 2023

Ok so to summarise our desired behaviour:

  1. Create a score > select a stave > press a note on the keyboard: User should hear a preview of that stave (currently doesn't work, so this is a bug)
  2. Clear selection > press a note on the keyboard: User should hear a preview of the last selected stave
  3. Select a different stave: User should hear a preview of the sound assigned to that stave

How does this sound?

@MarcSabatella
Copy link
Contributor

Good to me. I'd still like a sound in the case where nothing has been selected at all yet - so there is no last-selected to use. Top staff is as good as anything.

@AlexAndPedro
Copy link
Author

When you are not in note input mode, pressing keys on the piano keyboard previews the sound – nothing is entered on the stave. As soon as you enter note input mode, pressing keys on the piano keyboard enters those notes on the stave. That's really the extent of it. Am I missing something here that you expect the keyboard to do, but isn't doing @AlexAndPedro?

And @MarcSabatella I'll need you to clarify what you mean by "a reasonable default should exist".

Whenever I first see the keyboard, I am expecting a piano, but when I am composing with different instruments, I am expecting those instrument instead. I am used to the default staff to be piano so I immediately assumed that having a new score will have the piano keyboard a piano sound too. Also, I only notice the piano keyboard not working because I was tuning my instruments and I was too lazy to go to my physical piano so I just open MuseScore and go immediately to the piano keyboard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs review The issue needs review to set priority, fix version or change status etc.
Projects
None yet
Development

No branches or pull requests

6 participants