How to Play Offline Videos

I Searched the Comunity and Couldnt find the block to set as source
the test works fine, the apk cant find the file, is there a way to do it without taifun file?

Try like this one:
/android/data/package_name/files/your file name
Or use taifun tools extension and join path to assets to file name

1 Like

thanks,
in package name what do i write?

Your app package name if you have used a custom package name.
You can also use Package component available in utilities category to get package name.

Still same problem, i will try the experimental extension
/android/data/io.kodular.icaroemanuelpl.ShakeMemesBrasil/files/CachorroEditado.mp4

You have to use full path.The path I have given is an example.
Use taiful tools extension and get path using pathtoassets block.

There is obviously a bug with the Video_Player component. The video player does not find / get the (right) path to the assets. In addition, READ_EXTERNAL_STORAGE permission is falsely requested even though the video file is played from the assets. Companion works. The other AI versions do not have this error.

To reproduce the error, here is a test aia: videoPlayerTest.aia (633.6 KB)

EDIT: I posted this bug on July 2019. Today is Oct 10, 2020 and the bug is still not fixed.
Can anyone add it to the → Bug tracker?

EDIT 2: Today is Dec 6, 2021 and the bug is still not fixed.

3 Likes

This would have been enough

But as @bodymindpower mentioned

@KodularCreator something to take a look at

/Boban

1 Like

When I create an app-specific folder and save the video to this folder, READ / WRITE permissions are requested (should not be like this). If I deny it, I get an error message Error 908: …) and the video is not played. Therefore the Video_Player component behaves differently than eg the Player component.

videoPlayerTest2.apk (4.8 MB)

you have the AIA code, I tried to find the video file everywhere and I can’t find

your answer is here

just write mobile.mp4 without anything
Taifun

in companion work, but in apk does not work. i used permission

it seems to be, you just confirmed that bug again?

to be sure, please prepare an example project as simple as possible and

  1. provide a screenshot of the blocks as well as
  2. upload the project (aia file) into this thread, so someone can check

Taifun

gif.aia (1.3 MB)

This post was flagged by the community and is temporarily hidden.

unfortunately this is not a project as simple as possible
but probably someone else is interested in taking a look…

Taifun

Try this: gif.apk (6.6 MB)

Blocks

2 Likes

Every path should work except the one from the assets (only with APK).
As I have mentioned often enough, this bug is still not fixed. → @Kodular

1 Like

Great job, I did it with webview and it works without needing Tainfu, now it’s easy to understand

I placed the block within the permission granted, if the video is initialized right at the start of the app. And also a time to load the video and initialize.

1 Like

great work

1 Like