Delphi ASIO & VST sourceforge project
-
- KVRist
- 101 posts since 29 Dec, 2002
Hi,
I'm now using Delphi 2009 and downloaded the latest source from the Subversion repository. I see there's now a D12 set of projects but I had a lot of difficulty getting things to compile, and when I did my first test plugin crashed in VST hosts so I think there's some stuff (I'm guessing unicode issues) still to iron out. Before I wade in trying to pinpoint the problems I just wanted to check whether other people already had it working in D2009 successfully in which case I may be missing something.
Many thanks.
I'm now using Delphi 2009 and downloaded the latest source from the Subversion repository. I see there's now a D12 set of projects but I had a lot of difficulty getting things to compile, and when I did my first test plugin crashed in VST hosts so I think there's some stuff (I'm guessing unicode issues) still to iron out. Before I wade in trying to pinpoint the problems I just wanted to check whether other people already had it working in D2009 successfully in which case I may be missing something.
Many thanks.
-
Christian Budde Christian Budde https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=25572
- KVRAF
- Topic Starter
- 1538 posts since 14 May, 2004 from Europe
Hi Chrispy
If you have any suggestions, just let me know,
Christian
I built the D12 package based on the D11 packages. It might not be up-to-date though. The reason is, that I don't have D2009. I got some reports about things necessary to get it running. I changed some of the issues, but there still might remain some of the point (I didn't like the suggested workarounds, which meant a drawback for other Delphi version).Chrispy wrote:I'm now using Delphi 2009 and downloaded the latest source from the Subversion repository. I see there's now a D12 set of projects but I had a lot of difficulty getting things to compile, and when I did my first test plugin crashed in VST hosts so I think there's some stuff (I'm guessing unicode issues) still to iron out. Before I wade in trying to pinpoint the problems I just wanted to check whether other people already had it working in D2009 successfully in which case I may be missing something.
If you have any suggestions, just let me know,
Christian
-
- KVRist
- 101 posts since 29 Dec, 2002
This page seems to have a good description of the things to look out for with the unicode conversion:Christian Budde wrote:Hi Chrispy
If you have any suggestions, just let me know,
Christian
http://www.micro-isv.asia/2008/08/get-r ... d-unicode/
I went through the main units such as DAV_VSTEffect.pas and changed any Char arrays to AnsiChar, such as:
TVstParameterPropertyRecord = packed record
...
Caption: array[0..63] of {$IFDEF UNICODE} AnsiChar {$ELSE} Char {$ENDIF};
...
Likewise I changed PChar's to PAnsiChar's. Then in units like DAV_VSTCustomModule.pas I changed code such as:
FEffect.uniqueID[4 - i] := {$IFDEF UNICODE} AnsiChar(Value) {$ELSE} Value {$ENDIF}
And... now plugins are working in my host. However, whether I've found everything remains to be seen.
Thinking about it, there's not really any need to use the $IFDEF's for a lot (all?) of these - I'm thinking it would be safe to change "Char" to "AnsiChar" in the code (i.e. being explicit about the type rather than relying on Delphi's alias) and it would compile on D2009 and pre-D2009. So maybe that's the way to go; make all Char's explicitly AnsiChar where necessary (i.e. where there's no benefit from unicode), likewise for PChar->PAnsiChar and string -> AnsiString.
-
Christian Budde Christian Budde https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=25572
- KVRAF
- Topic Starter
- 1538 posts since 14 May, 2004 from Europe
I did so and it should now hopefully compile out of the box.Chrispy wrote:So maybe that's the way to go; make all Char's explicitly AnsiChar where necessary (i.e. where there's no benefit from unicode), likewise for PChar->PAnsiChar and string -> AnsiString.
Kind regards,
Christian
-
Norbert Stellberg Norbert Stellberg https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=37198
- KVRist
- 78 posts since 16 Aug, 2004
Hello,
I use the newest source from repository with Delphi 7
Now I will made any tests with WINE.
But not a program of all samples does find an ASIO driver.
Asio drivers are installed. Other programs does find this drivers.
Has here anybody an idee, why I cannot see an ASIO driver?
with best regards
Norbert
I use the newest source from repository with Delphi 7
Now I will made any tests with WINE.
But not a program of all samples does find an ASIO driver.
Asio drivers are installed. Other programs does find this drivers.
Has here anybody an idee, why I cannot see an ASIO driver?
with best regards
Norbert
-
- KVRian
- 1343 posts since 26 Aug, 2005 from Netherlands
Christian, Guys,
I'm having a difficult time figuring out how exactly chunk exchanging with the host is handled in this setup. I see there's a TMemoryStream called "chunk" declared. What am I supposed to do with it? Simply open it and write to it? Do I also need to manage the accompanying chunk descriptor record manually or is that done automatically?
Cheers,
Bram
I'm having a difficult time figuring out how exactly chunk exchanging with the host is handled in this setup. I see there's a TMemoryStream called "chunk" declared. What am I supposed to do with it? Simply open it and write to it? Do I also need to manage the accompanying chunk descriptor record manually or is that done automatically?
Cheers,
Bram
-
Christian Budde Christian Budde https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=25572
- KVRAF
- Topic Starter
- 1538 posts since 14 May, 2004 from Europe
The chunk handling is indeed not very clearly defined. There are some examples that make use of storing the parameters within a chunk, but I can't say which one exactly (I know the plugin merger template uses this, but beside I can't remember).brambos wrote:I'm having a difficult time figuring out how exactly chunk exchanging with the host is handled in this setup. I see there's a TMemoryStream called "chunk" declared. What am I supposed to do with it? Simply open it and write to it? Do I also need to manage the accompanying chunk descriptor record manually or is that done automatically?
However, from the VST interface point of view it's nothing more than a pointer to a memory and the size of that 'chunk'. It's your job to interprete this chunk to parameters and your job to form the parameters to a chunk when it comes to saving.
For handling the chunks I introduced the two events 'OnBeforeProgramChange' and 'OnAfterProgramChange'. It's still a lot of work here to make it more smooth and 'integrated'.
Also note 'OnGetChunkParameter', which is used to interprete the parameter from a chunk. It queries the parameter value by an index. Use the ParameterChange to store the parameter values back into your chunk.
I am still working on another important project, but as soon as I have some spare time I'll definitely have a look into this as it is necessary for some other plugins (e.g. the convolution stuff I recently added).
Kind regards,
Christian
-
Christian Budde Christian Budde https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=25572
- KVRAF
- Topic Starter
- 1538 posts since 14 May, 2004 from Europe
Hi,
tomorrow morning I got the idea of having a dedicated forum for the Delphi ASIO & VST stuff here at KVR. Since there is no manual or help file, this might be a good thing to store some information.
Any thoughts?
Kind regards,
Christian
PS: If there are about five or more persons interested in this, I'll ask Ben for it.
tomorrow morning I got the idea of having a dedicated forum for the Delphi ASIO & VST stuff here at KVR. Since there is no manual or help file, this might be a good thing to store some information.
Any thoughts?
Kind regards,
Christian
PS: If there are about five or more persons interested in this, I'll ask Ben for it.
-
- KVRAF
- 8389 posts since 11 Apr, 2003 from back on the hillside again - but now with a garden!
-
- KVRian
- 1343 posts since 26 Aug, 2005 from Netherlands
Thanks for reacting, Christian.
Cheers!
I'll have a look at those. Good to know there's a working example around. That should give me enough pointers (sic) to figure it out.Christian Budde wrote:The chunk handling is indeed not very clearly defined. There are some examples that make use of storing the parameters within a chunk, but I can't say which one exactly (I know the plugin merger template uses this, but beside I can't remember).
I'm aware of that, since I've had to handle those chunks in Tunafish. Hence I was expecting a pointer variable of sorts in the OnGetChunkParameter declaration but there wasn't. I stumbled on some chunk related objects here and there, but I couldn't quite figure out if they were also created/initialized and whether I was supposed to mess with them at all or to leave them alone.Christian Budde wrote:However, from the VST interface point of view it's nothing more than a pointer to a memory and the size of that 'chunk'. It's your job to interprete this chunk to parameters and your job to form the parameters to a chunk when it comes to saving.
Cheers!
-
Christian Budde Christian Budde https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=25572
- KVRAF
- Topic Starter
- 1538 posts since 14 May, 2004 from Europe
Hi Brambos,
I added an example to the SVN repository of how it should work. Unfortunatly it doesn't work that good. It might also be the host I was trying (a modified version of my VST Plugin Analyser), but I'm not sure.
At least you can have a look. The name is 'Chunk Demo' and you can find it under examples. The effect itself is a chaos product of a crossover filters, a pitchshifter, a compressor and a bunch of filters...
Kind regards,
Christian
I added an example to the SVN repository of how it should work. Unfortunatly it doesn't work that good. It might also be the host I was trying (a modified version of my VST Plugin Analyser), but I'm not sure.
At least you can have a look. The name is 'Chunk Demo' and you can find it under examples. The effect itself is a chaos product of a crossover filters, a pitchshifter, a compressor and a bunch of filters...
Kind regards,
Christian
-
- KVRian
- 1343 posts since 26 Aug, 2005 from Netherlands
Christian Budde wrote:Hi Brambos,
I added an example to the SVN repository of how it should work. Unfortunatly it doesn't work that good. It might also be the host I was trying (a modified version of my VST Plugin Analyser), but I'm not sure.
At least you can have a look. The name is 'Chunk Demo' and you can find it under examples. The effect itself is a chaos product of a crossover filters, a pitchshifter, a compressor and a bunch of filters...
Youz da man!
-
Christian Budde Christian Budde https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=25572
- KVRAF
- Topic Starter
- 1538 posts since 14 May, 2004 from Europe
Let me know if it is working. Or what is still necessary to get it working. And if you have better ideas on how to implement this, just let le know,brambos wrote:Christian Budde wrote:Hi Brambos,
I added an example to the SVN repository of how it should work. Unfortunatly it doesn't work that good. It might also be the host I was trying (a modified version of my VST Plugin Analyser), but I'm not sure.
At least you can have a look. The name is 'Chunk Demo' and you can find it under examples. The effect itself is a chaos product of a crossover filters, a pitchshifter, a compressor and a bunch of filters...
Youz da man!
Christian
-
- KVRian
- 1343 posts since 26 Aug, 2005 from Netherlands
Will do. I just had a peek at the code and it makes much more sense now. I'll test and tweak this (with Cubase) to get it to work and let you know if/what needs to be changed.Christian Budde wrote:Let me know if it is working. Or what is still necessary to get it working. And if you have better ideas on how to implement this, just let le know,brambos wrote:Youz da man!
Cheers!
-
Salih Sertkaya Salih Sertkaya https://www.kvraudio.com/forum/memberlist.php?mode=viewprofile&u=202857
- KVRer
- 8 posts since 11 Mar, 2009
Hi Christian Budde,
Sorry, for my poor English...
Many thanks for your great DAV project for Delphi developers:-)
I know this, there is only your components in our small world which I've been learned more knowledge of ASIO, VST and DSP!
You're a hero as other(Tobybear, Duncan Parsons etc...) for me and my family!
Please, don't stop the WinAmp stuff!
Can you please add a Paypal button to donate unlimited money for DAV project on your private website page under Delphi title?
For you and all heros, I wish all the best!
Best regards,
Salih Sertkaya
Sorry, for my poor English...
Many thanks for your great DAV project for Delphi developers:-)
I know this, there is only your components in our small world which I've been learned more knowledge of ASIO, VST and DSP!
You're a hero as other(Tobybear, Duncan Parsons etc...) for me and my family!
Please, don't stop the WinAmp stuff!
Can you please add a Paypal button to donate unlimited money for DAV project on your private website page under Delphi title?
For you and all heros, I wish all the best!
Best regards,
Salih Sertkaya

