using Godot;
using System.Reflection;
using System.Collections.Generic;

namespace Rokojori
{ 
  public class ShaderCodeImports
  {
    public string importPath;
  }

  public class ShaderCodeVariable
  {
    public string variableName;
  }

  public class ShaderCode
  {    
    public string variantName = "";
    public List<ShaderCodeImports> imports = [];
    public List<ShaderCodeVariable> variables = [];

    protected virtual string _GetCode( ShaderGenerationContext context )
    {
      return "";
    } 

    public string GetCode( ShaderGenerationContext context )
    {
      return _GetCode( context );
    }


  }

  public class StringShaderCode:ShaderCode
  {
    public string code = "";

    public StringShaderCode( string code )
    {
      this.code = code;
    }
    
    protected override string _GetCode( ShaderGenerationContext context )
    {
      return code;
    } 
  }

}