[vlc-devel] [PATCH 5/5] chroma: copy: remove CopyFromI420_10ToP010

Thomas Guillem thomas at gllm.fr
Fri Mar 9 19:15:34 CET 2018


---
 modules/video_chroma/copy.c | 41 -----------------------------------------
 modules/video_chroma/copy.h |  5 -----
 2 files changed, 46 deletions(-)

diff --git a/modules/video_chroma/copy.c b/modules/video_chroma/copy.c
index ef0fa9b9e6..653362cbbd 100644
--- a/modules/video_chroma/copy.c
+++ b/modules/video_chroma/copy.c
@@ -716,47 +716,6 @@ void Copy420_16_P_to_SP(picture_t *dst, const uint8_t *src[static 3],
     INTERLEAVE_UV();
 }
 
-void CopyFromI420_10ToP010(picture_t *dst, const uint8_t *src[static 3],
-                           const size_t src_pitch[static 3],
-                           unsigned height, const copy_cache_t *cache)
-{
-    (void) cache;
-
-    const int i_extra_pitch_dst_y = (dst->p[0].i_pitch  - src_pitch[0]) / 2;
-    const int i_extra_pitch_src_y = (src_pitch[Y_PLANE] - src_pitch[0]) / 2;
-    uint16_t *dstY = (uint16_t *) dst->p[0].p_pixels;
-    const uint16_t *srcY = (const uint16_t *) src[Y_PLANE];
-    for (unsigned y = 0; y < height; y++) {
-        for (unsigned x = 0; x < (src_pitch[0] / 2); x++) {
-            *dstY++ = *srcY++ << 6;
-        }
-        dstY += i_extra_pitch_dst_y;
-        srcY += i_extra_pitch_src_y;
-    }
-
-    const unsigned copy_lines = height / 2;
-    const unsigned copy_pitch = src_pitch[1] / 2;
-
-    const int i_extra_pitch_uv = dst->p[1].i_pitch / 2 - 2 * copy_pitch;
-    const int i_extra_pitch_u  = src_pitch[U_PLANE] / 2 - copy_pitch;
-    const int i_extra_pitch_v  = src_pitch[V_PLANE] / 2 - copy_pitch;
-
-    uint16_t *dstUV = (uint16_t *) dst->p[1].p_pixels;
-    const uint16_t *srcU  = (const uint16_t *) src[U_PLANE];
-    const uint16_t *srcV  = (const uint16_t *) src[V_PLANE];
-    for ( unsigned int line = 0; line < copy_lines; line++ )
-    {
-        for ( unsigned int col = 0; col < copy_pitch; col++ )
-        {
-            *dstUV++ = *srcU++ << 6;
-            *dstUV++ = *srcV++ << 6;
-        }
-        dstUV += i_extra_pitch_uv;
-        srcU  += i_extra_pitch_u;
-        srcV  += i_extra_pitch_v;
-    }
-}
-
 void Copy420_P_to_P(picture_t *dst, const uint8_t *src[static 3],
                     const size_t src_pitch[static 3], unsigned height,
                     const copy_cache_t *cache)
diff --git a/modules/video_chroma/copy.h b/modules/video_chroma/copy.h
index 296d1a6734..9b31551ecc 100644
--- a/modules/video_chroma/copy.h
+++ b/modules/video_chroma/copy.h
@@ -64,11 +64,6 @@ void Copy420_16_SP_to_P(picture_t *dst, const uint8_t *src[static 2],
                         const size_t src_pitch[static 2], unsigned height,
                         const copy_cache_t *cache);
 
-/* XXX: Not optimized copy (no SEE) */
-void CopyFromI420_10ToP010(picture_t *dst, const uint8_t *src[static 3],
-                           const size_t src_pitch[static 3],
-                           unsigned height, const copy_cache_t *cache);
-
 /**
  * This functions sets the internal plane pointers/dimensions for the given
  * buffer.
-- 
2.11.0



More information about the vlc-devel mailing list