MobileMobile | Continue
       
Nibiru VR Development Other Tools Launching 3D videos in Android

Launching 3D videos in Android

caligari Post time 2017-5-11 15:33 | Show all posts [Copy URL]
1 665

I have a MP4 video showing pretty with Media Player and I am trying to lauch it from my own Android app. I have tried with ACTION_VIEW intent and video/mp4type, but the player is asking for video mode (3D,2D,180º,360º,...) in every execution

What is the right way to launch a 3D video from an Android app? Do the video files contain any special metatag or similar to say what 3D mode is?
Reply

Use magic Report

Post time 2017-5-11 15:33 | Show all posts
Hi,  your question is don't want to select video mode in every execution? We have special intent for start system video player.  But our player cannot identify the video mode from video file since there is no standard to define it. So you need to specific the video mode by yourself when use our intent API.

Note that the intent API needs system support, so if you cannot start the Intent, let me know the system version and version type.

The intent definition is:
Intent Name: com.nibiru.videostart
Parameters: PATH, TYPE_2DOR3D, TYPE_MODEL, TYPE_DECODE,
Value definition:

TYPE_2DOR3D:

PLAY_TYPE_2D = 0;
PLAY_TYPE_3D = 1;

TYPE_MODEL:

PLAY_MODE_NORMAL = 0;
PLAY_MODE_360 = 1;
PLAY_MODE_180 = 2;
PLAY_MODE_FULLDOME = 3;

TYPE_DECODE:

DECODE_MODE_HARDWARE = 0;
DECODE_MODE_SOFTWARE = 1;

2D:          PLAY_MODE_NORMAL       PLAY_TYPE_2D

3D:          PLAY_MODE_NORMAL             PLAY_TYPE_3D

Pano360°:  PLAY_MODE_360          PLAY_TYPE_2D

Pano360°3D: PLAY_MODE_360          PLAY_TYPE_3D

Pano180°2D: PLAY_MODE_180          PLAY_TYPE_2D

Pano180°3D: PLAY_MODE_180          PLAY_TYPE_3D

FullDome2D:  PLAY_MODE_FULLDOME     PLAY_TYPE_2D

sample code:
Intent intent = new Intent("com.nibiru.videostart");
                    intent.putExtra("PATH", "/sdcard/XXXXX.mp4");
                    intent.putExtra("TYPE_2DOR3D", 0);
                    intent.putExtra("TYPE_MODEL", 1);
                    intent.putExtra("TYPE_DECODE", 0);
                    startActivity(intent);
You have to log in before you can reply Login | Register

Points Rules

!fastreply! Top !return_list!