<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><base href="https://e.mail.ru/" target="_self"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
p.msonormalmailrucssattributepostfix, li.msonormalmailrucssattributepostfix, div.msonormalmailrucssattributepostfix
        {mso-style-name:msonormal_mailru_css_attribute_postfix;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.tgcmailrucssattributepostfix
        {mso-style-name:tgc_mailru_css_attribute_postfix;}
p.msonormalmailrucssattributepostfixmailrucssattributepostfix, li.msonormalmailrucssattributepostfixmailrucssattributepostfix, div.msonormalmailrucssattributepostfixmailrucssattributepostfix
        {mso-style-name:msonormalmailrucssattributepostfix_mailru_css_attribute_postfix;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.pl-c1mailrucssattributepostfixmailrucssattributepostfixmailrucssattributepostfix
        {mso-style-name:pl-c1mailrucssattributepostfixmailrucssattributepostfix_mailru_css_attribute_postfix;}
span.E-mailStijl24
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=NL link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='mso-fareast-language:EN-US'>The packet you get, is raw stream data. If you want to decode it, you have to send the packet tot he decoder, and then receive back pcm frames from it. However, you don’t want to do that, as you want to use the hardware to decode, not ffmpeg. So this is why it’s kind of useless to put ffmpeg in it, as you want to do everything ffmpeg does, in hardware.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>I’d consider using one of the multiple available rtp libs, like this one:<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><a href="http://research.edm.uhasselt.be/jori/page/CS/Jrtplib.html">http://research.edm.uhasselt.be/jori/page/CS/Jrtplib.html</a><o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>to receive the stream, and then the mpp software to do the decoding/encoding and so forth.  FFMpeg would be bloated and overly complicated as ‘just an rtp receiver’.<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>Regards,<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'>Henri Zikken<o:p></o:p></span></p><p class=MsoNormal><span style='mso-fareast-language:EN-US'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b>Van:</b> Libav-user <libav-user-bounces@ffmpeg.org> <b>Namens </b>Anton Prikazchikov<br><b>Verzonden:</b> woensdag 11 april 2018 13:05<br><b>Aan:</b> "This list is about using libavcodec, libavformat, libavutil,libavdevice and libavfilter." <libav-user@ffmpeg.org><br><b>Onderwerp:</b> Re: [Libav-user] How to use rkmpp decoder?<o:p></o:p></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal style='margin-bottom:12.0pt'>I need an avpacket because i read rtcp stream using by ffmpeg and receive from the rtcp stream an avpacket. Mpp can't read rtcp stream as i know.<br><br>Also I saw that ffmpeg have "--enable-rkmpp" flag a<span lang=EN>t the configuration stage. And if I'm not mistaken this flag have to enable decoding using by rkmpp, but I can't run it... What must this flag do?</span><br><br><span style='mso-fareast-language:EN-US'>>Basically the packet->data is just the raw data. You can just pass this on to your mpp packet as the buffer. Packet->size gives you the size.<br>I tried to add the received packet->data to mpppacket, but it doesn't work. Also i want to clarify d</span><span lang=EN style='mso-fareast-language:EN-US'>oes the packet->data accurately contain unmodified H264 data?(I receive H264 data stream)</span><o:p></o:p></p><blockquote style='border:none;border-left:solid #0857A6 1.0pt;padding:0cm 0cm 0cm 8.0pt;margin-left:7.5pt;margin-top:7.5pt;margin-right:7.5pt;margin-bottom:7.5pt'><p class=MsoNormal style='margin-bottom:12.0pt'>Вторник, 10 апреля 2018, 21:16 +04:00 от Henri Zikken <<a href="mailto:zikken@xs4all.nl">zikken@xs4all.nl</a>>:<o:p></o:p></p><div id=""><div><div><div id="style_15233805730000000783_BODY"><div><div><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>I don’t see why you would want an avpacket in the first place, then. As ffmpeg won’t do the decoding, why bother with ffmpeg?</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Basically the packet->data is just the raw data. You can just pass this on to your mpp packet as the buffer. Packet->size gives you the size.</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Regards,</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Henri Zikken</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=msonormalmailrucssattributepostfix><b>Van:</b> Libav-user <<a href="mailto:libav-user-bounces@ffmpeg.org">libav-user-bounces@ffmpeg.org</a>> <b>Namens </b>Anton Prikazchikov<br><b>Verzonden:</b> dinsdag 10 april 2018 08:34<br><b>Aan:</b> "This list is about using libavcodec, libavformat, libavutil,libavdevice and libavfilter." <<a href="mailto:libav-user@ffmpeg.org">libav-user@ffmpeg.org</a>><br><b>Onderwerp:</b> Re: [Libav-user] How to use rkmpp decoder?<o:p></o:p></p></div></div><p class=msonormalmailrucssattributepostfix> <o:p></o:p></p><p class=msonormalmailrucssattributepostfix>My purpose is decoding a received from RTCP stream h264 AVPacket-s to AVFrame-s using by hardware of rk3399 (Rockchip RK3399 is a processor for computing(aarch64, Rockchip platform))<br><br>I found that rk3399 has mpp. Media Process Platform(mpp) is the video codec parser and <span class=tgcmailrucssattributepostfix>Hardware Abstraction Layer library for the Rockchip platforms.</span><br><span class=tgcmailrucssattributepostfix>Mpp provides C API for decoding h264 video files using by hardware of Rockchip platform.</span><br><br>And now i am thinking that the problem is converting from AVPacket(contain H264 data from RTCP stream) to MppPacket(this packet i will send to hardware decoder)<br><br>Thanks,<br>Anton Prikazchikov<o:p></o:p></p><blockquote style='border:none;border-left:solid #0857A6 1.0pt;padding:0cm 0cm 0cm 8.0pt;margin-left:7.5pt;margin-top:7.5pt;margin-right:7.5pt;margin-bottom:7.5pt'><p class=msonormalmailrucssattributepostfix style='margin-bottom:12.0pt'>Понедельник, 9 апреля 2018, 20:06 +04:00 от Henri Zikken <<a href="file://e.mail.ru/compose/%3fmailto=mailto%253azikken@xs4all.nl" target="_blank">zikken@xs4all.nl</a>>:<o:p></o:p></p><div id=""><div><div><div id="style_15232899660000000175_BODY_mailru_css_attribute_postfix"><div><div><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Ok, the rk339 is soms sort of computer. You are receiving a stream on that computer. Now you wish to decode that stream.</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>What is your purpose? What do you mean by decoding a stream? What has MPP got to do witht his all?</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Ffmpeg can decode H264. See the docs for a full example of this:</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'><a href="https://ffmpeg.org/doxygen/trunk/decoding__encoding_8c-source.html" target="_blank">https://ffmpeg.org/doxygen/trunk/decoding__encoding_8c-source.html</a></span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>You need more than just including .h files. The .h files can be seen as ‘descriptions of stuff to be found somewhere else’. So having the .h files might make it compile, but then it won’t link or won’t run due to missing files.</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>You need the compiled .so, .a or .dll files. So you need to compile ffmpeg yourself, or find the binaries suitable for your system.</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Regards,</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'>Henri Zikken</span><o:p></o:p></p><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><span style='mso-fareast-language:EN-US'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix><b>Van:</b> Libav-user <<a href="file://e.mail.ru/compose/%3fmailto=mailto%253alibav%252duser%252dbounces@ffmpeg.org" target="_blank">libav-user-bounces@ffmpeg.org</a>> <b>Namens </b>Anton Prikazchikov<br><b>Verzonden:</b> maandag 9 april 2018 16:27<br><b>Aan:</b> <a href="file://e.mail.ru/compose/%3fmailto=mailto%253alibav%252duser@ffmpeg.org" target="_blank">libav-user@ffmpeg.org</a><br><b>Onderwerp:</b> [Libav-user] How to use rkmpp decoder?<o:p></o:p></p></div></div><p class=msonormalmailrucssattributepostfixmailrucssattributepostfix> <o:p></o:p></p><div><div><div id="style_15232839560000000369_BODY_mailru_css_attribute_postfix_mailru_css_attribute_postfix"><div><p>Hello,<br><br>I have rk3399 and installed mpp(<a href="https://github.com/rockchip-linux/mpp" target="_blank">https://github.com/rockchip-linux/mpp</a>).<br><br>I am receiving rtsp stream using by ffmpeg(C++).<br>And now I have to decode h264 video using by mpp but I don't understand how to do this. <br><br>I found <a href="https://github.com/FFmpeg/FFmpeg/blob/master/libavcodec/rkmppdec.c" target="_blank">https://github.com/FFmpeg/FFmpeg/blob/master/libavcodec/rkmppdec.c</a>  and try to use this code for decoding.<o:p></o:p></p><p>I stopped on the code line below:<o:p></o:p></p><p>ret = <span class=pl-c1mailrucssattributepostfixmailrucssattributepostfixmailrucssattributepostfix>ff_decode_get_packet</span>(avctx, &pkt);<br><br>This function requires .h files from ffmpeg which i have not in my compiled version. Could someone prompt can I add some flags at configuration stage for .h files or somthing else?(I don't want take these files from github src)<br><br>Or maybe is there a better way for h264 decoding using by hw?<br><br>Thanks,<br>Anton Prikazchikov<o:p></o:p></p></div></div></div></div></div></div></div><div><p class=msonormalmailrucssattributepostfix>_______________________________________________<br>Libav-user mailing list<br><a href="file://e.mail.ru/compose/%3fmailto=mailto%253aLibav%252duser@ffmpeg.org" target="_blank">Libav-user@ffmpeg.org</a><br><a href="http://ffmpeg.org/mailman/listinfo/libav-user" target="_blank">http://ffmpeg.org/mailman/listinfo/libav-user</a><o:p></o:p></p></div></div></div></div></blockquote><p class=msonormalmailrucssattributepostfix> <o:p></o:p></p></div></div></div><div><p class=MsoNormal>_______________________________________________<br>Libav-user mailing list<br><a href="mailto:Libav-user@ffmpeg.org">Libav-user@ffmpeg.org</a><br><a href="http://ffmpeg.org/mailman/listinfo/libav-user" target="_blank">http://ffmpeg.org/mailman/listinfo/libav-user</a><o:p></o:p></p></div></div></div></div></blockquote><p class=MsoNormal><br><br>С Уважением,<br>Приказчиков Антон<o:p></o:p></p></div></body></html>