Old 11th September 2010, 00:00   #1
mre521
Junior Member
 
Join Date: Jul 2009
Location: Behind You
Posts: 4
How to use official Winamp Plugin with own program?

I'm trying to make a program to test a player I made for a sound format and I decided that it would be easy enough to just use a Winamp output plugin (out_wave.dll). So I include the out.h file so I can access the plugins structure. Then I try to load the plugin with LoadLibrary. I get the following error box:

Microsoft Visual C++ Runtime Library
Runtime Error! Program: C:\Documents And Settings\......
R6032
An application has made an attempt to load the C runtime library incorrectly.
Please contact the applications support team for more information


I know its because of msvcr90.dll and I have put it in the directory of my program.
I have searched on Google and it seems it's because I need to include a manifest file in my programs resource.

Does anyone know how I can load any of Winamps official output plugins?

Edit: Added a pic of the error window
Attached Thumbnails
Click image for larger version

Name:	runtime_error.PNG
Views:	169
Size:	8.2 KB
ID:	47555  
mre521 is offline   Reply With Quote
Old 11th September 2010, 06:55   #2
SilverBird775
Senior Member
 
SilverBird775's Avatar
 
Join Date: Jan 2009
Location: Russia
Posts: 237
Yes the msvcr90.dll is the cause. I'd bind the project with the Microsoft.VC90.CRT.manifest found in Microsoft.VC90.CRT folder of winamp directory.

By the way, just try for a start to host some third party plugins which don't have much of dll dependency, let them work and once you feel they are working as desired go on with official ones. This would simplify the debug. I do strongly recommend some existed plugin hosts aka "winamp alike player" this should bring you a lot of thought and hints.

My absolute favourite is PlainAmp i wish some day some good man would spark this great project a whole new life.
SilverBird775 is offline   Reply With Quote
Old 11th September 2010, 11:55   #3
DrO
 
Join Date: Sep 2003
Posts: 27,873
the official plug-ins really aren't designed to work from another process as you'd need to replicate api_language. api_service, parts of the Winamp api including a replicated Winamp main window to deal with message requests and a few other nuances and also deal with the dll dependency loading (can be done either by altering the manifest which then gets things into a dodgy area) or your app needs to have the same dll dependency + manifest which the loaded dll will then follow.

an alternative would be to output your test output to a wav file and then play that - this is how the vgmstream project works for its test app and might be an idea.

as for plainamp, that works better with non-nullsoft plug-ins as most plug-in authors don't seem to want to use the correct apis (even ones from the 2.9x release for knowing where to save settings to). then again there's other existing players/apps which use Winamp plug-ins though the Winamp plug-in design is really bad, it's only because of it's simplicity that it's easy for other apps in the past to use them.

-daz
DrO is offline   Reply With Quote
Reply
Go Back   Winamp & SHOUTcast Forums > Developer Center > Winamp Development

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump