* common internal api header.
*/
-#ifndef FFMPEG_INTERNAL_H
-#define FFMPEG_INTERNAL_H
+#ifndef AVUTIL_INTERNAL_H
+#define AVUTIL_INTERNAL_H
#if !defined(DEBUG) && !defined(NDEBUG)
# define NDEBUG
#endif
#endif
-#ifndef M_PI
-#define M_PI 3.14159265358979323846
-#endif
-
#ifndef INT16_MIN
#define INT16_MIN (-0x7fff-1)
#endif
# define offsetof(T,F) ((unsigned int)((char *)&((T *)0)->F))
#endif
-#ifdef CONFIG_FASTMEMCPY
-# include "libvo/fastmemcpy.h"
-# define memcpy(a,b,c) fast_memcpy(a,b,c)
-#endif
-
// Use rip-relative addressing if compiling PIC code on x86-64.
#if defined(ARCH_X86_64) && defined(PIC)
# define LOCAL_MANGLE(a) #a "(%%rip)"
static inline av_const int FASTDIV(int a, int b)
{
int r;
- asm volatile("smmul %0, %1, %2" : "=r"(r) : "r"(a), "r"(ff_inverse[b]));
+ asm volatile("cmp %2, #0 \n\t"
+ "smmul %0, %1, %2 \n\t"
+ "rsblt %0, %0, #0 \n\t"
+ : "=r"(r) : "r"(a), "r"(ff_inverse[b]));
return r;
}
#elif defined(ARCH_ARMV4L)
#define strcat strcat_is_forbidden_due_to_security_issues_use_av_strlcat
#undef exit
#define exit exit_is_forbidden
-#if !(defined(LIBAVFORMAT_BUILD) || defined(FFMPEG_FRAMEHOOK_H))
+#ifndef LIBAVFORMAT_BUILD
#undef printf
#define printf please_use_av_log
#undef fprintf
}
#endif /* HAVE_ROUNDF */
-#endif /* FFMPEG_INTERNAL_H */
+#endif /* AVUTIL_INTERNAL_H */