-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable video post processing after hw decoding #18
base: master
Are you sure you want to change the base?
Conversation
c21ffb1
to
4d97849
Compare
@dyang23 , @YuanjunHuang, could you please take a little time to have a review? Thanks! |
mfx_omx_defs.mk
Outdated
@@ -97,6 +97,9 @@ ifneq ($(filter $(MFX_ANDROID_VERSION), MFX_Q MFX_R),) | |||
MFX_OMX_CFLAGS += -DENABLE_READ_SEI | |||
endif | |||
|
|||
# Enable vpp for decoder | |||
MFX_OMX_CFLAGS += -DENABLE_DECVPP |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we disable this feature by default, I am afraid it may impact celadon performance, enable it if some product want it in product level?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, I will refine it and disable it by default. Thanks Dong. :)
mfx_res = MFX_ERR_MORE_SURFACE; | ||
} | ||
|
||
//ALOGI("%s, id = %d, returned %d", __func__, i, mfx_res); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this for debug, can we remove it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, will remove it.
m_MfxVideoParams.NumExtParam--; | ||
} | ||
MFX_OMX_LOG_INFO_IF(g_OmxLogLevel, "Decoder initialized with sts %d", mfx_res); | ||
ALOGI("%s. Decoder initialized with sts %d", __func__, mfx_res); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The LOGI() can be remove.
|
||
MFX_OMX_ZERO_MEMORY(m_vppParam); | ||
m_vppParam.AsyncDepth = 1; | ||
m_vppParam.IOPattern = MFX_IOPATTERN_IN_VIDEO_MEMORY | MFX_IOPATTERN_OUT_VIDEO_MEMORY; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The output buffer will be used by android framework/APP, I am not sure whether there is the case in which it will output system memory?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that should be considered. I will refine this PR.
Thanks,
mfxU32 i = 0; | ||
for (i = 0; i < DECODE_MAX_SRF_NUM; i++) | ||
{ | ||
if (false == m_DecInterSrf[i].Data.Locked) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The "Data.Locked" is a interger type but not a bool type, I suggest compare it with constant,or non-computing as (!m_DecInterSrf[i].Data.Locked)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will change it. :)
MFX_OMX_AUTO_TRACE_FUNC(); | ||
mfxStatus sts = MFX_ERR_NONE; | ||
mfxSyncPoint syncp; | ||
//ALOGI("%s, in_srf=%p, out_srf=%p", __func__, in_srf, out_srf); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
debug log?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, only for debug. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some comments inlined.
Thanks,
This patch adds the android 12 related build flags for MFX Tracked-On: OAM-100026 Signed-off-by: Tanuj Tekriwal <[email protected]>
This change is to enable video post processing after
hw decoding. The final output is 2X scaling of input.
Tracked-On:
Signed-off-by: Chen, Tianmi [email protected]