Git Product home page Git Product logo

Comments (18)

santimagames avatar santimagames commented on August 15, 2024 1

Hi, Keijiro.

Sorry to keep going back to the same issue but I can now confirm that this problem has got nothing to do with .meta files. The problem stems from the original dll file. Replacing the dll does not change anything contrary to what I've said before. Basically once you exit the game, the game will hang in the task manager for a few minutes after quitting, this includes the Unity editor itself. So when you build your game, quit Unity and start your game, you'll see that the Unity executable will linger in the task manager and MidiJack will not work. If you wait for a few minutes the executable will quit by its own, then you can run your game and MidiJack will definitely work. So it kind of works, as long as you wait for a few minutes between sessions.

from midijack.

santimagames avatar santimagames commented on August 15, 2024

I found a workaround and maybe the possible cause of the problem.

The workaround is to copy the original MidiJackPlugin.dll file from it's original Assets\MidiJack\Plugins\x64 folder to your built _Data\Plugins folder.

Do this before running your application, otherwise it will not let you overwrite the old .dll file. If you've already ran your app and quit it, you can see your app still working as a background process. The reason being a possible crash or a memory leak from the problematic old .dll I assume. Although I'm not too certain about this.

Maybe the reason for this problem is that Unity copying the 32bit dll into the build? Hard to say.

from midijack.

keijiro avatar keijiro commented on August 15, 2024

I'm under the impression that the root cause of the problem is the same to Funnel's case:

keijiro/Funnel#16 (comment)

I think I should update the .meta file of the plugin, actually don't know why though.

from midijack.

santimagames avatar santimagames commented on August 15, 2024

I see, but the first time this problem happened, I had just imported the unitypackage file. So the .meta file should have been automatically created, right?

from midijack.

keijiro avatar keijiro commented on August 15, 2024

.meta files are included in the unitypackage file. I guess that they have a problem, so that they have to be removed and recreated.

from midijack.

santimagames avatar santimagames commented on August 15, 2024

Yes I think that worked. Thanks.

Interestingly previous non-working builds also started to work as well.

I don't how that was possible :)

from midijack.

keijiro avatar keijiro commented on August 15, 2024

Thanks for verifying. I'll update them on my side.

from midijack.

santimagames avatar santimagames commented on August 15, 2024

Actually, I think the problem still persists. I thought it worked. Today I've updated the project to 2018.1 and same thing happened.

The other issue is, once you build and run the game, even though you quit the game, the game will linger in the task manager for a while. When you try to delete the game files, it will not let you (obviously). So I tried to delete everything one by one, it turns out the lingering file is no other than MidiJackPlugin.dll. You can delete everything else. So even after you quit the game, MidiJackPlugin.dll keeps running for a while. By the way, trying to end the task in the Task Manager doesn't do anything (it says "Access is denied" if you do it in the Details tab of the Task Manager). Fortunately after 5 minutes or so it will quit itself, so you don't need to reboot the computer.

I tried deleting all the meta files again before building the game, this time it did not work.

I also tried copying the original 64bit MidiJackPlugin.dll file to the built plugins folder, that did not work either. So nothing's working right now. I'll try to reboot after I post this message and will let you know.

from midijack.

santimagames avatar santimagames commented on August 15, 2024

A reboot works. I wonder if this method will work without copying the MidiJackPlugin.dll to the built plugins folder.

from midijack.

santimagames avatar santimagames commented on August 15, 2024

Hi, Keijiro.

Any updates on the issue?

Thanks.

from midijack.

MidnightGD avatar MidnightGD commented on August 15, 2024

Hi, i have the same problem. On MacOs everything works fine but on Windows 10 MidiJack only works in the editor. I cant get it to work at all in builds.

Has @santimagames have you found a solution for this problem?

from midijack.

Knomer avatar Knomer commented on August 15, 2024

Win 8.1 x64. Same problem.
after build in MidiDriver.cs "var data" always zero

// Process the message queue.
            while (true) {
                // Pop from the queue.
                var data = DequeueIncomingData();
                if (data == 0) break;

from midijack.

MidnightGD avatar MidnightGD commented on August 15, 2024

@keijiro can you help us with the problem? Are we missing something or is it maybe a bug?

from midijack.

keijiro avatar keijiro commented on August 15, 2024

Currently I'm occupied with other tasks (mainly for Unite events), so unfortunately I don't have time to look into the issue.

from midijack.

MidnightGD avatar MidnightGD commented on August 15, 2024

Thanks for you answer, even if its kind a bad news for us :D
@Knomer have you made any progress with your problem?

from midijack.

BoxOfClicks avatar BoxOfClicks commented on August 15, 2024

Also suffering from this issue - did anyone make any progress? Frustratingly the more up-to-date RtMidi project works fine for sending midi out but not receiving midi for me (LPD8 Win 10 x64). Who knew getting midi working would be so tricky.

from midijack.

keijiro avatar keijiro commented on August 15, 2024

@BoxOfClicks Please use the RtMidi repository to report issues about RtMidi.

from midijack.

BoxOfClicks avatar BoxOfClicks commented on August 15, 2024

Thanks @keijiro - happy to create an issue there too.

With regard to MidiJack, I've done a bit more investigation and it seems as though the MidiJack process never exits, causing any app that uses it to be put into a 'suspended' state when closed. At this point the app cannot be force quit, even through the terminal taskkill command.

Thus if, for example, you opened an application using MidiJack, you would be unable to delete or uninstall the app until restarting your machine. It also means it's not possible to have two apps (or app + editor) run without a machine restart between. If anyone has any pointers or knows a way to force terminate the process on app quit, that would be much appreciated.

from midijack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.