ソースを参照

Fixed some shaders not getting properly compiled (missing part of the content)

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
Alexis Maiquez 3 年 前
親
コミット
cd40950ade
1 ファイル変更、3 行追加、1 行削除
  1. 3 1
      src/WallpaperEngine/Render/Shaders/Compiler.cpp

+ 3 - 1
src/WallpaperEngine/Render/Shaders/Compiler.cpp

@@ -365,6 +365,7 @@ namespace WallpaperEngine::Render::Shaders
                     // types not found, try names
                     if (this->m_error == false)
                     {
+                        this->ignoreSpaces (it);
                         this->m_compiledContent += type;
                     }
                     else
@@ -444,9 +445,10 @@ namespace WallpaperEngine::Render::Shaders
                 // check for types first
                 std::string type = this->extractType (it);
 
-                // types not found, try names
+                // type found
                 if (this->m_error == false)
                 {
+                    this->ignoreSpaces (it);
                     // check for main, and take it into account, this also helps adding the includes
                     std::string name = this->extractName (it);