删除谷歌纸板"place phone into your cardboard viewer"消息



我有一个具有多个活动的纸板应用被展示?

您必须致电: setDisplayModesetTransitionViewEnabled

setTransitionViewEnabled设置为false

这样使用:

vrVideoView.setDisplayMode(VrWidgetView.DisplayMode.FULLSCREEN_STEREO);
vrVideoView.setTransitionViewEnabled(false);

我已经为我使用了它。

您可以使用此代码删除纸板视图中的对话框,设置和关闭按钮

 try {
           var f = VrWidgetView::class.java.getDeclaredField("vrUiLayer");
            f.setAccessible(true);
            var vrLayer =  f.get(mVrVideoView) as UiLayer
            // - here you can directly access to the UiLayer class - //

            // to hide the up-right settings button
            vrLayer.setSettingsButtonEnabled(false);
            //setting listener to null hides the x button
            vrLayer.setBackButtonListener(null);
            // these visibility options are frequently updated when you play videos,
            // so you have to call them often

            // OR

            vrLayer.setEnabled(false); // <- just hide the UI layer

        } catch ( e:Exception) {
            e.printStackTrace();
        }

相关内容

最新更新