Jump to content

Converting Linux source code to Windows/Mac


Anorax
 Share

Recommended Posts

It's possible, but it'd be pretty hard.

Any GUI stuff would have to be recoded from scratch. The bulk of the code would work with minor issues, but you'd also have to figure out how to make the code present itself as a VST or AU. I don't know about AU, which I'd imagine is similar, but for VSTs, there's a set of C++ functions that must be implemented and exposed in the Windows DLL. The DAW will be looking to call those functions and expect certain things to be returned. Probably, that plugin would generally be compatible with this kind of an approach (I can't imagine the general mechanism of audio plugins in Linux is much different from Windows or Mac), though there might be subtle differences in things that the VST API supports that aren't supported on Linux. I wouldn't expect it to be, simply, "For each function in the VST API, write a stub that calls the appropriate function within the Linux code" (this is called a wrapper, making one thing look like something else externally).

Basically, unless this plugin is REALLY good and unique, it's not worth the effort. GUI aside, it could take a few hours or it could be much more complex, and only someone who knew the VST or AU spec well and had some familiarity with porting to or from Linux would be able to tell. I'd suggest you find an alternative on Windows or Mac.

Link to comment
Share on other sites

It has an interesting sound to it, so I looked into the source code for a few minutes. Porting doesn't really seem to be to difficult, but that would only result in a stand-alone .exe file. But integrating it into a VST is more or less impossible, not because of the code, which can be connected with the VST SDK with a lot of work, but because of legal problems. The license for VST development clashes with the GPL.

BTW, I have only seen Zebra in zircon's tutorials, but can't it do something similar

Link to comment
Share on other sites

It has an interesting sound to it, so I looked into the source code for a few minutes. Porting doesn't really seem to be to difficult, but that would only result in a stand-alone .exe file. But integrating it into a VST is more or less impossible, not because of the code, which can be connected with the VST SDK with a lot of work, but because of legal problems. The license for VST development clashes with the GPL.

BTW, I have only seen Zebra in zircon's tutorials, but can't it do something similar

:-(

could it be recoded into C++?

hell, if I could code individual parts into C++, I would convert it piece by piece into a form that is Synthedit friendly while remaining VST-friendly and reconstruct it in the synthedit modular environment...

Link to comment
Share on other sites

:-(

could it be recoded into C++?

The source is in C++, the only possibilty to recreate that kind of sound, would be to recode the algorithms "by hand" meaning with the same algorithm with your own code. And this code woukd have to be written and adapted for the VST SDK

I haven't worked with SynthEdit yet, but I don't think it is possible to recreate those sounds in SE

Link to comment
Share on other sites

The source is in C++, the only possibilty to recreate that kind of sound, would be to recode the algorithms "by hand" meaning with the same algorithm with your own code. And this code woukd have to be written and adapted for the VST SDK

I haven't worked with SynthEdit yet, but I don't think it is possible to recreate those sounds in SE

I dunno, but (as I'm sure you already know) SE allows the importing of C++ modules in the form of .sem and .sep files (renamed .dlls) that were generated in C++ and created using SynthEdit SDK instead of the normal VST SDK.

Synthedit then exports a finished VST file to a vst .dll in whatever folder it's told to dump finished vsts to.

tl;dr if you can recreate the audio engine of din using the SE SDK then you might be able to recreate it in SynthEdit.

Link to comment
Share on other sites

I dunno, but (as I'm sure you already know) SE allows the importing of C++ modules in the form of .sem and .sep files (renamed .dlls) that were generated in C++ and created using SynthEdit SDK instead of the normal VST SDK.

Synthedit then exports a finished VST file to a vst .dll in whatever folder it's told to dump finished vsts to.

tl;dr if you can recreate the audio engine of din using the SE SDK then you might be able to recreate it in SynthEdit.

Different approach, same problem. You would have to recode by hand, otherwise you would violate the GPL and you would have to rewrite much of the code to accomodate it to the SDK. It's not impossible, but it's complicated. And doing something like this is nothing for the faint of heart, because of the hard realtime problems you face when programming audio related things. I'm a computer science major and I would need quite some time to analyze the code and rewrite it (actually I would try it, if I had enough time on my hands)

Link to comment
Share on other sites

Different approach, same problem. You would have to recode by hand, otherwise you would violate the GPL and you would have to rewrite much of the code to accomodate it to the SDK

I'm not a lawyer (CS grad, actually) but I'd think that even recoding it by hand while making reference to their source code would cause your source code to be under the GPL. My suspicion is that you'd have to write something from scratch without ever looking at the din source code, otherwise your work would be derivative even though you're not cutting and pasting parts of their source into your own project.

Link to comment
Share on other sites

I'm not a lawyer (CS grad, actually) but I'd think that even recoding it by hand while making reference to their source code would cause your source code to be under the GPL. My suspicion is that you'd have to write something from scratch without ever looking at the din source code, otherwise your work would be derivative even though you're not cutting and pasting parts of their source into your own project.

No, as far as I know, it doesn't. You have to publish changes of a program or a new program with source code parts from another ojne, which is licansed under the GPL, under the GPL as well. But when you recreate the workings of the algorithm in your own code you would not violate it. I think the code falls under the GPL, not the algorithm itself. But I would have to read about this once more, because I'm not 100% sure.

@Moseph: You would need to reroute the midi input from the DAW over a midi out port to din and then you would need to catch the audio from din back into the DAW. Tricky but possible. I think if you have a standalone exe, you wouldn't even need a VST Wrapper.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...