Output() static private method

static private Output ( CompilerOutputs output ) : string
output CompilerOutputs
return string
Exemplo n.º 1
0
        internal static string convertToBasicType(string type, CompilerOutputs outputType, bool convertVectorTypes)
        {
            switch (type)
            {
            case ("Void"): return("void");

            case ("Int32"): return("int");

            case ("UInt32"): return("uint");

            case ("Single"): return("float");

            case ("Double"): return("float");

            case ("Boolean"): return("bool");

            case ("Vector2"): return(convertVectorTypes ? Vector2.Output(outputType) : type);

            case ("Vector3"): return(convertVectorTypes ? Vector3.Output(outputType) : type);

            case ("Vector4"): return(convertVectorTypes ? Vector4.Output(outputType) : type);

            case ("Matrix3"): return(convertVectorTypes ? Matrix3.Output(outputType) : type);

            case ("Matrix4"): return(convertVectorTypes ? Matrix4.Output(outputType) : type);

            case ("Void[]"): return("void");

            case ("Int32[]"): return("int");

            case ("UInt32[]"): return("uint");

            case ("Single[]"): return("float");

            case ("Double[]"): return("float");

            case ("Boolean[]"): return("bool");

            case ("Vector2[]"): return(convertVectorTypes ? Vector2.Output(outputType) : type);

            case ("Vector3[]"): return(convertVectorTypes ? Vector3.Output(outputType) : type);

            case ("Vector4[]"): return(convertVectorTypes ? Vector4.Output(outputType) : type);

            case ("Matrix3[]"): return(convertVectorTypes ? Matrix3.Output(outputType) : type);

            case ("Matrix4[]"): return(convertVectorTypes ? Matrix4.Output(outputType) : type);

            case ("Texture2D"): return(convertVectorTypes ? Texture2D.Output(outputType) : type);

            default: return(type);
            }
        }