Moves the shader compiling into new func