[mpp_frame]: Add metadata check function

Change-Id: I95f722ae95b8db969c484b3157ddbe8c8f92a13f
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
This commit is contained in:
Herman Chen
2020-07-22 10:21:41 +08:00
parent ca93b9f3b5
commit 31e911d44b
2 changed files with 11 additions and 0 deletions

View File

@@ -302,6 +302,7 @@ void mpp_frame_set_buffer(MppFrame frame, MppBuffer buffer);
/*
* meta data parameter
*/
RK_S32 mpp_frame_has_meta(const MppFrame frame);
MppMeta mpp_frame_get_meta(const MppFrame frame);
void mpp_frame_set_meta(MppFrame frame, MppMeta meta);

View File

@@ -124,6 +124,16 @@ void mpp_frame_set_buffer(MppFrame frame, MppBuffer buffer)
}
}
RK_S32 mpp_frame_has_meta(const MppFrame frame)
{
if (check_is_mpp_frame(frame))
return 0;
MppFrameImpl *p = (MppFrameImpl *)frame;
return (NULL != p->meta);
}
MppMeta mpp_frame_get_meta(MppFrame frame)
{
if (check_is_mpp_frame(frame))