Beispiel #1
0
        static string _GetProperty(MToonMaterial mtoon, MaterialBindType bindType)
        {
            switch (bindType)
            {
            // case MaterialBindType.UvOffset:
            // case MaterialBindType.UvScale:
            //     return UV_PROPERTY;

            case MaterialBindType.Color:
                return(COLOR_PROPERTY);

            case MaterialBindType.EmissionColor:
                return(EMISSION_COLOR_PROPERTY);

            case MaterialBindType.ShadeColor:
                return(SHADE_COLOR_PROPERTY);

            case MaterialBindType.RimColor:
                return(RIM_COLOR_PROPERTY);

            case MaterialBindType.OutlineColor:
                return(OUTLINE_COLOR_PROPERTY);
            }

            throw new NotImplementedException();
        }
Beispiel #2
0
        static MaterialBindType _GetBindType(this MToonMaterial mtoon, string property)
        {
            switch (property)
            {
            // case UV_PROPERTY:
            //     return MaterialBindType.UvOffset;

            case COLOR_PROPERTY:
                return(MaterialBindType.Color);

            case EMISSION_COLOR_PROPERTY:
                return(MaterialBindType.EmissionColor);

            case RIM_COLOR_PROPERTY:
                return(MaterialBindType.RimColor);

            case SHADE_COLOR_PROPERTY:
                return(MaterialBindType.ShadeColor);

            case OUTLINE_COLOR_PROPERTY:
                return(MaterialBindType.OutlineColor);
            }

            throw new NotImplementedException();
        }