X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Fprogram.cpp;h=4cdbf97c0fcdf84431b1ba88044cc8bd41addb07;hb=73bef37da97b6da0b99227f63235cb52c4e56c44;hp=74c1df3e3058ac069bda809cf96a9566bf1e2904;hpb=c1b0303f65ee966a973197cbdbf177c571478674;p=libs%2Fgl.git diff --git a/source/core/program.cpp b/source/core/program.cpp index 74c1df3e..4cdbf97c 100644 --- a/source/core/program.cpp +++ b/source/core/program.cpp @@ -36,12 +36,13 @@ Program::Program(const std::string &source) if(source.find(';')==string::npos && source.size()>5 && !source.compare(source.size()-5, 5, ".glsl")) { if(RefPtr io = Resources::get_builtins().open(source)) - compiler.compile(*io, source); + compiler.load_source(*io, source); else throw IO::file_not_found(source); } else - compiler.compile(source); + compiler.set_source(source); + compiler.compile(); compiler.add_shaders(*this); link(); }