Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. Qt 6
  4. How to decode H.264 streams to a Surface using NDK AMediaCodec in QML on the Android
Qt 6.11 is out! See what's new in the release blog

How to decode H.264 streams to a Surface using NDK AMediaCodec in QML on the Android

Scheduled Pinned Locked Moved Unsolved Qt 6
3 Posts 2 Posters 408 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Q Offline
    Q Offline
    qwqwqw2
    wrote last edited by
    #1

    https://github.com/KDAB/android/tree/master/examples/qtsurfacetexture
    This works properly in Qt5 but not in Qt6. I’ve spotted the androidsurfacetexture_p.h file in the Qt6 source code, yet I’m unsure how to apply it with a QQuickItem.

    I know MediaPlayer decodes directly to a Surface, but I’m receiving raw H.264 streams from RTSP, so MediaPlayer isn’t an option. That means I have to implement H.264 decoding manually with AMediaCodec.

    1 Reply Last reply
    0
    • Q Offline
      Q Offline
      qwqwqw2
      wrote last edited by
      #2

      Is there a way to make the background of ApplicationWindow transparent, allowing it to see through to the underlying Activity and display the SurfaceView I created within that Activity?

      JoeCFDJ 1 Reply Last reply
      0
      • Q qwqwqw2

        Is there a way to make the background of ApplicationWindow transparent, allowing it to see through to the underlying Activity and display the SurfaceView I created within that Activity?

        JoeCFDJ Offline
        JoeCFDJ Offline
        JoeCFD
        wrote last edited by
        #3

        @qwqwqw2 use gstreamer raw code for rendering rtsp streaming. NDK AMediaCode may not be needed. Media Player is not the right tool.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved