本文整理汇总了Java中com.vuforia.Vuforia.onSurfaceCreated方法的典型用法代码示例。如果您正苦于以下问题:Java Vuforia.onSurfaceCreated方法的具体用法?Java Vuforia.onSurfaceCreated怎么用?Java Vuforia.onSurfaceCreated使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.vuforia.Vuforia
的用法示例。
在下文中一共展示了Vuforia.onSurfaceCreated方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onSurfaceCreated
import com.vuforia.Vuforia; //导入方法依赖的package包/类
public void onSurfaceCreated()
{
Vuforia.onSurfaceCreated();
}
示例2: onSurfaceCreated
import com.vuforia.Vuforia; //导入方法依赖的package包/类
public void onSurfaceCreated(GL10 gl, EGLConfig config)
{
// Call function to initialize rendering:
// The video texture is also created on this step
initRendering();
// Call Vuforia function to (re)initialize rendering after first use
// or after OpenGL ES context was lost (e.g. after onPause/onResume):
Vuforia.onSurfaceCreated();
for (int i = 0; i < VideoPlayback.NUM_TARGETS; i++)
{
if (mVideoPlayerHelper[i] != null)
{
// The VideoPlayerHelper needs to setup a surface texture given
// the texture id
// Here we inform the video player that we would like to play
// the movie
// both on texture and on full screen
// Notice that this does not mean that the platform will be able
// to do what we request
// After the file has been loaded one must always check with
// isPlayableOnTexture() whether
// this can be played embedded in the AR scene
if (!mVideoPlayerHelper[i]
.setupSurfaceTexture(videoPlaybackTextureID[i]))
mCanRequestType[i] = MEDIA_TYPE.FULLSCREEN;
else
mCanRequestType[i] = MEDIA_TYPE.ON_TEXTURE_FULLSCREEN;
// And now check if a load has been requested with the
// parameters passed from the main activity
if (mLoadRequested[i])
{
mVideoPlayerHelper[i].load(mMovieName[i],
mCanRequestType[i], mShouldPlayImmediately[i],
mSeekPosition[i]);
mLoadRequested[i] = false;
}
}
}
}