0 votes
by (160 points)
recategorized by

1.Use PicoVRAndroidSDK_Native
2.putExtra("playTime", 0)
3.it's doesn't work, and I found the log like this:

2021-09-27 17:07:45.211 1022-9999/? E/ActivityManager: Sending non-protected broadcast PLAYTIME_CHANGED from system 11076:com.picovr.wing.videoplayer/1000 pkg com.picovr.wing.videoplayer
    at com.android.server.am.ActivityManagerService.checkBroadcastFromSystem(ActivityManagerService.java:19312)
    at com.android.server.am.ActivityManagerService.broadcastIntentLocked(ActivityManagerService.java:19917)
    at com.android.server.am.ActivityManagerService.broadcastIntent(ActivityManagerService.java:20059)
    at android.app.IActivityManager$Stub.onTransact(IActivityManager.java:240)
    at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java:2983)
    at android.os.Binder.execTransact(Binder.java:697)

1 Answer

0 votes
by (55.5k points)

Hello, may I ask what is the call method of your playtime parameter? Could you please share it? We can repeat your question.

by (160 points)
        val intent = Intent()
        intent.action ="picovr.intent.action.player"
        intent.putExtra("title", "filmTitle")
            .putExtra("uri", Uri.fromFile(File(videoFilePath)).toString())
            .putExtra("videoType", videoType.toString() + "")
            .putExtra("loop", false)
            .putExtra("isSinglePlayLoop", false)
            .putExtra("playTime", 0)
            .putExtra("canExit", true)
            .putExtra("isPlayEndAndClose", true)
by (160 points)

And PUI Version is 3.11.3 , device is G2 4K

by (55.5k points)

Hello, the playtime parameter is used to set the starting point of the video.
For example: if playtime is set to 40(putExtra("playTime", 40)), the video will start at 40.

We tested the Playtime parameters with the code you provided and it worked.

by (160 points)

Thanks, have you tried a few more times with the same video path, it's only works the first time.

by (55.5k points)

Hello, yes we tried many times. The device we tested was G2 4K, PUI versions are 3.11.5 and 4.0.5.
Maybe try upgrading the PUI to see if the code works continuously.

by (55.5k points)

Hello, we used your code and this is our test apk.
enter image description here
Test video need to more than 40 seconds and named test360.mp4. Test video storage path: /storage/emulated /0/Videos/test360.mp4. You can try it on your device.

If that doesn't work, maybe upgrading PUI to try again.

by (160 points)

OK, thanks for your answer .

I update the PUI to 4.0.5 and try it, but I just set the playTime to 0 second and it doesn't work, so your means that it must more than 40 seconds?

by (55.5k points)

No, we set the playTime to 40 seconds. If you use our test apk, the test video should be over 40 seconds so that it can start playing from 40 seconds. Maybe you can try to set the playTime to other value instead of 0.