/// <summary> /// Get info of WepP image /// </summary> /// <param name="rawWebP">Bytes[] of webp image</param> /// <param name="data_size">Size of rawWebP</param> /// <param name="features">Features of WebP image</param> /// <returns>VP8StatusCode</returns> public static VP8StatusCode WebPGetFeatures(IntPtr rawWebP, int data_size, ref WebPBitstreamFeatures features) { switch (IntPtr.Size) { case 4: return(WebPGetFeaturesInternal_x86(rawWebP, (UIntPtr)data_size, ref features, WEBP_DECODER_ABI_VERSION)); case 8: return(WebPGetFeaturesInternal_x64(rawWebP, (UIntPtr)data_size, ref features, WEBP_DECODER_ABI_VERSION)); default: throw new InvalidOperationException("Invalid platform. Can not find proper function"); } }
private static extern VP8StatusCode WebPGetFeaturesInternal_x64([InAttribute()] IntPtr rawWebP, UIntPtr data_size, ref WebPBitstreamFeatures features, int WEBP_DECODER_ABI_VERSION);