diff options
author | michael <michael@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-01-21 03:56:47 +0000 |
---|---|---|
committer | michael <michael@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-01-21 03:56:47 +0000 |
commit | 1f2d4faa6d3c3c8a91e8eb4617bae936816cc833 (patch) | |
tree | 60b381823dd98be5ff98e09093e374f837297e49 /postproc/swscale_template.c | |
parent | 34da4c1e7f6ff38f5f74595b1383d7cd86e6e1aa (diff) | |
download | mpv-1f2d4faa6d3c3c8a91e8eb4617bae936816cc833.tar.bz2 mpv-1f2d4faa6d3c3c8a91e8eb4617bae936816cc833.tar.xz |
general convolution filtering of the source picture
dynamic memory allocation for the buffers (needed for the filter stuff)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@4291 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'postproc/swscale_template.c')
-rw-r--r-- | postproc/swscale_template.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/postproc/swscale_template.c b/postproc/swscale_template.c index b70806b1a1..7894b5d290 100644 --- a/postproc/swscale_template.c +++ b/postproc/swscale_template.c @@ -1935,13 +1935,10 @@ static void RENAME(swScale)(SwsContext *c, uint8_t* src[], int srcStride[], int const int lastLumSrcY= firstLumSrcY + vLumFilterSize -1; // Last line needed as input const int lastChrSrcY= firstChrSrcY + vChrFilterSize -1; // Last line needed as input - if(flags&SWS_FAST_BILINEAR) - { - //handle holes - if(firstLumSrcY > lastInLumBuf) lastInLumBuf= firstLumSrcY-1; - if(firstChrSrcY > lastInChrBuf) lastInChrBuf= firstChrSrcY-1; - } - + //handle holes (FAST_BILINEAR & weird filters) + if(firstLumSrcY > lastInLumBuf) lastInLumBuf= firstLumSrcY-1; + if(firstChrSrcY > lastInChrBuf) lastInChrBuf= firstChrSrcY-1; +//printf("%d %d %d\n", firstChrSrcY, lastInChrBuf, vChrBufSize); ASSERT(firstLumSrcY >= lastInLumBuf - vLumBufSize + 1) ASSERT(firstChrSrcY >= lastInChrBuf - vChrBufSize + 1) @@ -1953,6 +1950,7 @@ static void RENAME(swScale)(SwsContext *c, uint8_t* src[], int srcStride[], int { uint8_t *s= src[0]+(lastInLumBuf + 1 - srcSliceY)*srcStride[0]; lumBufIndex++; +// printf("%d %d %d %d\n", lumBufIndex, vLumBufSize, lastInLumBuf, lastLumSrcY); ASSERT(lumBufIndex < 2*vLumBufSize) ASSERT(lastInLumBuf + 1 - srcSliceY < srcSliceH) ASSERT(lastInLumBuf + 1 - srcSliceY >= 0) |