public void GetLastErrors(ShadingLanguages targetLanguage, ref string outVertexError, ref string outFragmentError) { var compiler = compilers[(int)targetLanguage]; outVertexError = compiler.LastVertexError; outFragmentError = compiler.LastFragmentError; }
public MainWindow() { InitializeComponent(); textEditor.TextArea.Caret.CaretBrush = new SolidColorBrush(Colors.Yellow); glControl = new OpenTK.GLControl(new OpenTK.Graphics.GraphicsMode(32, 24, 8, 4)); glControl.Load += glControl_Load; glControl.Paint += glControl_Paint; glHost.Child = glControl; renderTimeMeasurer = Stopwatch.StartNew(); sourceEditTimer = new SourceEditTimer(RecompilationDelayMillis); compilers = new EffectCompilers(); targetLanguage = ShadingLanguages.GLSL; }
public bool HasErrors(ShadingLanguages targetLanguage) { return(compilers[(int)targetLanguage].HasErrors()); }
public IEffect Compile(ShadingLanguages targetLanguage, string vertexSource, string fragmentSource) { return(compilers[(int)targetLanguage].Compile(vertexSource, fragmentSource)); }