ValleyAudio / ValleyRackFree

Modules for VCV Rack
Other
176 stars 26 forks source link

v2: Reference to custom font stored across frames #66

Closed cschol closed 2 years ago

cschol commented 2 years ago

Your plugin stores references to custom fonts across frames. This leads to crashes in the VST when reloading a project.

For example (but there might be others):

PlainText::PlainText() {
    font = APP->window->loadFont(asset::system("res/fonts/ShareTechMono-Regular.ttf"));
    color = nvgRGB(0xCF, 0xCF, 0xCF);
    horzAlignment = NVG_ALIGN_CENTER;
    vertAlignment = NVG_ALIGN_TOP;
    size = 16;
}

Please see the following link on how to resolve this issue and re-submit to the Library: https://vcvrack.com/manual/Migrate2#2-1-Don-t-store-Font-and-Image-references-across-multiple-frames