use of com.example.advanceDemo.view.StereoView in project LanSoEditor_advance by LanSoSdk.
the class VViewImage3DDemoActivity method onCreate.
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.vview_image3d_demo_layout);
mVideoPath = getIntent().getStringExtra("videopath");
mInfo = new MediaInfo(mVideoPath, false);
if (mInfo.prepare() == false) {
Toast.makeText(this, "传递过来的视频文件错误", Toast.LENGTH_SHORT).show();
this.finish();
}
drawpadView = (DrawPadView) findViewById(R.id.id_image3d_drawpadview);
mGLRelativeLayout = (ViewLayerRelativeLayout) findViewById(R.id.id_image3d_viewlayout);
mStereoView = (StereoView) findViewById(R.id.id_image3d_stereoView);
mStereoView.setVisibility(View.INVISIBLE);
findViewById(R.id.id_image3d_saveplay).setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
if (SDKFileUtils.fileExist(dstPath)) {
Intent intent = new Intent(VViewImage3DDemoActivity.this, VideoPlayerActivity.class);
intent.putExtra("videopath", dstPath);
startActivity(intent);
} else {
Toast.makeText(VViewImage3DDemoActivity.this, "目标文件不存在", Toast.LENGTH_SHORT).show();
}
}
});
findViewById(R.id.id_image3d_saveplay).setVisibility(View.GONE);
editTmpPath = SDKFileUtils.newMp4PathInBox();
dstPath = SDKFileUtils.newMp4PathInBox();
new Handler().postDelayed(new Runnable() {
@Override
public void run() {
startPlayVideo();
}
}, 300);
}
Aggregations