internal ExifTagInfo(ExifTag tag, ExifTagFormat format = Ansi, int count = 1, string description = null) { Name = tag.ToString(); Code = (int)tag; Description = description; Converter = ExifValueConverter.Get(format); }
internal static ExifValueConverter Get(ExifTagFormat format) { switch (format) { case ExifTagFormat.Ansi: return(ExifValueConverter.Default); case ExifTagFormat.Boolean: return(BooleanConverter.Default); case ExifTagFormat.Short: return(ExifValueConverter.Default); case ExifTagFormat.Date: return(DateNormalizer.Default); case ExifTagFormat.Rational: return(UnsignedRationalConverter.Default); case ExifTagFormat.SRational: return(SignedRationalConverter.Default); default: return(ExifValueConverter.Default); } }
internal ExifTagInfo(string name, ExifTagFormat format = Ansi) : this(name, ExifValueConverter.Get(format)) { }