3 #include <vst/aeffectx.h>
5 long amc (AEffect
* effect
,
13 case audioMasterVersion
:
21 fst_signal_handler (int sig
, siginfo_t
* info
, void* context
)
23 fst_error ("fst signal handler %d, thread = 0x%x", sig
, pthread_self ());
27 void vst_print (AEffect
*plugin
)
36 printf ("inputs: %lu\n", plugin
->numInputs
);
37 printf ("outputs: %lu\n", plugin
->numOutputs
);
38 printf ("params: %lu\n", plugin
->numParams
);
39 printf ("programs: %lu\n", plugin
->numPrograms
);
40 printf ("can HasEditor ? %ld\n", plugin
->flags
& effFlagsHasEditor
);
41 printf ("can HasClip ? %ld\n", plugin
->flags
& effFlagsHasClip
);
42 printf ("can HasVu ? %ld\n", plugin
->flags
& effFlagsHasVu
);
43 printf ("can CanMono ? %ld\n", plugin
->flags
& effFlagsCanMono
);
44 printf ("can CanReplacing ? %ld\n", plugin
->flags
& effFlagsCanReplacing
);
45 printf ("can ProgramChunks ? %ld\n", plugin
->flags
& effFlagsProgramChunks
);
47 plugin
->dispatcher (plugin
, effGetVendorString
, 0, 0, bigbuf
, 0);
48 printf ("Vendor: %s\n", bigbuf
);
49 plugin
->dispatcher (plugin
, effGetProductString
, 0, 0, bigbuf
, 0);
50 printf ("Product: %s\n", bigbuf
);
51 printf ("Version: %d\n", plugin
->dispatcher (plugin
, effGetVendorVersion
, 0, 0, NULL
, 0.0f
));
53 vst_version
= plugin
->dispatcher (plugin
, effGetVstVersion
, 0, 0, NULL
, 0.0f
);
55 if (vst_version
>= 2) {
56 printf ("Needs keypresses? %d\n",
57 plugin
->dispatcher (plugin
, effKeysRequired
, 0, 0, NULL
, 0.0f
));
60 for (i
= 0; i
< plugin
->numParams
; i
++) {
62 /* the Steinberg(tm) way... */
65 printf ("Control input/output(s):\n");
69 memset (display
, 0, 25);
72 plugin
->dispatcher (plugin
,
76 plugin
->dispatcher (plugin
,
79 plugin
->dispatcher (plugin
,
82 printf (" #%d \"%s\" (%s %s)\n",
83 i
+ 1, name
, display
, label
);
87 main (int argc
, char *argv
[])
92 if (fst_init (fst_signal_handler
)) {
96 if ((handle
= fst_load (argv
[1])) == NULL
) {
100 if ((fst
= fst_instantiate (handle
, amc
, 0)) == NULL
) {
104 vst_print (fst
->plugin
);