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

Update and bugfix for LV2 support #11

Merged
merged 8 commits into from
Jan 17, 2018
Merged

Update and bugfix for LV2 support #11

merged 8 commits into from
Jan 17, 2018

Conversation

jpcima
Copy link
Collaborator

@jpcima jpcima commented Jan 8, 2018

I have updated foo-yc20 to support the latest faust 0.9.x and modern LV2.
The LV2 used extensions which are long deprecated and not supported in Jalv.
I believe this should fix issues #6 and #7.

This is how the implementation is affected by changes.

  • I have generated the faust code without the architecture file minimal.cpp. Under the new faust it produced a dummy main() function which is in conflict with the code of foo-yc20.
  • The precalculated oscillators. LV2 did not initialize them, crashing the instrument on the first run.
    I converted these tables from global to one per instance. I make the oscillator pointer thread-local to keep the code like it is, but protect if there are concurrent runs. This thread-local may introduce a small runtime cost, which I have not measured.
  • UI2 does not refresh the display after there are interactions. I fix it by refreshing the draw area in mouse event handlers.

@jpcima
Copy link
Collaborator Author

jpcima commented Jan 8, 2018

update: I have found how to keep the oscillator table pointer in the DSP object.
I have eliminated the requirement for thread-local.

@sampov2
Copy link
Owner

sampov2 commented Jan 16, 2018

Thanks for the pull request. Unfortunately I don't have a development environment where I would be able to test this. @trebmuh - have you been able to test these fixes? My main question is that did we lose any functionality? For example, is the MIDI support still there?

@jpcima
Copy link
Collaborator Author

jpcima commented Jan 17, 2018

I have tested LV2 and standalone with Midi under Linux+Jack. There is no change in relation with Jack Midi, however LV2 has needed a transition from the old Event extension to Atom.
However I realize just now there is also a VST version and I have not tried it. It must not be difficult, I will give it a try shortly and add changes if necessary.
I can try Windows and Linux unfortunately I do not have access to Mac.

@sampov2
Copy link
Owner

sampov2 commented Jan 17, 2018

Thanks. Let me know if you're successful in testing the VST support.

@jpcima
Copy link
Collaborator Author

jpcima commented Jan 17, 2018

I tested the VST in 2 configurations: dssi-vst (Wine) and VSTHost for Windows.
It took the same changes than LV2 to avoid a crash in the process routine.
It takes a bit of effort to build in a recent mingw. I just include relevant changes to not overload the commit.

I could add some maintainance needed in other commits. (mingw has evolved a lot but much of the foo-yc20 code is a few years old).

@sampov2 sampov2 merged commit 9ac7b7a into sampov2:master Jan 17, 2018
@sampov2
Copy link
Owner

sampov2 commented Jan 17, 2018

Looks good. Thanks for the work!

@sampov2
Copy link
Owner

sampov2 commented Jan 17, 2018

As for the mingw stuff, it would be great if there was an online build service that offered mingw support that we could use to produce the DLL's. Do you happen to know if there are any available?

@jpcima
Copy link
Collaborator Author

jpcima commented Jan 17, 2018

I am afraid not, I am not familiar with such services.
The simplest route to setting up a mingw build environment with libraries must be msys2. Personally I use a cross-compilation toolchain from Linux.

@sampov2
Copy link
Owner

sampov2 commented Jan 17, 2018

I found a docker project that has containers with crosscompilers: https://github.com/dockcross/dockcross . This could be very good option as containers could offer a stable compilation environment to perform repeatable builds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants