aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/libpostproc/postprocess_internal.h
diff options
context:
space:
mode:
authorJindřich Makovička <makovick@gmail.com>2005-02-27 08:56:26 +0000
committerJindřich Makovička <makovick@gmail.com>2005-02-27 08:56:26 +0000
commit655f688d54ab2a4160eafb26522c0d5f2791ca70 (patch)
treee7ff19ff8378e8d1fcaa95a6a2af7a262c8d709d /libavcodec/libpostproc/postprocess_internal.h
parentc80d990fa91cb969286d66299d8f76e975a90d8e (diff)
downloadffmpeg-655f688d54ab2a4160eafb26522c0d5f2791ca70.tar.gz
support for negative strides
Originally committed as revision 3989 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/libpostproc/postprocess_internal.h')
-rw-r--r--libavcodec/libpostproc/postprocess_internal.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/libavcodec/libpostproc/postprocess_internal.h b/libavcodec/libpostproc/postprocess_internal.h
index 3d6728e2aa..01d4679adb 100644
--- a/libavcodec/libpostproc/postprocess_internal.h
+++ b/libavcodec/libpostproc/postprocess_internal.h
@@ -160,3 +160,11 @@ typedef struct PPContext{
} PPContext;
+static inline void linecpy(void *dest, void *src, int lines, int stride)
+{
+ if (stride > 0) {
+ memcpy(dest, src, lines*stride);
+ } else {
+ memcpy(dest+(lines-1)*stride, src+(lines-1)*stride, -lines*stride);
+ }
+}