<div dir="ltr">I am re-sending this, having joined the list.<div><br></div><div><span style="font-family:arial,sans-serif;font-size:13px">Dear LV2 Team,</span><div style="font-family:arial,sans-serif;font-size:13px"><br></div>
<div style="font-family:arial,sans-serif;font-size:13px">I am trying to create a reverb plug-in a la LV2 for Audacity by modifying the amplifier example (amp.c etc.) and have a question.<div><br></div><div>My reverb is implemented as a C++ class named Multiverb. From my current understanding of LV2 (and LADSPA), it appears that I should instantiate a Multiverb object in "activate", apply it in "run" and delete it in "deactivate". So the object needs to be accessible in all three functions. I see two ways to do this:</div>
<div><br></div><div><ol><li style="margin-left:15px">Declare a pointer to a Multiverb object as a static variatle (<font face="courier new, monospace">static Multiverb *revMono</font><font face="arial, helvetica, sans-serif">) near the top of the file containing the LV2 functions.</font></li>
<li style="margin-left:15px"><font face="arial, helvetica, sans-serif">Declare a pointer to a Multiverb object as a member of the same structure that contains the port variables.</font></li></ol><div><font face="arial, helvetica, sans-serif">I also need to have access to the sampling rate, which I can get when "instantiate" is called. I can also save this as a static or a member of the above mentioned structure.</font></div>
</div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">Which of these is preferable or is there a better way?</font></div><div><font face="arial, helvetica, sans-serif"><br>
</font></div><div><font face="arial, helvetica, sans-serif">Thanks.</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">Warren Koontz</font></div><div>
<font face="arial, helvetica, sans-serif">Professor Emeritus</font></div><div><font face="arial, helvetica, sans-serif">Rochester Institute of Technology</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div>
</div></div></div>