Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. qt qml load assets from apk in android devices
Forum Updated to NodeBB v4.3 + New Features

qt qml load assets from apk in android devices

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
6 Posts 3 Posters 202 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.
  • J Offline
    J Offline
    jchaviano
    wrote last edited by
    #1

    I am making an apk for android devices the problem is that I manage to put the assets in the apk, that is to say open it with a winrar and see the files in the assets folder the thing is that I put a photo and a video but from mediaplayer I cannot load the video from the assets but the image perfectly. Do I have any way to load the assets to mediaplayer without having to copy to memory

    1 Reply Last reply
    0
    • J Offline
      J Offline
      jchaviano
      wrote last edited by jchaviano
      #2

      Untitled.png

      1 Reply Last reply
      0
      • J Offline
        J Offline
        jchaviano
        wrote last edited by
        #3

        I need a way to read videos from the Android APK's assets folder without having to copy them to the SD card or phone. If there are a few videos, they would take up storage space in both the app and the phone. When extracting the entire .media player file, Qt QML doesn't recognize the path assets:/videos/video.mp4.

        1 Reply Last reply
        0
        • JoeCFDJ Offline
          JoeCFDJ Offline
          JoeCFD
          wrote last edited by JoeCFD
          #4

          It looks like no permission is needed. assets:/videos/video.mp4 may not be the full path.

          1 Reply Last reply
          0
          • J Offline
            J Offline
            jchaviano
            wrote last edited by
            #5

            If I use image{source: "assets:/image1.jpg"} it works, but mediaplayer source:"assets:/video.mp4" does not

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote last edited by
              #6

              Hi,

              You should add which version of Qt you are using.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              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