- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is it possible to turn off fill outside crop region (MFXVideoVPP_RunFrameVPPAsync)?
Thanks.
- Tags:
- Development Tools
- Graphics
- Intel® Media SDK
- Intel® Media Server Studio
- Media Processing
- Optimization
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Nikolay,
You can try mfxExtVPPColorFill to disable the filling.
You can refer to following online document or the developer guide in the release package for the usage:
https://software.intel.com/sites/default/files/mediasdk-man.pdf
Let me know if you have more questions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you, Mark.
I have tried to use mfxExtVPPColorFill, but with no success (MFX_ERR_INVALID_VIDEO_PARAM on Init). Also, there is no sample showing how this extension works. Can you check is my code correct?
#define ALIGN_UP(value, alignment) ((alignment) * ((value) / (alignment) + (((value) % (alignment)) ? 1 : 0))) mfxInitParam initPar; MFXVideoSession session; mfxVideoParam VPPParams; mfxExtVPPColorFill extColorFill; MFXVideoVPP* pVPP = nullptr; uint32_t width = 640; uint32_t height = 480; int main() { mfxStatus mfxsts; memset(&(initPar), 0, sizeof(initPar)); initPar.Version.Major = 1; initPar.Version.Minor = 19; initPar.Implementation = MFX_IMPL_SOFTWARE; mfxsts = session.InitEx(initPar); if (MFX_ERR_NONE != mfxsts) return -1; pVPP = new (std::nothrow) MFXVideoVPP(session); if (nullptr == pVPP) return -2; memset(&VPPParams, 0, sizeof(VPPParams)); VPPParams.IOPattern = MFX_IOPATTERN_IN_SYSTEM_MEMORY | MFX_IOPATTERN_OUT_SYSTEM_MEMORY; mfxFrameInfo& vppInInfo = VPPParams.vpp.In; mfxFrameInfo& vppOutInfo = VPPParams.vpp.Out; vppInInfo.FourCC = MFX_FOURCC_NV12; vppInInfo.ChromaFormat = MFX_CHROMAFORMAT_YUV420; vppInInfo.CropX = 0; vppInInfo.CropY = 0; vppInInfo.CropW = width; vppInInfo.CropH = height; vppInInfo.PicStruct = MFX_PICSTRUCT_PROGRESSIVE; vppInInfo.FrameRateExtN = 30; vppInInfo.FrameRateExtD = 1; vppInInfo.Width = ALIGN_UP(vppInInfo.CropW, 32); vppInInfo.Height = ALIGN_UP(vppInInfo.CropH, 32); memcpy(&vppOutInfo, &vppInInfo, sizeof(mfxFrameInfo)); vppOutInfo.CropW /= 2; vppOutInfo.CropH /= 2; memset(&(extColorFill), 0, sizeof(extColorFill)); extColorFill.Header.BufferId = MFX_EXTBUFF_VPP_COLORFILL; extColorFill.Header.BufferSz = sizeof(mfxExtVPPColorFill); extColorFill.Enable = MFX_CODINGOPTION_OFF; mfxExtBuffer* ExtBuffer[1]; ExtBuffer[0] = (mfxExtBuffer*)&extColorFill; VPPParams.NumExtParam = 1; VPPParams.ExtParam = (mfxExtBuffer**)&ExtBuffer[0]; mfxsts = pVPP->Init(&VPPParams); .... }
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Nikolay,
Sorry for the late response, I was focusing on other project and didn't have chance to look at your question.
I did some research and found sample_vpp has an argument to disable color filling, so if you can run it with argument "-cf_disable" to see if it can turn off the color at the output.
If this can do what you expected, then I think your code has some error on how to handle the points when passed to mfxVideoParams through mfxExtBuffer. Yes, I agree it is not very straightforward, here are the clues you might look at it:
- How to initiate the parameters at this line.
- The colorfill request seems stuffed here.
- Assign the transfer to Media SDK at this line and this line.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you, Mark.
It seems, there are difference beetween github samples and samples from Media SDK 2018 R2_1 from this site.
One more question, is there support for Intel Atom x5-z8350 (Cheery Trail) in linux version of Intel Media SDK?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Nikolay,
Does my info help?
For your question, I don't think this processor has the hardware to support HW accelerated codec after check our web site https://ark.intel.com
Normally, if we have the hardware, Media SDK should support.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Mark,
I assumed that mfxExtVPPColorFill is linux-only feature, but I couldn't get HW acceleration works on my atom PC with linux OS.
Intel Atom x5-z8350 has hardware support on Windows up to ver.1.19, but it seems that linux proprietary driver is not implemented for Cheery Trail CPUs.
Nikolay
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Nikolay,
If you check ark.intel.com with Z8350, looking at "graphic" section, you should be expected to see "Quick Sync Video" item but it is not there. This means it doesn't support Intel hardware video acceleration.
Back to the older atom process, there was some version which has third party graphic which might support hardware codec but I can't tell if this is the case for cherry trail.
But since Media SDK support software codec, the video codec might still work in your case. For Linux, the driver should be in the kernel one way or other but since the chip doesn't have the hardware, it doesn't make sense.
Let me know if this answers your questions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, it looks like different from ark.intel.com.
So I think there are mistakes for one of the document versions, the best way to check is to actually install Media Server Studio and run our samples.
There is also other issue:
According to media driver document, we don't support Atom until ApolloLake, this might mean we don't validate on CherryTrail since it is a very old processor.
So chances are, if you can install Ubuntu 16.04 or later and then build Media SDK Open Source library and then run the samples.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you, Mark.
Nikolay
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page