How to call my custom decoder in Android source code

I am trying to add my software HEVC decoder to Android source code. I want to create a libstagefright.so file .

I mentioned other similar issues and didn't really help me. I could not get a clear picture with the following questions or a reference guide.

1) Integration of Codec multimedia environment in Android.

2) Integration of a custom decoder for simultaneous playback on Android and display frames per second.

3) How to register the OMX core to add a new decoder.

Can someone please help me with the steps to integrate a new custom decoder with Android.

At the moment, I just added the media_codecs.xml { "OMX.google.h265.decoder" , "hevcdec" , "video_decoder.hevc" }file to the SoftOMXPlugin.cpp file as well.

What other files need to be edited for the new format that will be added to the Android source code? What functions do my decoder source code call (does the softomxcplugin source file output my decoder?).

+4
source share
1 answer

From your request and earlier discussions, please find the steps to integrate the component HEVCinto the infrastructure Android. Since your component is a component SW, you will need to integrate it with SoftVideoDecoderOMXComponent.

What is SoftVideoDecoderOMXComponent?

Android Stagefright SW OMX. , . , Google , SW SoftOMXComponent.

OMX IL , , , , .

AVC codec, . , OMX IL 1.1.2 , , OMX IL.

. HEVC OMX IL , , .

SoftHEVC

SoftAVC.h SoftAVC.cpp.

. AVC - .

SoftHEVC.cpp

  • SoftHEVC SoftHEVC.h, SoftVideoDecoderOMXComponent. , OMX .

  • profile - level , CodecProfileLevel.

  • constructor . , 2 , : input output. ctor a initDecoder . .

  • dtor , , .

  • onQueueFilled , input , , output . H264SwDecDecode. . , .

  • 2 handlePortSettingsChanged handleCropRectEvent. 2 . handlePortSettingsChanged , , . handleCropRectEvent , __cropping__, . .

  • drainOneOutputBuffer .

  • onQueueFilled .

  • , , .

  • createSoftOMXComponent, SoftHEVC, .

, . , , kComponents SoftOMXPlugin. , HEVC MIME, . MediaDefs.cpp , MEDIA_MIMETYPE_VIDEO_HEVC, , AVC, OMXCodec.cpp ACodec.cpp.

, SW .

+5

Source: https://habr.com/ru/post/1531345/


All Articles