summaryrefslogtreecommitdiffstats
path: root/postproc/swscale.h
diff options
context:
space:
mode:
authormichael <michael@b3059339-0415-0410-9bf9-f77b7e298cf2>2003-02-13 14:19:05 +0000
committermichael <michael@b3059339-0415-0410-9bf9-f77b7e298cf2>2003-02-13 14:19:05 +0000
commit04360970510aa1fb5ba3ec1914f216ae4bee7574 (patch)
tree4ec81ca61c53230ac22a55a9838cd7fb4896e9fe /postproc/swscale.h
parent7e94383861a80fa877381a59941b71f52ae6e8e5 (diff)
downloadmpv-04360970510aa1fb5ba3ec1914f216ae4bee7574.tar.bz2
mpv-04360970510aa1fb5ba3ec1914f216ae4bee7574.tar.xz
cleanup
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@9414 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'postproc/swscale.h')
-rw-r--r--postproc/swscale.h36
1 files changed, 33 insertions, 3 deletions
diff --git a/postproc/swscale.h b/postproc/swscale.h
index 54f8c71ba0..a03927cd57 100644
--- a/postproc/swscale.h
+++ b/postproc/swscale.h
@@ -44,6 +44,7 @@
#define SWS_FULL_CHR_H_INP 0x4000
#define SWS_DIRECT_BGR 0x8000
+#define MAX_FILTER_SIZE 256
#define SWS_MAX_REDUCE_CUTOFF 0.002
@@ -70,9 +71,6 @@ typedef struct SwsContext{
int16_t *vChrFilter;
int16_t *vChrFilterPos;
-// Contain simply the values from v(Lum|Chr)Filter just nicely packed for mmx
- int16_t *lumMmxFilter;
- int16_t *chrMmxFilter;
uint8_t formatConvBuffer[4000]; //FIXME dynamic alloc, but we have to change alot of code for this to be usefull
int hLumFilterSize;
@@ -105,8 +103,40 @@ typedef struct SwsContext{
void (*swScale)(struct SwsContext *context, uint8_t* src[], int srcStride[], int srcSliceY,
int srcSliceH, uint8_t* dst[], int dstStride[]);
+
+#define RED_DITHER "0*8"
+#define GREEN_DITHER "1*8"
+#define BLUE_DITHER "2*8"
+#define Y_COEFF "3*8"
+#define VR_COEFF "4*8"
+#define UB_COEFF "5*8"
+#define VG_COEFF "6*8"
+#define UG_COEFF "7*8"
+#define Y_OFFSET "8*8"
+#define U_OFFSET "9*8"
+#define V_OFFSET "10*8"
+#define LUM_MMX_FILTER_OFFSET "11*8"
+#define CHR_MMX_FILTER_OFFSET "11*8+4*4*256"
+
+ uint64_t redDither __attribute__((aligned(8)));
+ uint64_t greenDither __attribute__((aligned(8)));
+ uint64_t blueDither __attribute__((aligned(8)));
+
+ uint64_t yCoeff __attribute__((aligned(8)));
+ uint64_t vrCoeff __attribute__((aligned(8)));
+ uint64_t ubCoeff __attribute__((aligned(8)));
+ uint64_t vgCoeff __attribute__((aligned(8)));
+ uint64_t ugCoeff __attribute__((aligned(8)));
+ uint64_t yOffset __attribute__((aligned(8)));
+ uint64_t uOffset __attribute__((aligned(8)));
+ uint64_t vOffset __attribute__((aligned(8)));
+ int32_t lumMmxFilter[4*MAX_FILTER_SIZE];
+ int32_t chrMmxFilter[4*MAX_FILTER_SIZE];
+
} SwsContext;
//FIXME check init (where 0)
+//FIXME split private & public
+
// when used for filters they must have an odd number of elements
// coeffs cannot be shared between vectors