aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/ffmpeg-0.9/libavutil
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/ffmpeg-0.9/libavutil')
-rw-r--r--src/lib/ffmpeg-0.9/libavutil/log.pas (renamed from src/lib/ffmpeg-0.9/libavutil/log1.pas)109
-rw-r--r--src/lib/ffmpeg-0.9/libavutil/log2.pas138
-rw-r--r--src/lib/ffmpeg-0.9/libavutil/opt1.pas (renamed from src/lib/ffmpeg-0.9/libavutil/opt.pas)84
-rw-r--r--src/lib/ffmpeg-0.9/libavutil/opt2.pas83
4 files changed, 192 insertions, 222 deletions
diff --git a/src/lib/ffmpeg-0.9/libavutil/log1.pas b/src/lib/ffmpeg-0.9/libavutil/log.pas
index b60d6731..630d2838 100644
--- a/src/lib/ffmpeg-0.9/libavutil/log1.pas
+++ b/src/lib/ffmpeg-0.9/libavutil/log.pas
@@ -201,3 +201,112 @@ const
procedure av_log_set_flags(arg: cint);
cdecl; external av__util;
+
+const
+ AV_LOG_QUIET = -8;
+
+(**
+ * Something went really wrong and we will crash now.
+ *)
+ AV_LOG_PANIC = 0;
+
+(**
+ * Something went wrong and recovery is not possible.
+ * For example, no header was found for a format which depends
+ * on headers or an illegal combination of parameters is used.
+ *)
+ AV_LOG_FATAL = 8;
+
+(**
+ * Something went wrong and cannot losslessly be recovered.
+ * However, not all future data is affected.
+ *)
+ AV_LOG_ERROR = 16;
+
+(**
+ * Something somehow does not look correct. This may or may not
+ * lead to problems. An example would be the use of '-vstrict -2'.
+ *)
+ AV_LOG_WARNING = 24;
+
+ AV_LOG_INFO = 32;
+ AV_LOG_VERBOSE = 40;
+
+(**
+ * Stuff which is only useful for libav* developers.
+ *)
+ AV_LOG_DEBUG = 48;
+
+(**
+ * Send the specified message to the log if the level is less than or equal
+ * to the current av_log_level. By default, all logging messages are sent to
+ * stderr. This behavior can be altered by setting a different av_vlog callback
+ * function.
+ *
+ * @param avcl A pointer to an arbitrary struct of which the first field is a
+ * pointer to an AVClass struct.
+ * @param level The importance level of the message, lower values signifying
+ * higher importance.
+ * @param fmt The format string (printf-compatible) that specifies how
+ * subsequent arguments are converted to output.
+ * @see av_vlog
+ *)
+
+{** to be translated if needed
+void av_log(void *avcl, int level, const char *fmt, ...) av_printf_format(3, 4);
+**}
+
+type
+ va_list = pointer;
+
+procedure av_vlog(avcl: pointer; level: cint; fmt: {const} PAnsiChar; dummy: va_list);
+ cdecl; external av__util;
+function av_log_get_level(): cint;
+ cdecl; external av__util;
+procedure av_log_set_level(level: cint);
+ cdecl; external av__util;
+
+{** to be translated if needed
+void av_log_set_callback(void (*)(void*, int, const char*, va_list));
+void av_log_default_callback(void* ptr, int level, const char* fmt, va_list vl);
+**}
+
+function av_default_item_name (ctx: pointer): PAnsiChar;
+ cdecl; external av__util;
+
+(**
+ * Format a line of log the same way as the default callback.
+ * @param line buffer to receive the formated line
+ * @param line_size size of the buffer
+ * @param print_prefix used to store whether the prefix must be printed;
+ * must point to a persistent integer initially set to 1
+ *)
+procedure av_log_format_line(ptr: pointer; level: cint; fmt: {const} PAnsiChar; vl: va_list;
+ line: PAnsiChar; line_size: cint; print_prefix: Pcint);
+ cdecl; external av__util;
+
+(**
+ * av_dlog macros
+ * Useful to print debug messages that shouldn't get compiled in normally.
+ *)
+(** to be translated if needed
+#ifdef DEBUG
+# define av_dlog(pctx, ...) av_log(pctx, AV_LOG_DEBUG, __VA_ARGS__)
+#else
+# define av_dlog(pctx, ...) do { if (0) av_log(pctx, AV_LOG_DEBUG, __VA_ARGS__); } while (0)
+#endif
+**)
+
+(**
+ * Skip repeated messages, this requires the user app to use av_log() instead of
+ * (f)printf as the 2 would otherwise interfere and lead to
+ * "Last message repeated x times" messages below (f)printf messages with some
+ * bad luck.
+ * Also to receive the last, "last repeated" line if any, the user app must
+ * call av_log(NULL, AV_LOG_QUIET, "%s", ""); at the end
+ *)
+const
+ AV_LOG_SKIP_REPEATED = 1;
+
+procedure av_log_set_flags(arg: cint);
+ cdecl; external av__util;
diff --git a/src/lib/ffmpeg-0.9/libavutil/log2.pas b/src/lib/ffmpeg-0.9/libavutil/log2.pas
deleted file mode 100644
index 6ca978f3..00000000
--- a/src/lib/ffmpeg-0.9/libavutil/log2.pas
+++ /dev/null
@@ -1,138 +0,0 @@
-(*
- * This file is part of FFmpeg.
- *
- * FFmpeg is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * FFmpeg is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with FFmpeg; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- * This is a part of the Pascal port of ffmpeg.
- * - Changes and updates by the UltraStar Deluxe Team
- *
- * Conversion of libavutil/log.h
- * avutil version 51.32.0
- *
- *)
-
-(**
- * @file
- * log
- *)
-
-const
- AV_LOG_QUIET = -8;
-
-(**
- * Something went really wrong and we will crash now.
- *)
- AV_LOG_PANIC = 0;
-
-(**
- * Something went wrong and recovery is not possible.
- * For example, no header was found for a format which depends
- * on headers or an illegal combination of parameters is used.
- *)
- AV_LOG_FATAL = 8;
-
-(**
- * Something went wrong and cannot losslessly be recovered.
- * However, not all future data is affected.
- *)
- AV_LOG_ERROR = 16;
-
-(**
- * Something somehow does not look correct. This may or may not
- * lead to problems. An example would be the use of '-vstrict -2'.
- *)
- AV_LOG_WARNING = 24;
-
- AV_LOG_INFO = 32;
- AV_LOG_VERBOSE = 40;
-
-(**
- * Stuff which is only useful for libav* developers.
- *)
- AV_LOG_DEBUG = 48;
-
-(**
- * Send the specified message to the log if the level is less than or equal
- * to the current av_log_level. By default, all logging messages are sent to
- * stderr. This behavior can be altered by setting a different av_vlog callback
- * function.
- *
- * @param avcl A pointer to an arbitrary struct of which the first field is a
- * pointer to an AVClass struct.
- * @param level The importance level of the message, lower values signifying
- * higher importance.
- * @param fmt The format string (printf-compatible) that specifies how
- * subsequent arguments are converted to output.
- * @see av_vlog
- *)
-
-{** to be translated if needed
-void av_log(void *avcl, int level, const char *fmt, ...) av_printf_format(3, 4);
-**}
-
-type
- va_list = pointer;
-
-procedure av_vlog(avcl: pointer; level: cint; fmt: {const} PAnsiChar; dummy: va_list);
- cdecl; external av__util;
-function av_log_get_level(): cint;
- cdecl; external av__util;
-procedure av_log_set_level(level: cint);
- cdecl; external av__util;
-
-{** to be translated if needed
-void av_log_set_callback(void (*)(void*, int, const char*, va_list));
-void av_log_default_callback(void* ptr, int level, const char* fmt, va_list vl);
-**}
-
-function av_default_item_name (ctx: pointer): PAnsiChar;
- cdecl; external av__util;
-
-(**
- * Format a line of log the same way as the default callback.
- * @param line buffer to receive the formated line
- * @param line_size size of the buffer
- * @param print_prefix used to store whether the prefix must be printed;
- * must point to a persistent integer initially set to 1
- *)
-procedure av_log_format_line(ptr: pointer; level: cint; fmt: {const} PAnsiChar; vl: va_list;
- line: PAnsiChar; line_size: cint; print_prefix: Pcint);
- cdecl; external av__util;
-
-(**
- * av_dlog macros
- * Useful to print debug messages that shouldn't get compiled in normally.
- *)
-(** to be translated if needed
-#ifdef DEBUG
-# define av_dlog(pctx, ...) av_log(pctx, AV_LOG_DEBUG, __VA_ARGS__)
-#else
-# define av_dlog(pctx, ...) do { if (0) av_log(pctx, AV_LOG_DEBUG, __VA_ARGS__); } while (0)
-#endif
-**)
-
-(**
- * Skip repeated messages, this requires the user app to use av_log() instead of
- * (f)printf as the 2 would otherwise interfere and lead to
- * "Last message repeated x times" messages below (f)printf messages with some
- * bad luck.
- * Also to receive the last, "last repeated" line if any, the user app must
- * call av_log(NULL, AV_LOG_QUIET, "%s", ""); at the end
- *)
-const
- AV_LOG_SKIP_REPEATED = 1;
-
-procedure av_log_set_flags(arg: cint);
- cdecl; external av__util;
diff --git a/src/lib/ffmpeg-0.9/libavutil/opt.pas b/src/lib/ffmpeg-0.9/libavutil/opt1.pas
index ce45ec0c..4b03b916 100644
--- a/src/lib/ffmpeg-0.9/libavutil/opt.pas
+++ b/src/lib/ffmpeg-0.9/libavutil/opt1.pas
@@ -543,87 +543,3 @@ function av_opt_next(obj: pointer; prev: {const} PAVOption): {const} PAVOption;
*)
function av_opt_child_next(obj: pointer; prev: pointer): pointer;
cdecl; external av__util;
-
-(**
- * Iterate over potential AVOptions-enabled children of parent.
- *
- * @param prev result of a previous call to this function or NULL
- * @return AVClass corresponding to next potential child or NULL
- *)
-function av_opt_child_class_next(parent: {const} PAVClass; prev: {const} PAVClass): {const} PAVClass;
- cdecl; external av__util;
-
-(**
- * @defgroup opt_set_funcs Option setting functions
- * @{
- * Those functions set the field of obj with the given name to value.
- *
- * @param[in] obj A struct whose first element is a pointer to an AVClass.
- * @param[in] name the name of the field to set
- * @param[in] val The value to set. In case of av_opt_set() if the field is not
- * of a string type, then the given string is parsed.
- * SI postfixes and some named scalars are supported.
- * If the field is of a numeric type, it has to be a numeric or named
- * scalar. Behavior with more than one scalar and +- infix operators
- * is undefined.
- * If the field is of a flags type, it has to be a sequence of numeric
- * scalars or named flags separated by '+' or '-'. Prefixing a flag
- * with '+' causes it to be set without affecting the other flags;
- * similarly, '-' unsets a flag.
- * @param search_flags flags passed to av_opt_find2. I.e. if AV_OPT_SEARCH_CHILDREN
- * is passed here, then the option may be set on a child of obj.
- *
- * @return 0 if the value has been set, or an AVERROR code in case of
- * error:
- * AVERROR_OPTION_NOT_FOUND if no matching option exists
- * AVERROR(ERANGE) if the value is out of range
- * AVERROR(EINVAL) if the value is not valid
- *)
-function av_opt_set (obj: pointer; name: {const} PAnsiChar; val: {const} PAnsiChar; search_flags: cint): cint;
- cdecl; external av__util;
-function av_opt_set_int (obj: pointer; name: {const} PAnsiChar; val: cint64; search_flags: cint): cint;
- cdecl; external av__util;
-function av_opt_set_double(obj: pointer; name: {const} PAnsiChar; val: cdouble; search_flags: cint): cint;
- cdecl; external av__util;
-function av_opt_set_q (obj: pointer; name: {const} PAnsiChar; val: TAVRational; search_flags: cint): cint;
- cdecl; external av__util;
-(**
- * @}
- *)
-
-(**
- * @defgroup opt_get_funcs Option getting functions
- * @{
- * Those functions get a value of the option with the given name from an object.
- *
- * @param[in] obj a struct whose first element is a pointer to an AVClass.
- * @param[in] name name of the option to get.
- * @param[in] search_flags flags passed to av_opt_find2. I.e. if AV_OPT_SEARCH_CHILDREN
- * is passed here, then the option may be found in a child of obj.
- * @param[out] out_val value of the option will be written here
- * @return 0 on success, a negative error code otherwise
- *)
-(**
- * @note the returned string will av_malloc()ed and must be av_free()ed by the caller
- *)
-function av_opt_get (obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: ^Pcuint8): cint;
- cdecl; external av__util;
-function av_opt_get_int (obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: Pcint64): cint;
- cdecl; external av__util;
-function av_opt_get_double(obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: Pcdouble): cint;
- cdecl; external av__util;
-function av_opt_get_q (obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: PAVRational): cint;
- cdecl; external av__util;
-(**
- * @}
- *)
-(**
- * Gets a pointer to the requested field in a struct.
- * This function allows accessing a struct even when its fields are moved or
- * renamed since the application making the access has been compiled,
- *
- * @returns a pointer to the field, it can be cast to the correct type and read
- * or written to.
- *)
-function av_opt_ptr(avclass: {const} PAVClass; obj: pointer; name: {const} PAnsiChar): pointer;
- cdecl; external av__util;
diff --git a/src/lib/ffmpeg-0.9/libavutil/opt2.pas b/src/lib/ffmpeg-0.9/libavutil/opt2.pas
new file mode 100644
index 00000000..dcc240c5
--- /dev/null
+++ b/src/lib/ffmpeg-0.9/libavutil/opt2.pas
@@ -0,0 +1,83 @@
+(**
+ * Iterate over potential AVOptions-enabled children of parent.
+ *
+ * @param prev result of a previous call to this function or NULL
+ * @return AVClass corresponding to next potential child or NULL
+ *)
+function av_opt_child_class_next(parent: {const} PAVClass; prev: {const} PAVClass): {const} PAVClass;
+ cdecl; external av__util;
+
+(**
+ * @defgroup opt_set_funcs Option setting functions
+ * @{
+ * Those functions set the field of obj with the given name to value.
+ *
+ * @param[in] obj A struct whose first element is a pointer to an AVClass.
+ * @param[in] name the name of the field to set
+ * @param[in] val The value to set. In case of av_opt_set() if the field is not
+ * of a string type, then the given string is parsed.
+ * SI postfixes and some named scalars are supported.
+ * If the field is of a numeric type, it has to be a numeric or named
+ * scalar. Behavior with more than one scalar and +- infix operators
+ * is undefined.
+ * If the field is of a flags type, it has to be a sequence of numeric
+ * scalars or named flags separated by '+' or '-'. Prefixing a flag
+ * with '+' causes it to be set without affecting the other flags;
+ * similarly, '-' unsets a flag.
+ * @param search_flags flags passed to av_opt_find2. I.e. if AV_OPT_SEARCH_CHILDREN
+ * is passed here, then the option may be set on a child of obj.
+ *
+ * @return 0 if the value has been set, or an AVERROR code in case of
+ * error:
+ * AVERROR_OPTION_NOT_FOUND if no matching option exists
+ * AVERROR(ERANGE) if the value is out of range
+ * AVERROR(EINVAL) if the value is not valid
+ *)
+function av_opt_set (obj: pointer; name: {const} PAnsiChar; val: {const} PAnsiChar; search_flags: cint): cint;
+ cdecl; external av__util;
+function av_opt_set_int (obj: pointer; name: {const} PAnsiChar; val: cint64; search_flags: cint): cint;
+ cdecl; external av__util;
+function av_opt_set_double(obj: pointer; name: {const} PAnsiChar; val: cdouble; search_flags: cint): cint;
+ cdecl; external av__util;
+function av_opt_set_q (obj: pointer; name: {const} PAnsiChar; val: TAVRational; search_flags: cint): cint;
+ cdecl; external av__util;
+(**
+ * @}
+ *)
+
+(**
+ * @defgroup opt_get_funcs Option getting functions
+ * @{
+ * Those functions get a value of the option with the given name from an object.
+ *
+ * @param[in] obj a struct whose first element is a pointer to an AVClass.
+ * @param[in] name name of the option to get.
+ * @param[in] search_flags flags passed to av_opt_find2. I.e. if AV_OPT_SEARCH_CHILDREN
+ * is passed here, then the option may be found in a child of obj.
+ * @param[out] out_val value of the option will be written here
+ * @return 0 on success, a negative error code otherwise
+ *)
+(**
+ * @note the returned string will av_malloc()ed and must be av_free()ed by the caller
+ *)
+function av_opt_get (obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: ^Pcuint8): cint;
+ cdecl; external av__util;
+function av_opt_get_int (obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: Pcint64): cint;
+ cdecl; external av__util;
+function av_opt_get_double(obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: Pcdouble): cint;
+ cdecl; external av__util;
+function av_opt_get_q (obj: pointer; name: {const} PAnsiChar; search_flags: cint; outval: PAVRational): cint;
+ cdecl; external av__util;
+(**
+ * @}
+ *)
+(**
+ * Gets a pointer to the requested field in a struct.
+ * This function allows accessing a struct even when its fields are moved or
+ * renamed since the application making the access has been compiled,
+ *
+ * @returns a pointer to the field, it can be cast to the correct type and read
+ * or written to.
+ *)
+function av_opt_ptr(avclass: {const} PAVClass; obj: pointer; name: {const} PAnsiChar): pointer;
+ cdecl; external av__util;