PLANAR_YUV_FILL_COLOR (y41b, GST_VIDEO_FORMAT_Y41B, memset);
/* NV12, NV21 */
-#define NV_YUV_BLEND(format_name,first_component,MEMCPY,BLENDLOOP) \
+#define NV_YUV_BLEND(format_name,MEMCPY,BLENDLOOP) \
inline static void \
_blend_##format_name (const guint8 * src, guint8 * dest, \
gint src_stride, gint dest_stride, gint src_width, gint src_height, \
dest_comp_rowstride, src_comp_width, src_comp_height, \
src_alpha); \
\
- b_src = GST_VIDEO_FRAME_COMP_DATA (srcframe, first_component); \
- b_dest = GST_VIDEO_FRAME_COMP_DATA (destframe, first_component); \
+ b_src = GST_VIDEO_FRAME_PLANE_DATA (srcframe, 1); \
+ b_dest = GST_VIDEO_FRAME_PLANE_DATA (destframe, 1); \
src_comp_rowstride = GST_VIDEO_FRAME_COMP_STRIDE (srcframe, 1); \
dest_comp_rowstride = GST_VIDEO_FRAME_COMP_STRIDE (destframe, 1); \
src_comp_width = GST_VIDEO_FORMAT_INFO_SCALE_WIDTH(info, 1, b_src_width); \
src_alpha); \
}
-#define NV_YUV_FILL_CHECKER(format_name, first_component, MEMSET) \
+#define NV_YUV_FILL_CHECKER(format_name, MEMSET) \
static void \
fill_checker_##format_name (GstVideoFrame * frame) \
{ \
p += rowstride - comp_width; \
} \
\
- p = GST_VIDEO_FRAME_COMP_DATA (frame, first_component); \
+ p = GST_VIDEO_FRAME_PLANE_DATA (frame, 1); \
comp_width = GST_VIDEO_FRAME_COMP_WIDTH (frame, 1); \
comp_height = GST_VIDEO_FRAME_COMP_HEIGHT (frame, 1); \
rowstride = GST_VIDEO_FRAME_COMP_STRIDE (frame, 1); \
} \
}
-NV_YUV_BLEND (nv12, 1, memcpy, video_mixer_orc_blend_u8);
-NV_YUV_FILL_CHECKER (nv12, 1, memset);
+NV_YUV_BLEND (nv12, memcpy, video_mixer_orc_blend_u8);
+NV_YUV_FILL_CHECKER (nv12, memset);
NV_YUV_FILL_COLOR (nv12, memset);
-NV_YUV_BLEND (nv21, 2, memcpy, video_mixer_orc_blend_u8);
-NV_YUV_FILL_CHECKER (nv21, 2, memset);
+NV_YUV_BLEND (nv21, memcpy, video_mixer_orc_blend_u8);
+NV_YUV_FILL_CHECKER (nv21, memset);
/* RGB, BGR, xRGB, xBGR, RGBx, BGRx */