diff --git a/src/QtAV_Global.cpp b/src/QtAV_Global.cpp index 93308001..1ba55d4d 100644 --- a/src/QtAV_Global.cpp +++ b/src/QtAV_Global.cpp @@ -332,3 +332,21 @@ public: InitFFmpegLog fflog; } } + +// Initialize Qt Resource System when the library is built +// statically + +static void initResources() { + Q_INIT_RESOURCE(shaders); + Q_INIT_RESOURCE(QtAV); +} + +namespace { + class ResourceLoader { + public: + ResourceLoader() { initResources(); } + }; + + ResourceLoader QtAV_QRCLoader; +} +