Subject: Emacspeak discussion list
List archive
- From: Tim Cross <theophilusx AT gmail.com>
- To: "T.V Raman" <raman AT google.com>
- Cc: emacspeak AT emacspeak.net
- Subject: Re: [Emacspeak] Some auditory icon related bugs/issues
- Date: Wed, 24 Apr 2024 12:25:52 +1000
OK, I have tracked down both issues.
1. nil ems--play-args. The problem here is with the defcustom. If you select SoX, it sets the path to the hard coded value /usr/bin/play. However, sox-play is set based on a search for the play program. Yesterday, while tracking down issues, I did a sym link from /usr/bin/play to /usr/local/bin/play. As a result, when running the below custom definition and setting it to sox, the cond to set ems--play-args fails to match because emacspeak-play-program is /usr/bin/play and sox-play is /usr/local/bin/play.
As it stands now, the defcustom will not work for anyone who chooses SoX, but there SoX play program is not in /usr/bin. This could be a problem fo anyone who builds from source (where the default will likely be to install into /usr/local/bin) and possibly an issue for other platforms, like mac and installing SoX via homebrew, where it could be in /usr/local/bin or it could be in a homebrew specific directory that is added to the path. Probably need to change the defcustom to not use the const choice menu and instead allow user to enter a path and have it default to what sox-play is.
2. Failure to play emacspeak.ogg icon. I think your on the wrong track here. It isn't an issue with loading the samples. The problem is with emacspeak-sounds-resource and the emacspeak-sounds-cache hashtable. There are two issues here -
a. emacspeak-sounds-resource returns 'button' if an icon is not found AND you are using pactl, but it will return nil if your using SoX.
b. I cannot find anywhere in the code where the files in prompts directory are loaded into the emacspeak-soounds-cache hash table. This means that whenever you try to find an icon from one of these files, such as emacspeak.ogg, it won't be found.
The reason I was not hearing the emacsepeak.ogg file being played with the default pactl setup is because it is playing the default 'button' icon as emacspeak-sounds-resource did not find the 'emacspeak icon in the emacspeak-sounds-cache hashtable. The same error occurs with Sox, but because emacspeak-sounds-resource does not have a defualt when using Sox, the error generates the more severe sringp nil error.
The fix would be to add a new function which is called when emacspeak-sounds is loaded which add the ogg files in the prompts directory to the sounds cache hashtable. May also want to add the ptompts directory to the emacspeak-sounds-cache-rebuild function, though this is probably not required as long as the files are added at least once as they don't change (unlike changing themes).
On Wed, 24 Apr 2024 at 10:09, Tim Cross <theophilusx AT gmail.com> wrote:
Just pulled updates and tested. Unfortunately still not working.- When I start with default settings i.e. using pactl and stored icon sounds I no longer hear the emacspeak.ogg startup icon at all.- When I change the play program to sox, it does now set the correct path to /usr/bin/play, but it frails with the same wrong-type-argument stringp nil error. Looking at the backtrace, it also looks like the ems--play-args is not getting included in the call. The top of the stacktrace ismake-process(:name "Player" :buffer nil :command ("/usr/bin/play" nil nil))Sorry it isn't a full backtrace, but the error breaks emacs such that you cannot integer any commands and have ot kill it from outside.On Wed, 24 Apr 2024 at 00:56, T.V Raman <raman AT google.com> wrote:Most of these were because things are now simpler with only ogg files.
1. emacspeak-speak-version is simpler it just plays an icon
2. because vanilla bin/play handles .ogg, we can just use that
(doesn't do mp3)
3. I still haven't chased down cases where we get a null icon after
the above changes, let me know if that still happens.
--
--
--regards,Tim--Tim Cross
--
regards,
Tim
--
Tim Cross- [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/23/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, T.V Raman, 04/23/2024
- [Emacspeak] Some auditory icon related bugs/issues, T.V Raman, 04/23/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/23/2024
- [Emacspeak] Some auditory icon related bugs/issues, T.V Raman, 04/23/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/23/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, T.V Raman, 04/23/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/24/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, T.V Raman, 04/24/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/24/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/24/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, T.V Raman, 04/24/2024
- Re: [Emacspeak] Some auditory icon related bugs/issues, Tim Cross, 04/23/2024
Archive powered by MHonArc 2.6.19+.