jazz-soft / midi-player

MIDI Player extension for browsers
15 stars 3 forks source link

How is the extension activated? #3

Closed cleinias closed 3 years ago

cleinias commented 3 years ago

I installed the extension it on Firefox, and expected it to launch automatically when a link to a midi file (*.mid) is clicked. Instead, the browser gives me the usual option to open the file in a local app or to save it to disk. (I'm on Linux using the lated version of Firefox-Developer, in case it matters).

jazz-soft commented 3 years ago

Can you post the link please? Some MIDI links are not recognized by the extension because of wrong MIME type provided by the server or CORS-related issues.

cleinias commented 3 years ago

This is the page (I also tried other pages, with the same effect). The exact link is the first midi file linked: http://www.jazclass.aust.com/rhythmcl/rc01m1f.mid

when I click on it, Firefox recognizes it as audio/mid type:  Firefox-reading-a-midi-link

Inspecting the element seems to show that the extension is loaded:

Firefox-console

jazz-soft commented 3 years ago

Thank you! I'll investigate what is going on with that page. It does not work for me either... Does it work on the Wiki pages? e.g. https://en.wikipedia.org/wiki/File:MIDI_sample.mid

jazz-soft commented 3 years ago

Here is the problem with the website above: Content-Type is audio/mid instead of audio/midi I guess it will be an easy fix to make the extension accept the wrong MIME type too :)

cleinias commented 3 years ago

I can confirm the Wikipedia sample file works perfectly on my system. Your diagnosis about the wrong media type seems correct, I wonder if the author of that page got confused with the standard midi file extension. At any rate, I am glad to hear it's an easy fix, and thanks for the extension!

jazz-soft commented 3 years ago

I will publish the new release shortly. Thank you for the valuable information!

jazz-soft commented 3 years ago

I have published v.1.0.1.0 Firefox version is live online, Chrome - pending review, but normally takes them less than one day... Thanks again!

cleinias commented 3 years ago

Thanks for the update! Unfortunately, I see the same behavior as before. I now have version 1.0.2.0 of the Jazz-MIDI extension and version 1.0.0.0 of the MIDI player extension (both dated 12/29/2020). I also have version 1.5.2 of the jazz-midi-plugin installed.

cleinias commented 3 years ago

Actually, I see a regression: now even the Wikipedia sample file does not play anymore. The little player window pops-up correctly when the link is clicked, but it is unresponsive. I can close it, but all other buttons don't work (have no effect).

jazz-soft commented 3 years ago

You need version 1.0.1.0 of the MIDI player extension. Please update it!

cleinias commented 3 years ago

Ah, thanks. Now it works. The problem with the Wikipedia page was related to a different issue: apparently I cannot send the output to my audio interface, even though it was selected by default (from the extension's pop-up window's "little note" drop-down menu). Choosing "web audio" solved the problem, the window turned responsive again and the audio was processed correctly.