Exemple #1
0
 public ShaderStage SetSourceCode(string Code)
 {
     Source      = Code;
     SrcFile     = null;
     WatchHandle = null;
     return(this);
 }
Exemple #2
0
 public ShaderStage SetSourceFile(string FilePath)
 {
     Source      = null;
     SrcFile     = Path.GetFullPath(FilePath);
     WatchHandle = FileWatcher.Watch(FilePath);
     return(this);
 }
Exemple #3
0
        public void UpdateIfChanged()
        {
            FileWatchHandle Handle = FileWatcher.Watch(FileName, true);

            if (Handle?.HasChanged ?? false)
            {
                Handle.Reset();

                Parse(Handle.FullFilePath);
            }
        }