]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/mathops.h
tiff: support decoding GBRP and GBRAP formats
[ffmpeg] / libavcodec / mathops.h
index 218c459accf0a0d454f3b91339e53ba7a4d500e5..7af13e19e016918a6d6516b8b62b2f513f6e2b50 100644 (file)
 #include "libavutil/common.h"
 #include "config.h"
 
+#define MAX_NEG_CROP 1024
+
 extern const uint32_t ff_inverse[257];
+extern const uint8_t  ff_reverse[256];
 extern const uint8_t ff_sqrt_tab[256];
+extern const uint8_t ff_crop_tab[256 + 2 * MAX_NEG_CROP];
+extern const uint8_t ff_zigzag_direct[64];
 
 #if   ARCH_ARM
 #   include "arm/mathops.h"
@@ -214,4 +219,14 @@ static inline av_const unsigned int ff_sqrt(unsigned int a)
     return b - (a < b * b);
 }
 
+static inline int8_t ff_u8_to_s8(uint8_t a)
+{
+    union {
+        uint8_t u8;
+        int8_t  s8;
+    } b;
+    b.u8 = a;
+    return b.s8;
+}
+
 #endif /* AVCODEC_MATHOPS_H */