public string Convert(HLSLValue from, HLSLValue to, object value)
        {
            var pair = new HLSLValuePair
            {
                From = from.HLSLValueBaseType,
                To   = to.HLSLValueBaseType
            };

            if (CanConvert(pair))
            {
                var converter = converters[pair];
                return(converter.Convert(from.HLSLValueSubType, to.HLSLValueSubType, value));
            }

            return("");
        }
        public string Convert(HLSLResult input, HLSLValue target)
        {
            var pair = new HLSLValuePair
            {
                From = input.HLSLValueBaseType,
                To   = target.HLSLValueBaseType
            };

            if (CanConvert(pair))
            {
                var converter = converters[pair];
                return(converter.Convert(input.HLSLValueSubType, target.HLSLValueSubType, input.Value));
            }

            return("");
        }